Cowboy in the desert.

Octopus 1.2 with Retention Policies

November 28, 2012

Today I released Octopus Deploy 1.2, which along with a number of small improvements, includes the retention policy feature I blogged about last month, which was also the highest voted on feature on our Trello board. In this post I wanted to demonstrate how the feature works.

After installing 1.2, you'll now find a new tab under the Configuration area where you can define retention policies.

Retention policies

Retention policies are set at the project group level, a feature introduced in Octopus 1.1. You can choose which retention policy a project group uses on the project group settings dialog:

Setting the retention policy

Note that there's a default retention policy called "Keep everything, forever". If you delete a retention policy, the project group will revert back to this "keep everything" policy.

There are three different parts to a retention policy:

Editing retention policies

The Tentacle options take effect when you deploy to an environment. In this example, once I deploy a package 4 times to a given machine, the package (.nupkg and the directory it was extracted to) will also be deleted.

Retention policies on Tentacle

The Octopus options run on a schedule, much like the automatic health check task. You can see the output on the Tasks page:

Tasks page

The output from the task tells you which releases were deleted thanks to the retention policy:

Retention policy output

While the retention policy task runs automatically, you can also run it manually from the retention policies page. You may find that when you first upgrade to 1.2, you have to run the task multiple times as the indexes won't be fully up to date.

I hope you'll find this new addition useful.

Tagged with: New Releases