Octopus Deploy Documentation

Health check step

Last updated

Octopus periodically runs health checks on deployment targets and workers to ensure that they are available and running the latest version of Calamari as part of a machine policy.

However, often it can be useful to check the health of deployment targets when executing a runbook or deployment, particularly with dynamic infrastructure and transient deployment targets.

This can be achieved using the Health Check step.

Health check step search

This step allows a deployment target that was created in the currently executing deployment to be confirmed as healthy and then added to the running deployment for subsequent steps.

Similarly, it allows you to confirm that the tentacle service on a deployment target is running prior to attempting to perform an action against it.

Configure a Health check step

Health check steps are added to deployment and runbook processes in the same way as other steps:

  1. Add a new Health Check step to your project's deployment process.

    Health check step

  2. In the On Behalf Of section, select the target roles that match the deployment targets you want to run a health check against.

  3. In the Health check section select an option for Health check type:

    • Perform a full health check - this will run the health check script defined by the machine policy.
    • Perform a connection-only test - this only checks the machine is available (connected).

    For Health check errors, select which action to take on a health check error:

    • Fail the deployment (default).
    • Skip deployment targets that are unavailable.
  4. In the Machine Selection section, select which action to take for any new machines found as a result of the health check:

    • Ignore any newly available deployment targets (default)
    • Include new deployment targets in the deployment - This option is recommended in dynamic deployments that involve targets that are created as part of the current deployment.

Health check for workers

Whilst the built-in Health check step works for deployment targets, it was not designed for Workers.

To check the health of a worker in a deployment or runbook, there is a Worker - Health check community step template.

Need support? We're here to help.