Skip to content

sync pipelineruns with konflux-central - ca42384, triggered_by: https… #4112

sync pipelineruns with konflux-central - ca42384, triggered_by: https…

sync pipelineruns with konflux-central - ca42384, triggered_by: https… #4112

Workflow file for this run

# https://github.com/ruivieira/trustyai-explainability-python/blob/main/.github/workflows/security.yaml
---
name: Security
"on":
push:
branches:
- main
- stable
- 'rhoai-*'
pull_request:
schedule:
- cron: '0 5 * * 3'
workflow_dispatch:
jobs:
build:
name: Trivy scan (fs)
if: github.event_name != 'schedule'
runs-on: ubuntu-26.04
permissions:
contents: read
security-events: write
steps:
- name: Checkout code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Trivy scan
uses: aquasecurity/trivy-action@ed142fd0673e97e23eac54620cfb913e5ce36c25 # v0.36.0
with:
version: 'v0.73.0'
scan-type: 'fs'
trivy-config: trivy.yaml
format: 'sarif'
output: 'trivy-results.sarif'
exit-code: '0'
- name: Update Security tab
uses: github/codeql-action/upload-sarif@d1ba80a13dd99fba24a470575428917156a28b43 # v4.37.5
with:
sarif_file: 'trivy-results.sarif'
scheduled-scan:
name: Trivy scan (fs) [${{ matrix.ref }}]
# `schedule` only ever fires against the default branch, so a plain cron
# trigger would never re-scan the rhoai-* release branches once they go
# quiet. Sweep the active ones explicitly instead. Those branches only
# exist on the downstream repo, so skip this on forks/upstream.
if: github.event_name == 'schedule' && github.repository == 'red-hat-data-services/notebooks'
runs-on: ubuntu-26.04
permissions:
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
ref: [main, rhoai-3.5, rhoai-3.4, rhoai-3.3, rhoai-2.25]
steps:
- name: Checkout code
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
ref: ${{ matrix.ref }}
persist-credentials: false
- name: Resolve checked-out commit
id: commit
run: echo "sha=$(git rev-parse HEAD)" >> "$GITHUB_OUTPUT"
- name: Trivy scan
uses: aquasecurity/trivy-action@ed142fd0673e97e23eac54620cfb913e5ce36c25 # v0.36.0
with:
version: 'v0.73.0'
scan-type: 'fs'
trivy-config: trivy.yaml
format: 'sarif'
output: 'trivy-results.sarif'
exit-code: '0'
- name: Update Security tab
uses: github/codeql-action/upload-sarif@d1ba80a13dd99fba24a470575428917156a28b43 # v4.37.5
with:
sarif_file: 'trivy-results.sarif'
# Required here (unlike the push/pull_request job above): matrix.ref
# points at a branch other than the one that triggered this run, so
# the commit info can't be inferred from github context.
ref: refs/heads/${{ matrix.ref }}
sha: ${{ steps.commit.outputs.sha }}