forked from alphagov/asset-manager
-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (34 loc) · 1.1 KB
/
deploy.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Deploy
on:
workflow_dispatch:
inputs:
gitRef:
description: 'Commit, tag or branch name to deploy'
required: true
type: string
default: 'main'
push:
branches:
- main
paths-ignore:
- "Jenkinsfile"
- ".git**"
jobs:
build-and-publish-image:
name: Build and publish image
uses: alphagov/govuk-infrastructure/.github/workflows/ci-ecr.yaml@main
with:
gitRef: ${{ github.event.inputs.gitRef }}
secrets:
AWS_GOVUK_ECR_ACCESS_KEY_ID: ${{ secrets.AWS_GOVUK_ECR_ACCESS_KEY_ID }}
AWS_GOVUK_ECR_SECRET_ACCESS_KEY: ${{ secrets.AWS_GOVUK_ECR_SECRET_ACCESS_KEY }}
trigger-deploy-to-integration:
name: Trigger deploy to integration
needs: build-and-publish-image
uses: alphagov/govuk-infrastructure/.github/workflows/deploy.yaml@main
with:
imageTag: ${{ needs.build-and-publish-image.outputs.imageTag }}
manualDeploy: ${{ 'main' != github.event.inputs.gitRef }}
secrets:
WEBHOOK_TOKEN: ${{ secrets.ARGO_EVENTS_WEBHOOK_TOKEN }}
WEBHOOK_URL: ${{ secrets.ARGO_EVENTS_WEBHOOK_URL }}