1

I have a situation where I need to set up GitLab behind an IIS.

The GitLab instance is working perfectly fine within the LAN, but trying to set it up through IIS reverse proxy doesn't work.

I get 502 / Bad Gateway no matter what I try.

Any idea how to solve this?

1 Answer 1

0

It can be incorrectly specified docker ip address. Here is my working web.config:

<?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <rewrite> <rules> <clear /> <rule name="Let's encypt" stopProcessing="true"> <match url="^\.well-known.*$" /> <conditions logicalGrouping="MatchAll" trackAllCaptures="false" /> <action type="None" /> </rule> <rule name="gitlab forwarding" stopProcessing="true"> <match url="(.*)" /> <conditions logicalGrouping="MatchAll" trackAllCaptures="false" /> <serverVariables> <set name="HTTP_X_FORWARDED_HOST" value="your.public.domain" /> </serverVariables> <action type="Rewrite" url="http://192.168.99.100:10080/{R:1}" /> </rule> </rules> </rewrite> </system.webServer> </configuration> 
1
  • I'm using IIS 10 and facing issue: The server variable "HTTP_X_FORWARDED_HOST" is not allowed to be set. Add the server variable name to the allowed server variable list., removed the <serverVariables> section and it works! Commented Aug 31, 2017 at 3:04

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.