[ACCEPTED]-Site is under construction" page for asp.net site-web

Accepted answer
Score: 18

I prefer App_Offline.htm file in the root.

Take 8 a scrape of your site template, stick it 7 in the App_Offline.htm file and place a 6 message in it. Just dropping this file in 5 the root folder of your web site effectively 4 disables your site.

Meanwhile, upload/manage 3 a second instance of the web-site using 2 a temporary domain/URL and when tested/ready, re-point 1 the old site to the new site in IIS.

Score: 2

The change you're deploying now is a simple 15 change to a single page. But sometimes you 14 deploy larger changes, or you deploy both 13 code and database changes, and the site 12 might behave incorrectly if a user requests 11 a page before deployment is finished. To 10 prevent users from accessing the site while 9 deployment is in progress, you can use an 8 app_offline.htm file. When you put a file 7 named app_offline.htm in the root folder 6 of your application, IIS automatically displays 5 that file instead of running your application. So 4 to prevent access during deployment, you 3 put app_offline.htm in the root folder, run 2 the deployment process, and then remove 1 app_offline.htm after successful deployment.

Source: https://www.asp.net/mvc/overview/deployment/visual-studio-web-deployment/deploying-a-code-update

More Related questions