Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?xml version="1.0" encoding="UTF-8"?>
- <configuration>
- <system.webServer>
- <rewrite>
- <rules>
- <clear />
- <rule name="Force SSL" enabled="false" stopProcessing="true">
- <match url=".*" />
- <conditions logicalGrouping="MatchAll" trackAllCaptures="false">
- <add input="{HTTPS}" pattern="off" />
- </conditions>
- <action type="Redirect" url="https://{HTTP_HOST}{REQUEST_URI}" />
- </rule>
- <rule name="Root redirect" patternSyntax="ECMAScript" stopProcessing="true">
- <match url="^([^/]*)$" />
- <conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
- <action type="Redirect" url="{R:1}/" />
- </rule>
- <rule name="HG: Url rewrite" stopProcessing="true">
- <match url="^hg/(.*)" />
- <conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
- <action type="Rewrite" url="http://hg.example.local/{R:1}" />
- </rule>
- <rule name="SVN: Url rewrite" stopProcessing="true">
- <match url="^svn/(.*)" />
- <conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
- <action type="Rewrite" url="http://svn.example.local/{R:1}" />
- </rule>
- </rules>
- <outboundRules>
- <rule name="Content rewrite" preCondition="IsHtml">
- <match filterByTags="A, Img, Link, Script" pattern="^/(.*)" />
- <action type="Rewrite" value="/src/{C:1}/{R:1}" />
- <conditions>
- <add input="{URL}" pattern="src/([^/]*)/(.*)" />
- </conditions>
- </rule>
- <preConditions>
- <preCondition name="IsHtml">
- <add input="{RESPONSE_CONTENT_TYPE}" pattern="^text/html" />
- </preCondition>
- </preConditions>
- </outboundRules>
- </rewrite>
- <urlCompression doStaticCompression="false" doDynamicCompression="false" />
- </system.webServer>
- </configuration>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement