mirror of
https://github.com/tim-krehan/shopping-list.git
synced 2024-11-23 14:20:41 +01:00
add web.config to make application ready for azure
This commit is contained in:
parent
e169a36e5b
commit
b5d4e5874a
1 changed files with 37 additions and 0 deletions
37
web.config
Normal file
37
web.config
Normal file
|
@ -0,0 +1,37 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration>
|
||||
<system.webServer>
|
||||
<rewrite>
|
||||
<rules>
|
||||
<rule name="normal page without subpage">
|
||||
<match url="^([a-zA-Z0-9-]+)$" ignoreCase="false" />
|
||||
<action type="Rewrite" url="?site={R:1}" appendQueryString="false" />
|
||||
</rule>
|
||||
<rule name="scripts">
|
||||
<match url="/js/(.+)" ignoreCase="false" />
|
||||
<action type="Rewrite" url="/js/{R:1}" />
|
||||
</rule>
|
||||
<rule name="error pages">
|
||||
<match url="^error/([a-zA-Z0-9-_]+)$" ignoreCase="false" />
|
||||
<action type="Rewrite" url="?site=error&id={R:1}" appendQueryString="false" />
|
||||
</rule>
|
||||
<rule name="recipe pages">
|
||||
<match url="^recipe/([0-9]+)$" ignoreCase="false" />
|
||||
<action type="Rewrite" url="?site=recipe&number={R:1}" appendQueryString="false" />
|
||||
</rule>
|
||||
<rule name="recipe edits">
|
||||
<match url="^edit-recipe/([0-9]+)$" ignoreCase="false" />
|
||||
<action type="Rewrite" url="?site=edit-recipe&number={R:1}" appendQueryString="false" />
|
||||
</rule>
|
||||
<rule name="login page">
|
||||
<match url="^login/url=(.+)$" ignoreCase="false" />
|
||||
<action type="Rewrite" url="?site=login&refurl={R:1}" appendQueryString="false" />
|
||||
</rule>
|
||||
<rule name="api calls" stopProcessing="true">
|
||||
<match url="^api/([\w-]+)/([\w-]+)$" ignoreCase="false" />
|
||||
<action type="Rewrite" url="php/api.php?site=api&call={R:1}&function={R:2}" appendQueryString="false" />
|
||||
</rule>
|
||||
</rules>
|
||||
</rewrite>
|
||||
</system.webServer>
|
||||
</configuration>
|
Loading…
Reference in a new issue