-
Notifications
You must be signed in to change notification settings - Fork 38
feat(workflows): add orchestration workflows and documentation #29
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
daa9470
7418992
e40ca93
b930aa2
3a34806
2a2a93e
d5a3a04
0e5d132
4268efa
d0d431e
a19e83f
0e08afc
05878ce
8980f4f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -12,7 +12,7 @@ on: | |||||||||||||
| description: 'Comma-separated list of dependency types to check' | ||||||||||||||
|
||||||||||||||
| description: 'Comma-separated list of dependency types to check' | |
| description: 'Comma-separated list of dependency types to check. Valid values: github-actions, npm, pip, containers. Default is github-actions. (Parameter is passed as IncludeTypes to the script.)' |
WilliamBerryiii marked this conversation as resolved.
Show resolved
Hide resolved
Copilot
AI
Nov 14, 2025
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.
The workflow input parameter is named dependency-types (line 10-15) but it's being passed to the PowerShell script as IncludeTypes (line 92). While this might work if the script parameter is actually named IncludeTypes, the naming inconsistency is confusing.
According to the script documentation in Test-DependencyPinning.ps1 (line 32-33 in this PR), the parameter is indeed .PARAMETER IncludeTypes with description "Comma-separated list of dependency types to check."
For clarity and consistency:
- Either rename the workflow input to
include-typesto match the script parameter naming - Or add a comment explaining the parameter name mapping
- Update the workflow input description to match the script's parameter description exactly
WilliamBerryiii marked this conversation as resolved.
Show resolved
Hide resolved
Copilot
AI
Nov 14, 2025
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.
The script exit code from the JSON format run ($jsonExitCode = $LASTEXITCODE) is captured but never used. This means if the first run fails, the workflow will continue to generate SARIF format and then succeed even if it shouldn't have. The script's exit code should be checked and honored.
Add after line 102:
if ($jsonExitCode -ne 0) {
Write-Host "JSON validation failed with exit code $jsonExitCode"
exit $jsonExitCode
}| $jsonExitCode = $LASTEXITCODE | |
| $jsonExitCode = $LASTEXITCODE | |
| if ($jsonExitCode -ne 0) { | |
| Write-Host "JSON validation failed with exit code $jsonExitCode" | |
| exit $jsonExitCode | |
| } |
Copilot
AI
Nov 14, 2025
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.
The JSON format script run captures the exit code ($jsonExitCode = $LASTEXITCODE on line 102) but never uses it. If the JSON validation fails, the workflow continues to generate SARIF format and process results as if everything succeeded. This is problematic because:
- A failed JSON run means the validation found issues and the script should have exited with code 1 (when
FailOnUnpinnedis true) - Running SARIF generation after a failure may produce incorrect or incomplete results
- The workflow will ultimately succeed even though validation failed
The captured exit code should be checked and the workflow should fail immediately if non-zero:
& scripts/security/Test-DependencyPinning.ps1 @params
$jsonExitCode = $LASTEXITCODE
if ($jsonExitCode -ne 0) {
Write-Host "JSON validation failed with exit code $jsonExitCode"
exit $jsonExitCode
}| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| name: Main Branch CI | ||
WilliamBerryiii marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| workflow_dispatch: | ||
|
|
||
| # Minimal permissions for security | ||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| spell-check: | ||
| name: Spell Check | ||
| uses: ./.github/workflows/spell-check.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
|
|
||
| markdown-lint: | ||
| name: Markdown Lint | ||
| uses: ./.github/workflows/markdown-lint.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
|
|
||
| table-format: | ||
| name: Table Format Check | ||
| uses: ./.github/workflows/table-format.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
|
|
||
| dependency-pinning-scan: | ||
| name: Dependency Pinning Scan | ||
| uses: ./.github/workflows/dependency-pinning-scan.yml | ||
| permissions: | ||
| contents: read | ||
| security-events: write | ||
| with: | ||
| soft-fail: false | ||
| upload-sarif: true | ||
| upload-artifact: true | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,85 @@ | ||
| name: PR Validation | ||
WilliamBerryiii marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| on: | ||
| pull_request: | ||
| types: [opened, synchronize, reopened] | ||
| branches: | ||
| - main | ||
| - develop | ||
| workflow_dispatch: | ||
|
|
||
| # Minimal permissions for security | ||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| spell-check: | ||
| name: Spell Check | ||
| uses: ./.github/workflows/spell-check.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
|
|
||
| markdown-lint: | ||
| name: Markdown Lint | ||
| uses: ./.github/workflows/markdown-lint.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
|
|
||
| table-format: | ||
| name: Table Format Check | ||
| uses: ./.github/workflows/table-format.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
|
|
||
| psscriptanalyzer: | ||
| name: PowerShell Lint | ||
| uses: ./.github/workflows/ps-script-analyzer.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
| changed-files-only: true | ||
|
|
||
| frontmatter-validation: | ||
| name: Frontmatter Validation | ||
| uses: ./.github/workflows/frontmatter-validation.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
| changed-files-only: true | ||
| skip-footer-validation: false | ||
| warnings-as-errors: true | ||
|
|
||
| link-lang-check: | ||
| name: Link Language Check | ||
| uses: ./.github/workflows/link-lang-check.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: false | ||
|
|
||
| markdown-link-check: | ||
| name: Markdown Link Check | ||
| uses: ./.github/workflows/markdown-link-check.yml | ||
| permissions: | ||
| contents: read | ||
| with: | ||
| soft-fail: true | ||
|
|
||
| dependency-pinning-check: | ||
| name: Validate Dependency Pinning | ||
| uses: ./.github/workflows/dependency-pinning-scan.yml | ||
| permissions: | ||
| contents: read | ||
| security-events: write | ||
| with: | ||
| soft-fail: false | ||
| upload-sarif: true | ||
| upload-artifact: false | ||
Uh oh!
There was an error while loading. Please reload this page.