|
79 | 79 | install: true |
80 | 80 | - name: Inject slug/short variables |
81 | 81 | uses: rlespinasse/[email protected] |
82 | | - - name: Install cosign |
83 | | - if: github.event_name != 'pull_request' |
84 | | - uses: sigstore/cosign-installer@f3c664df7af409cb4873aa5068053ba9d61a57b6 #v2.6.0 |
85 | | - with: |
86 | | - cosign-release: 'v1.13.1' |
87 | 82 | - name: Tailscale |
88 | 83 | uses: tailscale/github-action@7bd8039bf25c23c4ab1b8d6e2cc2da2280601966 |
89 | 84 | with: |
@@ -150,39 +145,6 @@ jobs: |
150 | 145 | labels: ${{ steps.meta.outputs.labels || steps.meta-pr.outputs.labels }} |
151 | 146 | cache-from: type=registry,ref=registry.internal.huggingface.tech/api-inference/community/text-generation-inference:cache,mode=min |
152 | 147 | cache-to: type=registry,ref=registry.internal.huggingface.tech/api-inference/community/text-generation-inference:cache,mode=min |
153 | | - # Sign the resulting Docker image digest except on PRs. |
154 | | - # This will only write to the public Rekor transparency log when the Docker |
155 | | - # repository is public to avoid leaking data. |
156 | | - - name: Sign the published Docker image |
157 | | - if: ${{ github.event_name != 'pull_request' }} |
158 | | - env: |
159 | | - COSIGN_EXPERIMENTAL: "true" |
160 | | - # This step uses the identity token to provision an ephemeral certificate |
161 | | - # against the sigstore community Fulcio instance. |
162 | | - run: echo "${{ steps.meta.outputs.tags }}" | xargs -I {} cosign sign {}@${{ steps.build-and-push.outputs.digest }} |
163 | | - - name: Run Trivy in GitHub SBOM mode and submit results to Dependency Graph |
164 | | - uses: aquasecurity/trivy-action@master |
165 | | - if: ${{ github.event_name != 'pull_request' }} |
166 | | - with: |
167 | | - image-ref: 'ghcr.io/huggingface/text-generation-inference:sha-${{ env.GITHUB_SHA_SHORT }}' |
168 | | - format: 'github' |
169 | | - output: 'dependency-results.sbom.json' |
170 | | - github-pat: ${{ secrets.GITHUB_TOKEN }} |
171 | | - scanners: 'vuln' |
172 | | - - name: Run Trivy vulnerability scanner |
173 | | - uses: aquasecurity/trivy-action@master |
174 | | - if: ${{ github.event_name != 'pull_request' }} |
175 | | - with: |
176 | | - image-ref: 'ghcr.io/huggingface/text-generation-inference:sha-${{ env.GITHUB_SHA_SHORT }}' |
177 | | - format: 'sarif' |
178 | | - output: 'trivy-results.sarif' |
179 | | - severity: 'CRITICAL' |
180 | | - scanners: 'vuln' |
181 | | - - name: Upload Trivy scan results to GitHub Security tab |
182 | | - uses: github/codeql-action/upload-sarif@v2 |
183 | | - if: ${{ github.event_name != 'pull_request' }} |
184 | | - with: |
185 | | - sarif_file: 'trivy-results.sarif' |
186 | 148 |
|
187 | 149 | integration-tests: |
188 | 150 | concurrency: |
|
0 commit comments