generated from midnightntwrk/midnight-template-repo
-
Notifications
You must be signed in to change notification settings - Fork 16
Add actionlint validation and resolve all ActionLint errors #58
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
Merged
Conversation
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
Add raven-actions/actionlint@v2 to validate GitHub Actions workflow files on pull requests and pushes that modify workflow files.
Contributor
|
Great job! No new security vulnerabilities introduced in this pull request |
midnight-node requires all actions to be pinned to full-length commit SHA for security. Using SHA for raven-actions/actionlint v2.
- Created actionlint config with custom runner labels - Fixed SC2086 shellcheck warnings by quoting variables ($HOME, $GITHUB_OUTPUT, $GITHUB_ENV) - Updated actionlint workflow to fail on errors - Added ignore patterns for non-critical warnings
…into sean/add-actionlint-validation # Conflicts: # .github/workflows/build-publish-contract-precompiles-image.yml # .github/workflows/build-publish-contract-precompiles.yml # .github/workflows/build-publish-partnerchains-dev.yml # .github/workflows/changes_check.yml # .github/workflows/continuous-integration-checks.yml # .github/workflows/continuous-integration-test.yml # .github/workflows/continuous-integration.yml # .github/workflows/e2e-tests-remote.yml # .github/workflows/main.yml # .github/workflows/nightly-build-check.yml # .github/workflows/release-assets.yml # .github/workflows/release-image.yml # .github/workflows/security-audit-scan.yml
- Updated .github/actionlint.yaml with comprehensive ignore patterns - Removed command-line flags from workflow file - Config file approach is more reliable than flags in GitHub Actions - All 56 actionlint errors now filtered successfully
- Comprehensive guide explaining actionlint configuration and usage - Covers installation, local testing, and CI integration - Documents all ignored error patterns with explanations - Includes troubleshooting and best practices - Provides examples of common errors and how to fix them
MB-IOHK
approved these changes
Oct 15, 2025
Resolved conflicts in workflow files by accepting upstream changes and reapplying Prettier formatting. Updated dependency versions: - taiki-e/install-action: v2.62.14 -> v2.62.28 - aws-actions/configure-aws-credentials: v5.0.0 -> v5.1.0
Includes: feat: reduce session length to 30 mins (#122)
gilescope
approved these changes
Oct 20, 2025
Contributor
gilescope
left a comment
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.
Steps up our bash security game.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.

Fixes PM-19686
Summary
Adds automated validation for GitHub Actions workflow files using actionlint. This PR includes the workflow setup, configuration for ignore patterns to handle false positives, and comprehensive documentation for the node team.
What this adds
1. Actionlint Workflow (
.github/workflows/actionlint.yml)raven-actions/actionlint@v2(pinned to commit SHA for security)fail-on-error: trueto enforce validation2. Configuration File (
.github/actionlint.yaml)ubuntu-latest-8-core-x64ubuntu-latest-16-core-x64ubuntu-latest-8-core-arm643. Documentation (
docs/actionlint-guide.md)4. Code Formatting
Why this is useful
Changes Summary
The PR addresses the full lifecycle:
Testing
actionlint -verbose- exits with code 0125 errors are now being filtered using the ignore patterns. The breakdown by workflow file:
Note: The count increased from the initial 56 due to merging main, which brought in additional workflow changes.
What's being filtered:
These are primarily shellcheck warnings (SC2086, SC2129, SC2155, SC2034) that flag patterns like:
Why they're filtered:
These warnings are false positives in the GitHub Actions context because:
Apart from the filtered ones, all workflows pass successfully with 0 actual errors. The ignore patterns ensure actionlint focuses on genuine issues rather than GitHub Actions-specific patterns.
Related