I need to set uploadReadAheadSize
attribute of serverRuntime
element in ASP.NET Core web.config
, but after launching, it throws a HTTP Error 500.19 with the message
This configuration section cannot be used at this path
I found here, that I just need to set overrideModeDefault
to "Allow" for ServerRuntime
in {ProjectDirectory}.vs\\config\\applicationhost.config
path. And that's exactly the problem, because everyone on the team has to change this setting locally the first time they run the application.
We could also add an applicationhost file in .gitignore
, but we would like to avoid this.
Are there any options so that I don't have to change applicationhost.config
every time I start the project for the first time? My goal is to make the first launch of an application a little easier for developers.
Steps to reproduce:
- Create new ASP.NET Core Web API
- Create Web.Config with:
<configuration>
<system.webServer>
<serverRuntime uploadReadAheadSize="1000000" />
</system.webServer>
</configuration>
- Run app using IISExpress