Skip to content

[SECURITY] Harden GitHub workflows#346

Merged
John McCall (lowlydba) merged 7 commits intomainfrom
306-devops-create-omf-ruleset-for-all-public-repos
Apr 8, 2026
Merged

[SECURITY] Harden GitHub workflows#346
John McCall (lowlydba) merged 7 commits intomainfrom
306-devops-create-omf-ruleset-for-all-public-repos

Conversation

@lowlydba
Copy link
Copy Markdown
Contributor

@lowlydba John McCall (lowlydba) commented Apr 8, 2026

Resolves 40+ findings from zizmor as workflow security concerns.

After this, the OMF Security Checks required workflow will be enabled to keep a secure baseline (the check is available already on this PR, see below)

Signed-off-by: John McCall <john@overturemaps.org>
Update CI/CD workflows to pin actions to specific commit SHAs and tighten behavior. Added concurrency groups to avoid overlapping runs, adjusted permissions (including id-token for OIDC, pages, and super-linter-specific rights), and moved some job-level permissions into the jobs that need them. Replaced direct uses of expressions in shell strings with explicit env variables (e.g. PR_HEAD_SHA, GITHUB_EVENT_NUMBER) to avoid quoting issues, and updated several action references (checkout, setup-node, configure-pages, upload/download artifacts, deploy-pages, aws credentials, super-linter, etc.) to stable SHAs for reproducibility and security.

Signed-off-by: John McCall <john@overturemaps.org>
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

Super-linter summary

Language Validation result
JAVASCRIPT_ES Pass ✅
MARKDOWN Pass ✅
NATURAL_LANGUAGE Pass ✅
SQLFLUFF Pass ✅

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

🗺️ OMF Docs previews are live!

🆕 Auto-gen schema site (beta) https://staging.overturemaps.org/docs/pr/346/index.html
🗂️ Auto-gen schema ref dev@ce6584f
🌍 Repo schema site https://staging.overturemaps.org/docs/pr/346-no-autogen/index.html
🕐 Updated Apr 08, 2026 14:54 UTC
📝 Commit c3cdaf8

Auto-gen schema site is now available. This is an early preview of a future workflow where we will automatically generate and publish reference docs for the Overture Maps Format schema with every change to the schema repo.
The auto-gen schema site may contain incomplete or inaccurate information as we are still refining the generation process, so please compare against the repo schema site and refer to the linked commit for the most up-to-date source of truth.

Note

♻️ This preview updates automatically with each push to this PR.

@github-advanced-security
Copy link
Copy Markdown

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:

  • The 'Security' tab will display more code scanning analysis results (e.g., for the default branch).
  • Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results.
  • You will be able to see the analysis results for the pull request's branch on this overview once the scans have completed and the checks have passed.

For more information about GitHub Code Scanning, check out the documentation.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR hardens the repository’s GitHub Actions and automation config in response to zizmor findings, primarily by pinning action dependencies, reducing token permissions, and adding concurrency controls to reduce workflow attack surface and improve safety.

Changes:

  • Pin GitHub Actions to full commit SHAs and disable credential persistence where applicable.
  • Scope GITHUB_TOKEN permissions to the minimum required per workflow/job and add concurrency groups to avoid overlapping runs.
  • Update Dependabot configuration to include a cooldown period for update PRs.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
.github/workflows/staging_deploy.yaml Pins actions, scopes permissions to the deploy job, and refactors runtime interpolation in shell steps.
.github/workflows/staging_deploy_cleanup.yaml Adds concurrency and pins AWS auth action; refactors shell interpolation to use env vars.
.github/workflows/production_deploy_documentation.yml Adds concurrency, pins actions, and scopes Pages/OIDC permissions to the deploy job.
.github/workflows/lint.yml Adds concurrency, pins actions, scopes permissions to the linter job, and disables credential persistence on checkout.
.github/dependabot.yml Adds a cooldown configuration to reduce update PR churn.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

Super-linter summary

Language Validation result
JAVASCRIPT_ES Pass ✅
MARKDOWN Pass ✅
NATURAL_LANGUAGE Pass ✅
SQLFLUFF Pass ✅

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me after you resolve all the issues flagged

Update action references across CI workflows to newer patch releases for stability and bug fixes: actions/checkout -> v6.0.2, actions/setup-node -> v6.3.0, aws-actions/configure-aws-credentials -> v6.1.0, and actions/download-artifact -> v8.0.1. Changes touch .github/workflows/lint.yml, production_deploy_documentation.yml, staging_deploy.yaml, and staging_deploy_cleanup.yaml.

Signed-off-by: John McCall <john@overturemaps.org>
Signed-off-by: John McCall <john@overturemaps.org>
…ttps://github.com/OvertureMaps/docs into 306-devops-create-omf-ruleset-for-all-public-repos

Signed-off-by: John McCall <john@overturemaps.org>
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

Super-linter summary

Language Validation result
JAVASCRIPT_ES Pass ✅
MARKDOWN Pass ✅
NATURAL_LANGUAGE Pass ✅
SQLFLUFF Pass ✅

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter

Signed-off-by: John McCall <john@overturemaps.org>
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 8, 2026

Super-linter summary

Language Validation result
JAVASCRIPT_ES Pass ✅
MARKDOWN Pass ✅
NATURAL_LANGUAGE Pass ✅
SQLFLUFF Pass ✅

All files and directories linted successfully

For more information, see the GitHub Actions workflow run

Powered by Super-linter

@lowlydba John McCall (lowlydba) merged commit cba58c2 into main Apr 8, 2026
15 checks passed
@lowlydba John McCall (lowlydba) deleted the 306-devops-create-omf-ruleset-for-all-public-repos branch April 8, 2026 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants