Skip to content

ci: Enable codeql for github actions #1

ci: Enable codeql for github actions

ci: Enable codeql for github actions #1

Workflow file for this run

name: "CodeQL"
on:
push:
branches:
- 'main'
- 'release-v*'
pull_request:
schedule:
- cron: '0 12 * * *'
jobs:
analyze-go:
name: Analyze Go
runs-on: ubuntu-latest
permissions:
actions: read # github/codeql-action/init@v2
security-events: write # github/codeql-action/init@v2
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- uses: ./.github/actions/install-deps
- run: make vulncheck
- uses: github/codeql-action/init@df32e399139a3050671466d7d9b3cbacc1cfd034 # v2.22.8
with:
languages: go
- uses: github/codeql-action/autobuild@df32e399139a3050671466d7d9b3cbacc1cfd034 # v2.22.8
- uses: github/codeql-action/analyze@df32e399139a3050671466d7d9b3cbacc1cfd034 # v2.22.8
# Javascript is added here for evaluating Github Action vulnerabilities
# https://github.blog/2023-08-09-four-tips-to-keep-your-github-actions-workflows-secure/#2-enable-code-scanning-for-workflows
analyze-github-actions:
name: Analyze Github Actions
runs-on: ubuntu-latest
permissions:
actions: read # github/codeql-action/init@v2
security-events: write # github/codeql-action/init@v2
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- uses: github/codeql-action/init@df32e399139a3050671466d7d9b3cbacc1cfd034 # v2.22.8
with:
languages: javascript
config: |
packs:
# Use the latest version of 'codeql-javascript' published by 'advanced-security'
# This will catch things like actions that aren't pinned to a hash
- advanced-security/codeql-javascript
paths:
- '.github/workflows'
- '.github/actions'
- uses: github/codeql-action/analyze@df32e399139a3050671466d7d9b3cbacc1cfd034 # v2.22.8