Skip to content

Commit 7cec99c

Browse files
Merge pull request #2891 from alphagov/bulk/add-release-versions
2 parents dfad328 + fa03cf8 commit 7cec99c

File tree

2 files changed

+20
-6
lines changed

2 files changed

+20
-6
lines changed

.github/workflows/deploy.yml

+4-6
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,16 @@ on:
1919
- staging
2020
- production
2121
default: 'integration'
22-
workflow_run:
23-
workflows: [CI]
24-
types: [completed]
25-
branches: [main]
22+
release:
23+
types: [released]
2624

2725
jobs:
2826
build-and-publish-image:
29-
if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success'
27+
if: github.event_name == 'workflow_dispatch' || startsWith(github.ref_name, 'v')
3028
name: Build and publish image
3129
uses: alphagov/govuk-infrastructure/.github/workflows/build-and-push-image.yml@main
3230
with:
33-
gitRef: ${{ inputs.gitRef || github.ref }}
31+
gitRef: ${{ inputs.gitRef || github.ref_name }}
3432
secrets:
3533
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_GOVUK_ECR_ACCESS_KEY_ID }}
3634
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_GOVUK_ECR_SECRET_ACCESS_KEY }}

.github/workflows/release.yml

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: Release
2+
3+
on:
4+
workflow_dispatch:
5+
workflow_run:
6+
workflows: [CI]
7+
types: [completed]
8+
branches: [main]
9+
10+
jobs:
11+
release:
12+
if: github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success'
13+
name: Release
14+
uses: alphagov/govuk-infrastructure/.github/workflows/release.yml@main
15+
secrets:
16+
GH_TOKEN: ${{ secrets.GOVUK_CI_GITHUB_API_TOKEN }}

0 commit comments

Comments
 (0)