-
Notifications
You must be signed in to change notification settings - Fork 35
97 lines (89 loc) · 2.62 KB
/
production.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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
name: Deploy Production Branch
on:
push:
branches:
- main
schedule:
- cron: "0 6,18 * * *"
workflow_dispatch:
inputs:
skip-cache:
description: "Skip Cache"
required: true
default: true
type: boolean
force-deploy:
description: "Deploy even if tests fail"
required: true
default: false
type: boolean
jobs:
cache-modifier:
uses: ./.github/workflows/cache-modifier.yml
with:
skip-cache: ${{ github.event.inputs.skip-cache }}
call-atlas:
uses: ./.github/workflows/realm.yml
secrets: inherit
needs: cache-modifier
with:
sha: ${{ github.sha }}
environment: production
runner-label: ${{ vars.PRODUCTION_RUNNER_LABEL }}
call-test-api:
uses: ./.github/workflows/test-api.yml
needs: cache-modifier
secrets: inherit
with:
sha: ${{ github.sha }}
environment: production
call-test-build:
uses: ./.github/workflows/test-build.yml
secrets: inherit
needs: [cache-modifier, call-atlas]
with:
sha: ${{ github.sha }}
environment: production
netlify-context: production
runner-label: ${{ vars.PRODUCTION_RUNNER_LABEL }}
cache-modifier: ${{ needs.cache-modifier.outputs.cache-modifier }}
call-test:
uses: ./.github/workflows/test.yml
needs: [cache-modifier, call-test-build]
secrets: inherit
with:
sha: ${{ github.sha }}
environment: production
runner-label: ${{ vars.PRODUCTION_RUNNER_LABEL }}
cache-modifier: ${{ needs.cache-modifier.outputs.cache-modifier }}
call-test-playwright:
uses: ./.github/workflows/test-playwright.yml
needs: call-test-build
secrets: inherit
with:
sha: ${{ github.sha }}
environment: production
runner-label: ${{ vars.PRODUCTION_RUNNER_LABEL }}
call-test-playwright-full:
if: ${{ !failure() && !cancelled() }}
uses: ./.github/workflows/test-playwright-full.yml
needs: [cache-modifier]
secrets: inherit
with:
sha: ${{ github.sha }}
environment: production
runner-label: ${{ vars.PREVIEW_RUNNER_LABEL }}
call-deploy:
if: (inputs.force-deploy == true || success()) && !cancelled()
uses: ./.github/workflows/deploy.yml
needs: [cache-modifier, call-test, call-test-api, call-test-playwright]
secrets: inherit
permissions:
pull-requests: write
with:
environment: production
sha: ${{ github.sha }}
netlify-context: production
netlify-alias:
runner-label: ${{ vars.PRODUCTION_RUNNER_LABEL }}
cache-modifier: ${{ needs.cache-modifier.outputs.cache-modifier }}