Add CodeQL workflow for S360 compliance - #267
Conversation
|
Thanks for the contribution! This pull request comes from a fork, so the Azure E2E workflow is intentionally skipped for security reasons. Merge will remain blocked until the E2E tests have been run from a branch in the Maintainer options:
We do not run Azure E2E directly from fork PR code because it requires Azure OIDC access. |
There was a problem hiding this comment.
Pull request overview
Adds a GitHub Actions CodeQL workflow to ensure the repository publishes a fresh Go CodeQL snapshot regularly (push/PR to main, weekly schedule, and manual dispatch) to meet S360 CodeQL compliance expectations.
Changes:
- Introduces
.github/workflows/codeql.ymlto run CodeQL analysis for Go onpush,pull_request,schedule, andworkflow_dispatch. - Pins GitHub Actions by SHA and configures
security-events: writepermissions for SARIF upload.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| - name: Checkout repository | ||
| uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5.0.1 | ||
| with: | ||
| submodules: true | ||
| fetch-depth: 0 |
| - name: Initialize CodeQL | ||
| uses: github/codeql-action/init@c793b717bc78562f491db7b0e93a3a178b099162 | ||
| with: | ||
| languages: ${{ matrix.language }} | ||
|
|
||
| - name: Autobuild | ||
| uses: github/codeql-action/autobuild@c793b717bc78562f491db7b0e93a3a178b099162 |
|
You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool. What Enabling Code Scanning Means:
For more information about GitHub Code Scanning, check out the documentation. |
What / Why
AKSFlexNode(modulegithub.com/Azure/AKSFlexNode, primarily Go) has no CodeQL workflow, so it is flagged non-compliant for S360 standard Microsoft.Security.CodeQL.10000 (every active, production repo must publish a non-expired CodeQL snapshot per language).This adds
.github/workflows/codeql.ymlthat runs CodeQL Goautobuildon:main,cron: "0 7 * * 1"), so a fresh snapshot is uploaded even without commits,workflow_dispatch.Pattern mirrors the existing
Azure/gpu-provisionerCodeQL workflow (pinned action SHAs,security-events: write, autobuild for Go).Notes
matrix.languagelist.gosnapshot is attributed to this repo (allow 48–72h).