Black Tambourine (Posts tagged Octopus Deploy)

1.5M ratings
277k ratings

See, that’s what the app is perfect for.

Sounds perfect Wahhhh, I don’t wanna

Branching, Versioning and Deployment of Sitecore

Here’s quick set of recommendations for setting up your deployment processes with Sitecore once a solution goes live into Production.

Versioning

For versioning I’d recommend the http://semver.org convention of MAJOR.MINOR.PATCH.BUILDNo-BranchName

e.g. 1.2.15.1102-hotfix

Source Control Branches

Branches in source control should be setup as follows:

Master: should be the current production code or code about to be deployed.

Hotfix: should be used for small fixes for production.

Release “A”: larger changes that require a longer period of development and testing.

Each branch is distinguished using a suffix and has it’s own Build Number. The exception is the Master branch, which has no suffix.

The Major.Minor.Patch number reflects which version of Production has been merged into that branch.

When a support/development branch is merged into Master (i.e. ready for Deployment to Production) the version number of Master is incremented (to reflect whether this is a major, minor, or patch change).

This all looks like this over the life of the solution:

image

Channels

Using Octopus Deploy we can create release Channels based on the version numbers suffix. Create a Channel and add a Version Rule. Set the “Tag” filter to be the name of the branch e.g. hotfix. For the Master branch set this value to ^$

Each Channel can have it’s own Lifecycle, so we could set it up so that only the Master branch can be deployed to Production, while others can only go to testing environments.

Sitecores Recommendations

Sitecore have some of their own best practices around deployment, which you can read about on the official Sitecore Helix best practices website: http://helix.sitecore.net/devops/deployment/strategy.html

Sitecore Deployment Versioning Source Control Branching devops Octopus Deploy Channels Team City Build Configuration
Octopus Deploy Script Module: CommandNotFoundException Script Modules are a great way of reusing the same Powershell scripts across multiple projects.
One gotcha is that you need to explicitly specify which Script Modules can run per project;...

Octopus Deploy Script Module: CommandNotFoundException

Script Modules are a great way of reusing the same Powershell scripts across multiple projects.

One gotcha is that you need to explicitly specify which Script Modules can run per project; Otherwise you will see a “CommandNotFoundException” and the error “is not recognized as the name of a cmdlet“.

The location of this setting seems to vary from version to version of Octopus and is easy to miss. It will be under the Process tab. See the image above for where it is in Octopus 3.4, on the bottom right of the screen.

Octopus Deploy CommandNotFoundException is not recognized as the name of a cmdlet