-
Notifications
You must be signed in to change notification settings - Fork 1
ci: establish enterprise GitHub Actions automation baseline #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
8779d76
5786c85
d088a65
ad6847c
fa7a6a7
7992f5f
56f9181
2e5ed81
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| version: 2 | ||
| updates: | ||
| - package-ecosystem: github-actions | ||
| directory: / | ||
| schedule: {interval: weekly} | ||
| open-pull-requests-limit: 10 |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,45 @@ | ||
| name: CodeQL | ||
| on: | ||
| push: | ||
| pull_request: | ||
| schedule: | ||
| - cron: '23 3 * * 1' | ||
| permissions: | ||
| contents: read | ||
| security-events: write | ||
| jobs: | ||
| detect: | ||
| runs-on: ubuntu-latest | ||
| outputs: | ||
| languages: ${{ steps.lang.outputs.languages }} | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - id: lang | ||
| shell: bash | ||
| run: | | ||
| set -euo pipefail | ||
| langs='' | ||
| [ -n "$(find . -name '*.py' -print -quit)" ] && langs="$langs python" | ||
| [ -n "$(find . -name '*.js' -print -quit)" ] || [ -n "$(find . -name '*.ts' -print -quit)" ] && langs="$langs javascript-typescript" | ||
| [ -f go.mod ] && langs="$langs go" | ||
| [ -f Cargo.toml ] && langs="$langs rust" | ||
| [ -f pom.xml ] || [ -f build.gradle ] && langs="$langs java-kotlin" | ||
| [ -n "$(find . -name '*.c' -print -quit)" ] || [ -n "$(find . -name '*.cpp' -print -quit)" ] && langs="$langs c-cpp" | ||
| [ -n "$langs" ] || langs=' python' | ||
| json="$(jq -cn --arg l "$langs" '$l | split(" ") | map(select(length > 0))')" | ||
| echo "languages=$json" >> "$GITHUB_OUTPUT" | ||
| analyze: | ||
| needs: detect | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| language: ${{ fromJSON(needs.detect.outputs.languages) }} | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - uses: github/codeql-action/init@v3 | ||
| with: | ||
| languages: ${{ matrix.language }} | ||
| build-mode: none | ||
|
|
||
| - uses: github/codeql-action/analyze@v3 | ||
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,9 @@ | ||||||
| name: Dependency Review | ||||||
| on: {pull_request:} | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/usr/bin/env bash
set -euo pipefail
actionlint .github/workflows/dependency-review.ymlRepository: CoreyLeath-code/SentinelAI Length of output: 461 Fix the invalid workflow trigger.
Proposed fix-on: {pull_request:}
+on: [pull_request]📝 Committable suggestion
Suggested change
🧰 Tools🪛 actionlint (1.7.12)[error] 2-2: unknown Webhook event "pull_request:". see https://docs.github.com/en/actions/reference/workflows-and-actions/events-that-trigger-workflows#webhook-events for list of all Webhook event names (events) 🤖 Prompt for AI AgentsSources: MCP tools, Linters/SAST tools |
||||||
| permissions: {contents: read, pull-requests: read} | ||||||
| jobs: | ||||||
| review: | ||||||
| runs-on: ubuntu-latest | ||||||
| steps: | ||||||
| - uses: actions/dependency-review-action@v4 | ||||||
| with: {fail-on-severity: high} | ||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎯 Functional Correctness | 🟠 Major | 🏗️ Heavy lift
🧩 Analysis chain
🏁 Script executed:
Repository: CoreyLeath-code/SentinelAI
Length of output: 164
🏁 Script executed:
Repository: CoreyLeath-code/SentinelAI
Length of output: 1908
🌐 Web query:
github codeql-action initialize build-mode none Go Kotlin supported build-mode values💡 Result:
The CodeQL Action does not support the build-mode: none value for either Go or Kotlin [1][2][3]. For compiled languages like Go and Kotlin, the CodeQL Action supports the following build modes: - autobuild: The CodeQL Action attempts to automatically build the source code [4][1]. - manual: You must specify manual build steps in your workflow between the init and analyze steps to build the source code [4][1][5]. While the build-mode: none option is available for certain languages where the database can be created without building the source code (such as interpreted languages and specific compiled languages like C/C++, C#, Java, and Rust), it is explicitly unsupported for Go and Kotlin [1][2][5][3]. If you attempt to use build-mode: none for these languages, the action will fail with an error [6].
Citations:
Use a build mode per detected language.
build-mode: noneblocks CodeQL build setup for Go and Java/Kotlin; with only onebuild-modeinput for the whole matrix, repos that include those languages either fail or miss database creation. Keepnonefor C/C++ no-build scans, but carry a build mode alongside each detected language, such asautobuild/manualfor Go and Java/Kotlin, and pass it as${{ matrix.build-mode }}.🤖 Prompt for AI Agents
Source: MCP tools