I tend to use the
app_offline.htm
file, which takes the application off-line, combined with a batch file.
app_offline.htm:
<!DOCTYPE html>
<html>
<head>
<title>Application Offline</title>
<meta http-equiv="refresh" content="60" />
<style type="text/css">
div
{
background-color: #ffc;
padding: 10px;
border: 1px solid black;
}
</style>
</head>
<body>
<div>
This application is currently offline. Please try again in a few moments.
</div>
</body>
</html>
update.bat:
@ECHO OFF
robocopy .\WWW .\_bak /Z /E /MIR
xcopy app_offline.htm .\WWW\ /Y
ping localhost -n 5 > NUL
robocopy .\_staging .\WWW /XF app_offline.htm /Z /E /MIR
del .\WWW\app_offline.htm