ci: prove the action bumps on github before main #63
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # CodeQL static analysis (Go), results to the Security tab. | |
| name: codeql | |
| on: | |
| push: | |
| branches: [main, 'ci/**'] # ci/** proves a workflow change green before it lands on main | |
| pull_request: | |
| branches: [main] | |
| schedule: | |
| - cron: '27 3 * * 1' # Mondays 03:27 UTC | |
| workflow_dispatch: # so a run can be kicked off without inventing a commit | |
| permissions: {} | |
| jobs: | |
| analyze: | |
| name: analyze (go) | |
| runs-on: ubuntu-latest | |
| permissions: | |
| security-events: write # upload CodeQL results | |
| contents: read | |
| actions: read | |
| steps: | |
| # Deny egress by default; see ci.yml. uploads.github.com is where the SARIF result goes, | |
| # storage.googleapis.com is where setup-go falls back for a toolchain the runner has | |
| # not cached. | |
| - name: Harden the runner | |
| uses: step-security/harden-runner@05e31511f85b41b11d1cf0ef85d0992719546e2c # v2.21.0 | |
| with: | |
| egress-policy: block | |
| allowed-endpoints: > | |
| api.github.com:443 | |
| github.com:443 | |
| proxy.golang.org:443 | |
| release-assets.githubusercontent.com:443 | |
| storage.googleapis.com:443 | |
| uploads.github.com:443 | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Set up Go | |
| uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0 | |
| with: | |
| go-version: '1.26.6' | |
| check-latest: false | |
| - name: Initialize CodeQL | |
| uses: github/codeql-action/init@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd # v4.37.7 | |
| with: | |
| languages: go | |
| build-mode: autobuild | |
| - name: Analyze | |
| uses: github/codeql-action/analyze@ff2f1c621b7f889edc0d3c761ac2e6a3f8cdb0dd # v4.37.7 | |
| with: | |
| category: "/language:go" |