generated from communitiesuk/funding-service-design-TEMPLATE
-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (42 loc) · 1.4 KB
/
deployment_cd_test_prod.yml
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
37
38
39
40
41
42
43
44
45
name: Deployment pipeline for post-award services
run-name: Deploy branch ${{ github.ref_name }} to test and prod (${{ format('SHA:{0}', github.sha) }})
on:
push:
branches:
- main
jobs:
paketo_build:
name: Build post-award image
permissions:
packages: write
concurrency: build-${{ github.sha }}
uses: communitiesuk/funding-service-design-workflows/.github/workflows/package.yml@main
with:
assets_required: true
version_to_build: ${{ github.sha }}
owner: ${{ github.repository_owner }}
application: ${{ github.event.repository.name }}
test_deploy:
name: Deploy to test
needs: [ paketo_build ]
concurrency:
group: deploy-test
cancel-in-progress: false
uses: ./.github/workflows/aws_copilot_deployment.yml
with:
copilot_environment: test
image_location: ghcr.io/${{ github.repository_owner }}/${{ github.event.repository.name }}:${{ github.sha }}
run_e2e_tests: true
secrets: inherit
prod_deploy:
if: ${{ github.ref_name == 'main' }}
name: Deploy to prod
needs: [ paketo_build, test_deploy ]
concurrency:
group: deploy-prod
cancel-in-progress: false
uses: ./.github/workflows/aws_copilot_deployment.yml
with:
copilot_environment: prod
image_location: ghcr.io/${{ github.repository_owner }}/${{ github.event.repository.name }}:${{ github.sha }}
secrets: inherit