Pavel
Pavel

Reputation: 554

IIS ARR does not handle requests on port 80

I have following global rule in IIS 7 on Windows Server 2008 R2

   <rewrite>
        <globalRules>
            <rule name="123" stopProcessing="false">
                <match url=".*" />
                <action type="Rewrite" url="http://work-monitoring/{R:0}" />
                <conditions>
                    <add input="{HTTP_HOST}" pattern="work-reports.mydomain.com" />
                </conditions>
            </rule>
        </globalRules>
    </rewrite>
    <proxy enabled="false" />

This rule handles successfully http requests to work-reports.mydomain.com on any port except 80 which results in 404 Not Found error code.

E.g. it handles http://work-reports.mydomain.com:777 but http://work-reports.mydomain.com:80 results in 404 Not Found error.

What is wrong with my IIS settings? Failed Request Tracing does not produce any logs. Windows Event logs do not contain any related info

Upvotes: 0

Views: 290

Answers (1)

Pavel
Pavel

Reputation: 554

The solution is to define some default site with port 80 and with empty hostname like this

 <binding protocol="http" bindingInformation="*:80:" />

Upvotes: 0

Related Questions