I'm running my ASP.NET MVC app on a Windows Server using IIS 10.
I've set bunch of custom header in HTTP Response Headers section for this website.
After some time I was stunned after finding out that they're no longer there.
I suspect that they were erased when I deployed a new app version - effectively by changing app path in Basic settings section for a website.
How can I make those headers persistant? Why where they cleared? Is there anything else that I should know about?
If custom headers were added through the IIS server interface the changes would be persisted on the web.config of the app on the server. Upon deploying a new version of the app the same would be replaced with new config file. Over writing of the config file would lead to loss of any custom configuration the old file may have including the custom header fields. With the amount of information available, I assume this may be one of the possible reason.