7. GitHub Actions
The deployment process keeps all environments in sync with production except what is being deployed with the pull request. As such you have both sync_run_ids and deploy_run_ids as input to a combined-deploy.yaml workflow.
sync_run_ids- GitHub Actions run IDs of the services to sync with production to update your environment.deploy_run_ids- GitHub Actions run IDs of the services to deploy from your pull request.
Combined Deploy Workflow¶

In order for a repository to handle deployments, it must contain and workflow of combined-deploy.yaml with the following inputs:
on:
workflow_dispatch:
inputs:
pull_number:
description: 'Pull request number'
type: string
required: false
environment:
type: choice
description: 'Deploy environment'
options:
- dev
- stage
- prod
deploy_run_ids:
description: 'IDs of builds to deploy'
type: string
required: true
sync_run_ids:
description: 'IDs of builds to sync'
type: string
required: false
deploy_name:
description: 'Deploy run name (automated)'
type: string
required: true
A job can be used like the following to get the build information from the run IDs:
jobs:
deploy_info:
name: Deploy Info
runs-on: ubuntu-latest
concurrency:
group: deploy-info-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
outputs:
branch: ${{ steps.build_info.outputs.branch }}
builds_matrix_json: ${{ steps.build_info.outputs.builds_matrix_json }}
builds_json: ${{ steps.build_info.outputs.builds_json }}
steps:
- name: Get build info
id: build_info
uses: greggbjensen/prdeploy/.github/actions/get-build-info@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
pull_number: ${{ inputs.pull_number }}
deploy_run_ids: ${{ inputs.deploy_run_ids }}
sync_run_ids: ${{ inputs.sync_run_ids }}
GitHub Actions¶
Actions that apply and retrieve the information needed for builds and deployments.
| Action | Description |
|---|---|
| build-details | Creates a summary of your build with version and pull request info. |
| date-version | Creates a version for a build using the current date and run ID of the workflow. |
| get-build-info | Gets build data and a matrix for a set of deploy and sync run IDs. |
Notes¶
- Labels will be automatically created for each environment in your repository.
- Environment label color will be the badge color for the environment icon in comments.
- In order for a completed or failed deploy status message to show the version, you must provide a
build-detailsartifact to your builds that includes abuild-details.jsonfile with at least the following: -
The build-details action can provide this.

- Go to Settings and General for your repository and check
Always suggest updating pull request branchesto get the pull request Update button. - This makes it much easier to update your pull requests to latest before deploying.