Allow Deployment Scheduling via Manual Intervention step in advance of Deployment

For the following scenario:

A suitable Release Candidate has been completed by the Development Team and the Artifact is ready in Octopus, at the close of business on a particular day. (Signed off by Team and safe to ship)

A customer may be expecting said Release Candidate to be deployed to their site/s early the following morning, prior to business hours to avoid any disruption to its’ users.

The ‘Manual Intervention and approval step’ is ideal for cases where a human needs to be involved to approve or confirm a deployment, before it is safe to go ahead. (And is perfect to ensure ‘Production/Live’ deployments have had the appropriate attention paid to them before being actioned)

My personal experience has been that scheduling a Deployment in advance with the ‘Manual Intervention and approval step’, has been that I still have to be present to action the manual approval, at the point-of-time of the intended deployment.

Is it possible for the actual approval step to be actioned and any approval/s collected from any applicable Octopus users ahead of the scheduled deployment time? (example: If I approve deployment at 21:00 the night before, and the deployment proceeds at 06:00 the next morning.)

Thanks in advance.

Kind regards,

Michael Murphy

Hi Michael,

Thanks for getting in touch with your great, detailed question, and welcome!

Unfortunately there’s no out-of-the-box perfect solution to address your needs at this point in time. There has been work done on an “approval gate” feature that would solve this requirement nicely, however that will likely still be some time until it’s out the door. As for now, I imagine the best option to implement this might be to do the following.

Create a separate project (in my example test I called it “approval gate”) that has three steps.

  1. Manual Intervention to control the approval
  2. Wait Until Time library step template to control when to proceed after the deployment has been approved
  3. Deploy a Release step to kick off the deployment of the “child project” once the time has come

I split the approval process into its own project so as to avoid the actual project showing as having an in-progress deployment for those hours spent simply waiting to continue.

I’d be very keen to hear what you think, and happy to revisit this based on your thoughts. :slight_smile:

Best regards,

Kenny

1 Like

Hi @michael.murphy

To add to what @Kenneth_Bates has already mentioned, a colleague of mine wrote about a similar scenario in his blog post Better release management. It covers a community step template that he authored.

It might be worth reading it; specifically the section titled Scenario: Approve today, deploy tomorrow.

I hope that helps!

1 Like

Hi @michael.murphy,

You are absolutely spot-on in your analysis. The manual intervention step was originally designed to pause a deployment so a person could perform an action:

  • Review the Terraform output to verify what is about to change.
  • Perform some manual sanity checks on a recently deployed website to a “staging” slot prior to switching it over.
  • Verifying a Database Delta Script doesn’t include phrases like “drop database.”

As you can imagine, all of those actions require the deployment to be actually running. In the blog post I authored, I provided a work-around to that issue. Specifically, create an “prod-approval” environment that sits between staging and production. The prod approval environment is where all the approvals take place.

As Kenny alluded to, we are currently working on ServiceNow integration. ServiceNow handles all the approvals, Octopus Deploy checks that a change request exists and proceeds once it finds one. We are currently in alpha with a limited number of customers. Our goal is a Q3 2022 release (that is assuming the Alpha doesn’t discover any massive areas to improve).

As Mark said, right now, your best bet is to have a release orchestration project handle that all for you. The manual intervention would occur in that release orchestration project. The step template I authored can either kick off a release now, or you can tell it to schedule a release to be deployed later.

I hope that helps!

1 Like