Rehearse a pipeline
Run a site's saved pipeline on its staging environment before a deployment uses it on Production.
Before you start
- You are an owner, or your role has Edit Environment Deployment Pipeline.
- The site has a staging environment: see Create an environment. Rehearsals never run on Production.
- Your changes to the pipeline are saved: see Pipeline.
Start a rehearsal
A rehearsal builds your code and runs the database commands on the staging environment.
Open the dialog
Go to Managed Websites, choose the site, then Deployments under Code & backups. On the Pipeline card of the Production environment, choose Rehearse on Staging….
Choose what to build
Choose the environment under Rehearse on. Leave Branch, tag or commit blank to build the branch this pipeline deploys, or enter another, then choose Start.
Read the result
Rehearsal on Staging appears under the Pipeline card and follows each step: Build, Upload, Shared files, Platform step and Database commands. A failed step shows the command that failed, with its exit code.
The rehearsal ends as Rehearsal passed or Rehearsal failed. Choose Open the log for the full output, and Dismiss when you have read the result.
What a rehearsal leaves out
- The staging environment's release is not switched, and nothing on Production changes.
- After-deploy commands do not run.
- Commands that reach the network are skipped, and listed under the steps.
Automate this
Runs a pipeline's stages on a staging environment without changing what the environment serves, to show whether a deployment would succeed.
curl -X POST https://manage.corefinity.com/api/corestack/sites/1042/deployments/rehearsals \
-H "Authorization: Bearer $COREFINITY_TOKEN" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"binding_id": 2211
}'Your assistant calls corestack_deployments_rehearse.
{
"name": "corestack_deployments_rehearse",
"arguments": {
"site_id": 4212,
"binding_id": 1841,
"proposal": {
"database": {
"lines": ["wp option get siteurl"]
}
}
}
}