When I publish my ASP .Net Core 1.1 MVC web app, I see the Publish folder contain a Web.config
file, where I can set stdoutLogEnabled
, etc. However, while developing I don't see this file at all - it looks like it's being generated when publishing... How can I therefore set the variables in this file without having to manually edit the file after each publish?
Web.config
only makes sense if you host the app on Windows with IIS. You have to manually add it to the project to edit the file's contents or it will be auto-generated:
Documentation:
If you don't have a
web.config
file in the project when you publish with dotnet publish or with Visual Studio publish, the file is created for you in published output. If you have the file in your project, it's transformed with the correctprocessPath
andarguments
to configure the ASP.NET Core Module and moved to published output. The transformation doesn't touch IIS configuration settings that you've included in the file.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With