-
Notifications
You must be signed in to change notification settings - Fork 38
131 lines (125 loc) · 5.52 KB
/
InitDev Implementation.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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
name: Trigger InitDev workflows in Implementation repo
on:
pull_request:
branches:
- main-6x
workflow_dispatch:
env:
EDFI_ODS_IMP_TOKEN: ${{ secrets.REPO_DISPATCH_TOKEN }}
REPOSITORY_OWNER: ${{ GITHUB.REPOSITORY_OWNER }}
HEAD_REF: ${{ GITHUB.HEAD_REF }}
REF_NAME: ${{ GITHUB.REF_NAME }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Check for Repo Dispatch Token
if: ${{ env.REPOSITORY_OWNER == 'Ed-Fi-Alliance-OSS' && env.EDFI_ODS_IMP_TOKEN == '' }}
run: |
echo "::error::Missing GitHub Token"
exit 1
- name: Checkout Ed-Fi-ODS
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
with:
repository: Ed-Fi-Alliance-OSS/Ed-Fi-ODS
path: Ed-Fi-ODS/
- name: Is pull request branch exists in Ed-Fi-ODS
working-directory: ./Ed-Fi-ODS/
shell: pwsh
run: |
.\build.githubactions.ps1 CheckoutBranch -RelativeRepoPath "."
- name: Checkout Ed-Fi-ODS-Implementation
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4
with:
repository: Ed-Fi-Alliance-OSS/Ed-Fi-ODS-Implementation
path: Ed-Fi-ODS-Implementation/
- name: Is pull request branch exists in Ed-Fi-ODS-Implementation
working-directory: ./Ed-Fi-ODS/
shell: pwsh
run: |
.\build.githubactions.ps1 CheckoutBranch -RelativeRepoPath "../Ed-Fi-ODS-Implementation"
- name: Set Current Branch Environment Variable
shell: pwsh
run: |
$current_branch = '${{env.REF_NAME}}'
if ($current_branch -like "*/merge"){
$current_branch = '${{env.HEAD_REF}}'
}
Write-Host "Current Branch: $current_branch"
echo "current_branch=$current_branch" >> $Env:GITHUB_ENV
- name: Dispatch InitDev, Unit tests, Integration tests, Package
uses: Codex-/return-dispatch@03a7fcd260cce601805567f86c892bd06d2719e1 #v1.12.0
id: return_dispatch_initdev_unit_tests_integration_tests_package
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
ref: ${{ env.current_branch }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
workflow: InitDev, Unit tests, Integration tests, Package.yml
workflow_timeout_seconds: 4800
- name: Dispatch InitDev Postgres, Unit tests, Integration tests
uses: Codex-/return-dispatch@03a7fcd260cce601805567f86c892bd06d2719e1 #v1.12.0
id: return_dispatch_initdev_postgres_unit_tests_integration_tests
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
ref: ${{ env.current_branch }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
workflow: InitDev Postgres, Unit tests, Integration tests.yml
workflow_timeout_seconds: 4800
- name: Dispatch InitDev, Smoke Tests
uses: Codex-/return-dispatch@03a7fcd260cce601805567f86c892bd06d2719e1 #v1.12.0
id: return_dispatch_initdev_smoketests
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
ref: ${{ env.current_branch }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
workflow: InitDev, Smoke Tests.yml
workflow_timeout_seconds: 4800
- name: Dispatch InitDev Postgres, Smoke Tests
uses: Codex-/return-dispatch@03a7fcd260cce601805567f86c892bd06d2719e1 #v1.12.0
id: return_dispatch_initdev_postgres_smoketests
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
ref: ${{ env.current_branch }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
workflow: InitDev Postgres, Smoke Tests.yml
workflow_timeout_seconds: 4800
- name: Await to complete the execution for InitDev, Unit tests, Integration tests, Package
uses: Codex-/await-remote-run@d04eeb1e053a19a32037eb0b8ddee6ab4f19790a #v1.7.0
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
run_id: ${{ steps.return_dispatch_initdev_unit_tests_integration_tests_package.outputs.run_id }}
run_timeout_seconds: 4800
poll_interval_ms: 5000
- name: Await to complete the execution for InitDev Postgres, Unit tests, Integration tests
uses: Codex-/await-remote-run@d04eeb1e053a19a32037eb0b8ddee6ab4f19790a #v1.7.0
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
run_id: ${{ steps.return_dispatch_initdev_postgres_unit_tests_integration_tests.outputs.run_id }}
run_timeout_seconds: 4800
poll_interval_ms: 5000
- name: Await to complete the execution for InitDev, Smoke Tests
uses: Codex-/await-remote-run@d04eeb1e053a19a32037eb0b8ddee6ab4f19790a #v1.7.0
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
run_id: ${{ steps.return_dispatch_initdev_smoketests.outputs.run_id }}
run_timeout_seconds: 4800
poll_interval_ms: 5000
- name: Await to complete the execution for InitDev Postgres, Smoke Tests
uses: Codex-/await-remote-run@d04eeb1e053a19a32037eb0b8ddee6ab4f19790a #v1.7.0
with:
token: ${{ env.EDFI_ODS_IMP_TOKEN }}
repo: Ed-Fi-ODS-Implementation
owner: ${{ github.repository_owner }}
run_id: ${{ steps.return_dispatch_initdev_postgres_smoketests.outputs.run_id }}
run_timeout_seconds: 4800
poll_interval_ms: 5000