Staged Publishing support for AzureWebsites

ScottGu recently (yesterday) announced the staged publishing support for Windows AzureWebsites. The concept of staging deployment is not new in Azure world, we have this support from long time for Cloud Services. In Cloud Services, we can simply make a staging deployment and then test it thoroughly to ensure the integrity and new features of new version, once we test the staging deployment we can simply make a swap between staging and production versions. Thus we get new features and changes included in new version into production with a single button click.

AzureWebsites now support staged publishing along with production swap. Unlike to cloud services where the DNS will be swapped across deployments, in AzureWebsites content of the staging will be swapped with production.

To get started create a AzureWebsite and in Dashboard we can find “Enable Staged Publishing” as shown below.

image

Presently AzureWeebsites staged publishing supports only for Standard mode websites. So enabling the staged publishing will prompt for upgrading free/shared websites to standard mode.

image

On clicking Upgrade, Management portal will take us to Scale tab of the website.

image

Once Website has been scaled to Standard mode. We can go back and click Enable Staged publishing on dashboard. It will prompt for confirmation, Click Yes.

image

A staged version of website will be created as shown below.

image

Now lets browse the actual site at jash.azurewbesites.net. It displays default home page for AzureWbsites, because we never deployed any content to this site so far.

image

Lets create a simple Visual Studio 2013 MVC5 project.

image

Download the publish settings for the staging site, by clicking Download publishsettings as shown below.

image

Right click Visual Studio project and select publish. Click on Import and browse the publishsettings file we just downloaded.

image

Click ok, navigate to Preview tab and click on Publish. Once done, we have following version of site at jash-staging.azurewebsites.net

image

Once we test the application in staging url, we can swap the content from staging to production as shown below.

image

That will display the following confirmation.

image

click ok. It will take matter of seconds to minutes for swapping the content between the production and staging areas. Once completed, we can browse the production site and see all our changes from staging reflecting in production.

Swapping only changes the configuration related to following -

  1. General Settings
  2. Connection String
  3. Handler Mappings
  4. Monitoring and Diagnostic Settings

Rest all configuration will be intact for both the sites.

image

If we visit stating URL, then we will content swapped with production as shown below.

image

Staging site always helps us to be more productive when it comes to business continuity and User acceptance testing. I hope this feature will be more enhanced in future and extended to free and shared modes. Happy Coding!!!

You may also like...

One Pingback/Trackback

    22 January 2014 at 5:01pm
    [...] Staged Publishing support for AzureWebsites ...
  • TechNet Blogs