|
1 | 1 | # This example workflow can be used to perform manually-triggered Azimuth deployments targeting production environments.
|
2 | 2 | # The workflow requires a GitHub environment (https://docs.github.com/en/actions/using-jobs/using-environments-for-jobs) to
|
3 |
| -# be created in the site-specific config repo with a name which exactly matches the azimuth-config environment to be used |
4 |
| -# for production deployments. For security, this GitHub environment should also have a deployment protection rule which |
5 |
| -# restricts the environment workflows to only run on the main/default branch. This ensures that production deployments |
| 3 | +# be created in the site-specific config repo with a name which exactly matches the azimuth-config environment to be used |
| 4 | +# for production deployments. For security, this GitHub environment should also have a deployment protection rule which |
| 5 | +# restricts the environment workflows to only run on the main/default branch. This ensures that production deployments |
6 | 6 | # cannot be executed from arbitrary branches which could contain incorrect or unreviewed configuration.
|
7 | 7 | #
|
8 |
| -# A manually-triggered workflow is used here since GitHub does not allow deployment approval rules for environments in |
| 8 | +# A manually-triggered workflow is used here since GitHub does not allow deployment approval rules for environments in |
9 | 9 | # private GitHub repos without a GitHub Enterprise subscription. If the site-specific config repo is public, or if an enterprise
|
10 |
| -# subscription is available, then triggering the workflow on push to main with additional approval rules in the environment is |
| 10 | +# subscription is available, then triggering the workflow on push to main with additional approval rules in the environment is |
11 | 11 | # the recommended approach.
|
12 |
| -# |
| 12 | +# |
13 | 13 | # The site-specific config repo must also define a repository secret named GIT_CRYPT_KEY_B64 which contains the base64 encoded
|
14 | 14 | # git-crypt key which was used to encrypt the repository's secrets. This can be obtained by running `git-crypt export-key - | base64`
|
15 | 15 | # from within an unlocked checkout of the repository. For information on defining GitHub repo secrets, see:
|
|
18 | 18 | name: Azimuth deployment
|
19 | 19 | on:
|
20 | 20 | workflow_dispatch:
|
21 |
| - inputs: |
| 21 | + inputs: |
22 | 22 | environment:
|
23 | 23 | description: "The Azimuth config environment to deploy"
|
24 | 24 | type: environment
|
|
40 | 40 |
|
41 | 41 | - name: Deploy Azimuth
|
42 | 42 | shell: bash
|
| 43 | + env: |
| 44 | + ANSIBLE_FORCE_COLOR: True |
43 | 45 | # Here we just decrypt the repo checkout then follow the steps from the Azimuth deployment docs.
|
44 | 46 | # The GitHub repo should have an environment configured with a name which matches the Azimuth config environment.
|
45 | 47 | # This GitHub environment should also have a branch protection rule which only allows deployments on chosen production branch (e.g. main).
|
|
0 commit comments