De Wiki inetshell
Saltar a: navegación, buscar

Exportar/importar configuracion[editar]

You can export the rules using appcmd, eg

appcmd list config -section:system.webServer/rewrite/globalRules -xml > file.xml

or

appcmd list config "My Site/My App" -section:system.webServer/rewrite/rules -xml > file.xml

and you can then import them using appcmd like below

appcmd set config -in < file.xml


Exportar:
C:\Windows\System32\inetsrv\appcmd.exe list config -section:system.webServer/rewrite/globalRules -xml > rewrite-2016-10-07.xml
C:\Windows\System32\inetsrv\appcmd.exe list config -section:webFarms -xml > webFarms-2016-10-07.xml
C:\Windows\System32\inetsrv\appcmd.exe list config -xml > IIS_CONFIG-2016-10-07.xml
C:\Windows\System32\inetsrv\appcmd.exe list config -section:system.webServer/httpErrors -xml  > httpErrors-2016-10-09.xml


Importar:
C:\Windows\System32\inetsrv\appcmd.exe set config -in < webFarms-2016-10-07.xml
C:\Windows\System32\inetsrv\appcmd.exe set config -in < rewrite-2016-10-07.xml

Manda error al importar
C:\Windows\System32\inetsrv\appcmd.exe set config -in -xml < httpErrors-2016-10-07.xml


Instalar desde powershell[editar]

https://www.solvps.com/blog/installing-iis-powershell-windows-vps/

ARR / Redirecciones[editar]

Redirigir HTTP a HTTPS[editar]

https://www.namecheap.com/support/knowledgebase/article.aspx/9953/38/iis-redirect-http-to-https

https://blogs.technet.microsoft.com/dawiese/2016/06/07/redirect-from-http-to-https-using-the-iis-url-rewrite-module/