Skip main navigation

Configuring Octopus – Machine Role and Lifecycle

In the previous step, you were introduced to the first building block of configuring Octopus, the environment. In this step, you will learn about the concepts of machine role and lifecycle in Octopus.

Machine Role

A machine role is a tag on a machine. It allows you to group deployment targets with a common tag. You can have more than one tag per target.

Roles are free form, which means you can use whatever values you choose. It is typical to use tags such as WebServer, Database or any other categorisation type to classify machines.

graphical representation of deployment target settings for specifying roles


Lifecycles define how code can flow between environments. They can be used to define scenarios such as:

  • Force a release to be promoted to a given environment after it has been deployed to the previous environment.
  • Enable auto-deploy for a given environment; for example, automatically deploy to development after a release is created.

A lifecycle is defined by phases. A phase can have one or more environments, where each environment can be configured to be either an automatic deployment environment or a manual deployment environment. A phase can define the number of environments that must have a release before deployment is allowed for the next phase.

graphical representation of the location of lifecycles on Octopus

A lifecycle also has an associated retention policy, in which you can set how long or how many releases are kept. Policies can also be defined per phase.

graphical representation of setting up a retention policy for lifecycles

In the following step, you will learn about project in Octopus.

This article is from the free online

Microsoft Future Ready: Continuous Integration Implementation

Created by
FutureLearn - Learning For Life

Reach your personal and professional goals

Unlock access to hundreds of expert online courses and degrees from top universities and educators to gain accredited qualifications and professional CV-building certificates.

Join over 18 million learners to launch, switch or build upon your career, all at your own pace, across a wide range of topic areas.

Start Learning now