The configuration works when I’m not running it with docker compose. I filed in issue with them as well. I think the case maybe be that with the proxy configuration has to have the host name set with with an
upstream declaration as is done in this article. I’ll be testing it out soon.
Of course… what else do you expect?
Well I worded that one a bit “Captain obviously’ish”, but the point I was making is that the proxy redirect does work in that case. In other words the nginx ip address is 203.0.113.2 and the gogs address is 203.0.113.1 so the redirect is working, and we see 203.0.113.2 in the address bar.
Now all I want to do is set
git.example.com in my
203.0.113.2 so that I can enter
git.example.com in the address bar, and have the redirect work still, but this does not work. In other words when I use a host name that should matches the IP address that nginx does perform the redirect from, then nginx ignores the redirect.
So it should work … but it does not.
One thing I wanted to make sure of is that Gogs does have have any “special” programming where it would ignore requests under certain conditions right? In other words this has to be an nginx or a docker compose issue?