Configuration (.github/deploy.yml)

Deliverybot controls deployments based on a configuration file. Targets are the top level resource for this file which house configuration to trigger a list of deployments depending on specific conditions. Documentation for those conditions and fields is provided below.

# .github/deploy.yml
  environment: name 

Controls auto deployment behaviour given a ref. If any new push events are detected on this event, the deployment will be triggered.

# .github/deploy.yml
  auto_deploy_on: refs/heads/master

Recently added!:

This configuration option also supports a * character to match any subsequent characters after it. This allows us to deploy on any tag (refs/tags/*) or to match any branch for deployments (refs/heads/*).

Deploying on any tag is probably one of the most commonly used features for deliverybot:

  auto_deploy_on: refs/tags/*

Specifies if the given environment is specific to the deployment and will no longer exist at some point in the future. Default: false

If this value is true all deployments triggered on a pr will be marked inactive.


Specifies if the given environment is one that end-users directly interact with. Default: true when environment is production and false otherwise.


The status contexts to verify against commit status checks. Default: []


The name of the environment that was deployed to (e.g., staging or production). Default: none


The name of the task for the deployment (e.g., deploy or deploy:migrations). Default: none


Attempts to automatically merge the default branch into the requested ref, if it’s behind the default branch. Default: false


Payload with extra information about the deployment. Default: {}


The following variables are available using ${{ }} syntax when evaluating deployment targets:

  • ref: Deployment ref, ie: master.
  • sha: Full git sha.
  • short_sha: Short git sha.
  • pr: Pr number, if this deployment is kicked off in a PR.
  • target: Current target name.
  • owner: Owner name.
  • repo: Repo name.
  • pull_request: GitHub pull request object.
  • commit: GitHub commit object.

An example usage of this:

# .github/deploy.yml
  # Dynamic environment name. The environment will look like pr123.
  environment: pr${{ pr }} 
Need help?
Or chat with the community on Spectrum