summaryrefslogtreecommitdiff
path: root/.github/workflows/security.yml
blob: faa19083462def3125240b13868f79c8be0d78c9 (plain)
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
---
name: Security

# yamllint disable-line rule:truthy
on:
  workflow_dispatch:
  schedule:
    - cron: "42 05 * * *"

concurrency:
  group: ${{ github.workflow }}
  cancel-in-progress: false

permissions:
  contents: read

jobs:
  container:
    if: github.repository_owner == 'searxng'
    name: Container
    runs-on: ubuntu-24.04-arm
    permissions:
      security-events: write

    steps:
      - name: Checkout
        uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8  # v5.0.0
        with:
          persist-credentials: "false"

      - name: Sync GHCS from Docker Scout
        uses: docker/scout-action@f8c776824083494ab0d56b8105ba2ca85c86e4de  # v1.18.2
        with:
          organization: "searxng"
          dockerhub-user: "${{ secrets.DOCKERHUB_USERNAME }}"
          dockerhub-password: "${{ secrets.DOCKERHUB_TOKEN }}"
          image: "registry://ghcr.io/searxng/searxng:latest"
          command: "cves"
          sarif-file: "./scout.sarif"
          exit-code: "false"
          write-comment: "false"

      - name: Upload SARIFs
        uses: github/codeql-action/upload-sarif@e296a935590eb16afc0c0108289f68c87e2a89a5  # v4.30.7
        with:
          sarif_file: "./scout.sarif"