Wednesday, January 9, 2013

Yet another story about OneClick deployment for Sitecore

This blog post is inspired by "OneClick deployment for Sitecore..." post by Jan Hebnes.

I'll describe how to achieve the same result, but using slightly different tools. So, what are the options?



Differential Update packages
They include only changes between the releases, you can TAG all releases in version control, and the get diff between TAG and TRUNK - generate a patch containing only changed items / templates / etc.

This will also work for extremely large websites, even if you have thousands of templates - you don't have to worry about it at all, only changed items will be included into the update package.

How to create diff packages? Read the blog post about Sitecore Courier module or browse the source code here: https://github.com/adoprog/Sitecore-Courier. And yes, it is completely free.

Zipped web root as a build output (instead of msdeploy package)
This gives more flexibility when you deploy it with PowerShell, you get endless scalability with deployment scripts via PowerShell remoting, etc. Such packages are also much easier to create - just copy your custom files over the data & website folders from, clean Sitecore installation, and you're done.

You can find Sitecore PowerShell deployment framework here: https://github.com/adoprog/Sitecore-PowerCore 

Versioned releases with rollback option and no donwtime during release
The usual scenario looks like this - while production website version XX is running:

  1. Deploy version YY from package using PowerShell
    • Extract all new files from zip
    • Duplicate production website database 
    • Apply update package with Sitecore items at YY website
  2. Verify that the installation succeed 

Is everything is fine - just press a button to go live with YY, website switch in IIS is instant.
Found critical issue? -  Press another button to revert to the version XX in seconds!

It's not used that often, but you feel safer when you know you can undo the changes.

Summary
I hope this will help you to make the right decision when designing build-deploy-test workflow for your Sitecore project. If you have any questions and suggestions - please do not hesitate to contact me.

No comments:

Post a Comment