@@ -63,13 +63,13 @@ jobs:
63
63
setup-build :
64
64
outputs :
65
65
matrix : ${{ steps.build-matrix.outputs.matrix }}
66
- runs-on : ubuntu-latest
66
+ runs-on : ${{ github.repository_owner == 'intel' && 'intel- ubuntu-latest' || 'ubuntu-latest' }}
67
67
steps :
68
68
- name : Harden Runner
69
- uses : step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12 .1
69
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9 .1
70
70
with :
71
71
egress-policy : audit
72
- - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
72
+ - uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
73
73
- name : Set Matrix
74
74
id : build-matrix
75
75
run : echo "matrix=$(jq -c . < ${{ inputs.group_dir }}/.actions.json)" >> $GITHUB_OUTPUT
@@ -87,18 +87,13 @@ jobs:
87
87
group : ${{ steps.build-group.outputs.container-group }}
88
88
steps :
89
89
- uses : jlumbroso/free-disk-space@54081f138730dfa15788a46383842cd2f914a1be # v1.3.1
90
- - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
90
+ - uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
91
91
if : ${{ !inputs.no_build }}
92
- - uses : azure/ docker- login@15c4aadf093404726ab2ff205b2cdd33fa6d054c # v2
92
+ - uses : docker/ login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
93
93
with :
94
- login-server : ${{ secrets.REGISTRY }}
94
+ registry : ${{ secrets.REGISTRY }}
95
95
username : ${{ secrets.REGISTRY_USER }}
96
96
password : ${{ secrets.REGISTRY_TOKEN }}
97
- # - uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
98
- # with:
99
- # registry: ${{ secrets.REGISTRY }}
100
- # username: ${{ secrets.REGISTRY_USER }}
101
- # password: ${{ secrets.REGISTRY_TOKEN }}
102
97
if : ${{ !inputs.no_build }}
103
98
- name : Build Container Group
104
99
if : ${{ !inputs.no_build }}
@@ -117,15 +112,15 @@ jobs:
117
112
setup-scan :
118
113
needs : [build-containers]
119
114
if : ${{ github.event_name == 'pull_request' }}
120
- runs-on : ubuntu-latest
115
+ runs-on : ${{ github.repository_owner == 'intel' && 'intel- ubuntu-latest' || 'ubuntu-latest' }}
121
116
outputs :
122
117
matrix : ${{ steps.scan-matrix.outputs.matrix }}
123
118
steps :
124
119
- name : Harden Runner
125
- uses : step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12 .1
120
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9 .1
126
121
with :
127
122
egress-policy : audit
128
- - uses : actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
123
+ - uses : actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
129
124
with :
130
125
path : matrix
131
126
- name : Set Matrix
@@ -140,44 +135,27 @@ jobs:
140
135
container : ${{ fromJSON(needs.setup-scan.outputs.matrix) }}
141
136
fail-fast : false
142
137
steps :
143
- - uses : jlumbroso/free-disk-space@54081f138730dfa15788a46383842cd2f914a1be # v1.3.1
144
138
- name : Harden Runner
145
- uses : step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12 .1
139
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9 .1
146
140
with :
147
141
egress-policy : audit
148
- - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
149
- - uses : azure/ docker- login@15c4aadf093404726ab2ff205b2cdd33fa6d054c # v2
142
+ - uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
143
+ - uses : docker/ login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
150
144
with :
151
- login-server : ${{ secrets.REGISTRY }}
145
+ registry : ${{ secrets.REGISTRY }}
152
146
username : ${{ secrets.REGISTRY_USER }}
153
147
password : ${{ secrets.REGISTRY_TOKEN }}
154
- # - uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
155
- # with:
156
- # registry: ${{ secrets.REGISTRY }}
157
- # username: ${{ secrets.REGISTRY_USER }}
158
- # password: ${{ secrets.REGISTRY_TOKEN }}
159
148
- name : Pull Image
160
149
run : docker pull ${{ secrets.REGISTRY }}/${{ secrets.REPO }}:${{ matrix.container }}
161
- - uses : actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
162
- with :
163
- path : ${{ github.workspace }}/.cache/trivy
164
- key : ${{ github.head_ref || github.ref_name }}-trivy
165
150
- name : Scan Container
166
- uses : aquasecurity/trivy-action@76071ef0d7ec797419534a183b498b4d6366cf37 # v0.31.0
167
- env :
168
- TRIVY_DB_REPOSITORY : public.ecr.aws/aquasecurity/trivy-db
169
- TRIVY_JAVA_DB_REPOSITORY : public.ecr.aws/aquasecurity/trivy-java-db
151
+ uses : intel/ai-containers/.github/scan@main
170
152
with :
171
- cache : true
172
- format : sarif
173
- github-pat : ${{ secrets.GITHUB_TOKEN }}
174
153
image-ref : ${{ secrets.REGISTRY }}/${{ secrets.REPO }}:${{ matrix.container }}
175
154
output : ${{ matrix.container }}-scan.sarif
176
- timeout : 30m0s
177
155
- name : Cleanup
178
156
if : always()
179
157
run : docker rmi -f ${{ secrets.REGISTRY }}/${{ secrets.REPO }}:${{ matrix.container }}
180
- - uses : github/codeql-action/upload-sarif@ce28f5bb42b7a9f2c824e633a3f6ee835bab6858 # v3.29 .0
158
+ - uses : github/codeql-action/upload-sarif@eb055d739abdc2e8de2e5f4ba1a8b246daa779aa # v3.26 .0
181
159
with :
182
160
sarif_file : ' ${{ matrix.container }}-scan.sarif'
183
161
category : ' ${{ matrix.container }}'
@@ -187,15 +165,15 @@ jobs:
187
165
# ###################################################################################################
188
166
setup-test :
189
167
needs : [build-containers]
190
- runs-on : ubuntu-latest
168
+ runs-on : ${{ github.repository_owner == 'intel' && 'intel- ubuntu-latest' || 'ubuntu-latest' }}
191
169
outputs :
192
170
matrix : ${{ steps.test-matrix.outputs.matrix }}
193
171
steps :
194
172
- name : Harden Runner
195
- uses : step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12 .1
173
+ uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9 .1
196
174
with :
197
175
egress-policy : audit
198
- - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
176
+ - uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
199
177
- name : Get Recipes
200
178
id : test-matrix
201
179
run : echo "matrix=$(find ${{ inputs.group_dir }} -type f -name 'tests.yaml' -exec dirname {} \; | jq -R -s -c 'split("\n")[:-1]')" >> $GITHUB_OUTPUT
@@ -209,20 +187,15 @@ jobs:
209
187
experimental : [true]
210
188
fail-fast : false
211
189
steps :
212
- - uses : step-security/harden-runner@002fdce3c6a235733a90a27c80493a3241e56863 # v2.12 .1
190
+ - uses : step-security/harden-runner@5c7944e73c4c2a096b17a9cb74d65b6c2bbafbde # v2.9 .1
213
191
with :
214
192
egress-policy : audit
215
- - uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
216
- - uses : azure/ docker- login@15c4aadf093404726ab2ff205b2cdd33fa6d054c # v2
193
+ - uses : actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
194
+ - uses : docker/ login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
217
195
with :
218
- login-server : ${{ secrets.REGISTRY }}
196
+ registry : ${{ secrets.REGISTRY }}
219
197
username : ${{ secrets.REGISTRY_USER }}
220
198
password : ${{ secrets.REGISTRY_TOKEN }}
221
- # - uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
222
- # with:
223
- # registry: ${{ secrets.REGISTRY }}
224
- # username: ${{ secrets.REGISTRY_USER }}
225
- # password: ${{ secrets.REGISTRY_TOKEN }}
226
199
- name : Test Container Group
227
200
uses : intel/ai-containers/test-runner@main
228
201
with :
0 commit comments