Browse Source

Add instructions to fix 405 Method Not Allowed error in IIS deployment

pull/22396/head
maliming 2 years ago
parent
commit
13061704c3
No known key found for this signature in database GPG Key ID: A646B9CB645ECEA4
  1. 29
      docs/en/solution-templates/layered-web-application/deployment/deployment-iis.md

29
docs/en/solution-templates/layered-web-application/deployment/deployment-iis.md

@ -254,6 +254,35 @@ We can visit the websites from a browser.
![Tiered IIS deployment](../../../images/iis-sample-tiered-deployment.gif)
## Fix 405 Method Not Allowed Error
Remove `WebDAV` modules and handlers from the `Web.config` file.
```xml
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<modules>
<remove name="WebDAVModule" />
</modules>
<handlers>
<remove name="WebDAV" />
</handlers>
</system.webServer>
</configuration>
```
Also remove the `WebDAV Publishing` feature from your computer if it's not being used. To do so, follow these steps:
1. Select Start, type Turn Windows features on or off in the Start Search box, and then select Turn Windows features on or off.
2. In the Windows Features window, expand Internet Information Services -> World Wide Web Services -> Common HTTP Features.
3. Uncheck the WebDAV Publishing feature.
See:
- https://learn.microsoft.com/en-us/aspnet/web-api/overview/testing-and-debugging/troubleshooting-http-405-errors-after-publishing-web-api-applications#resolve-http-405-errors
- https://learn.microsoft.com/en-us/troubleshoot/developer/webapps/iis/site-behavior-performance/http-error-405-website#resolution-for-cause-3
## How to get stdout-log
If your application is running on IIS and getting errors like `502.5, 500.3x`, you can enable stdout logs to see the error details.

Loading…
Cancel
Save