Skip to content

ci: add cron job to cache trivy db #5893

ci: add cron job to cache trivy db

ci: add cron job to cache trivy db #5893

Workflow file for this run

name: "CodeQL Scan"
on:
push:
branches:
- main
- dev
- 1.0.0*
pull_request:
branches:
- main
- dev
- 1.0.0*
schedule:
- cron: "30 1 * * 0"
workflow_dispatch:
permissions: read-all
jobs:
CodeQL-Build:
runs-on: ubuntu-latest
permissions:
security-events: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # tag=3.0.2
- name: setup go environment
uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: "1.22"
- name: Initialize CodeQL
uses: github/codeql-action/init@662472033e021d55d94146f66f6058822b0b39fd # tag=v3.27.0
with:
languages: go
- name: Run tidy
run: go mod tidy
- name: Build CLI
run: make build
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@662472033e021d55d94146f66f6058822b0b39fd # tag=v3.27.0