Skip to content

chore: Set top-level permissions to read-all#1649

Merged
HofmeisterAn merged 5 commits into
developfrom
feature/add-openssf-scorecard
Mar 6, 2026
Merged

chore: Set top-level permissions to read-all#1649
HofmeisterAn merged 5 commits into
developfrom
feature/add-openssf-scorecard

Conversation

@HofmeisterAn

@HofmeisterAn HofmeisterAn commented Mar 6, 2026

Copy link
Copy Markdown
Collaborator

What does this PR do?

The PR improves some findings after adding the OpenSSF Scorecard to CI.

Why is it important?

-

Related issues

-

Summary by CodeRabbit

  • Chores

    • Stronger branch protection on main and develop (admin enforcement; required status check set to test-report)
    • Added a CI collaborator/bot with write access
    • CI workflows: broader workflow permissions added; attest step made conditional and narrowed to specific package artifacts; draft-release action updated
    • Upgraded Python runtime to 3.11 and bumped documentation build dependency
  • Documentation

    • Docs: minimum Python requirement set to 3.11
    • Theme: configurable search icon, improved nav rendering, enabled code-block copy and TOC permalinks; minor header fixes

@HofmeisterAn HofmeisterAn added the chore A change that doesn't impact the existing functionality, e.g. internal refactorings or cleanups label Mar 6, 2026
@netlify

netlify Bot commented Mar 6, 2026

Copy link
Copy Markdown

Deploy Preview for testcontainers-dotnet ready!

Name Link
🔨 Latest commit aa02f47
🔍 Latest deploy log https://app.netlify.com/projects/testcontainers-dotnet/deploys/69ab27c093c0620009de9e87
😎 Deploy Preview https://deploy-preview-1649--testcontainers-dotnet.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@coderabbitai

coderabbitai Bot commented Mar 6, 2026

Copy link
Copy Markdown

Walkthrough

Repository CI/config updates: branch protection enforces admins; several GitHub Actions workflows gain top-level permissions: read-all; cicd attest step made conditional and artifact path narrowed; Python runtime and mkdocs-material bumped; docs theme templates and mkdocs config adjusted.

Changes

Cohort / File(s) Summary
Branch protection
\.github/settings.yml
Added collaborator testcontainersbot (write); set enforce_admins: true and simplified required status check contexts to test-report for main and develop.
CI/CD workflow
\.github/workflows/cicd.yml
Made Attest step conditional on PUBLISH_NUGET_PACKAGE == 'true'; narrowed subject-path to artifacts/**/nuget/Testcontainers*.nupkg; updated Draft Release action version.
Workflow permissions (global)
\.github/workflows/codeql-analysis.yml, \.github/workflows/scorecard-analysis.yml, \.github/workflows/test-report.yml
Added top-level permissions: read-all to workflows (global default).
Docs theme templates
docs/theme/partials/header.html, docs/theme/partials/nav.html, docs/theme/partials/tc-header.html
Conditional search button rendering and configurable search icon; refactored nav rendering to use imported item.render; minor whitespace/formatting adjustments.
Documentation & site config
mkdocs.yml, docs/contributing_docs.md
Enabled code-block copy and TOC permalinks in mkdocs.yml; raised documented minimum Python from 3.8.0+ to 3.11.0+.
Runtime & deps
runtime.txt, requirements.txt
Updated Python runtime to 3.11; upgraded mkdocs-material from 8.5.11 to 9.7.2.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 I hop through branches where the checks stand tall,
Permissions hum softly, watching over all.
Attest waits on publish as artifacts align,
Docs polish their icons while Python steps to nine-eleven, fine.
I nibble a carrot and bless this tidy vine.

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive The description is incomplete, missing detailed explanations of changes and testing instructions that are recommended in the template. Provide more specific details about which OpenSSF Scorecard findings were addressed and how the top-level permissions changes mitigate them. Include testing steps and rationale.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title 'chore: Set top-level permissions to read-all' accurately and specifically describes the main change across multiple workflow files in the changeset.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/add-openssf-scorecard

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@requirements.txt`:
- Line 3: Your custom theme partials (header.html, nav.html, tc-header.html) are
likely incompatible with mkdocs-material v9.7.2; review upstream v9 template
changes and update those partials to match new block names/structure, merging
any removed/renamed template blocks. In mkdocs.yml explicitly enable any
features that became opt-in in v9 that your site relies on (e.g., add
theme.features entries for content.code.copy, navigation.footer,
content.action.edit as needed). Verify the rest of the theme (palette scheme:
testcontainers) remains unchanged and run a local build to catch template
errors.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 9839dc3c-340d-46f1-9a23-8fc8947fe40d

📥 Commits

Reviewing files that changed from the base of the PR and between e0191f9 and 7ae70a1.

📒 Files selected for processing (8)
  • .github/settings.yml
  • .github/workflows/cicd.yml
  • .github/workflows/codeql-analysis.yml
  • .github/workflows/scorecard-analysis.yml
  • .github/workflows/test-report.yml
  • docs/contributing_docs.md
  • requirements.txt
  • runtime.txt

Comment thread requirements.txt

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.github/settings.yml:
- Around line 179-181: The branch-protection config removed the CodeQL required
check by only listing "test-report" under contexts, making the CodeQL job (named
"analyze (csharp)" in .github/workflows/codeql-analysis.yml) non-blocking;
restore CodeQL as a required status check by adding the CodeQL job name back
into the contexts array (in addition to "test-report") and keep enforce_admins:
true so admins are also blocked; ensure the contexts array includes both
"test-report" and "analyze (csharp)" wherever branch-protection is defined.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 3ac8027f-4428-4f4f-9266-8e8624a30402

📥 Commits

Reviewing files that changed from the base of the PR and between c34e211 and aa02f47.

📒 Files selected for processing (1)
  • .github/settings.yml

Comment thread .github/settings.yml
@HofmeisterAn
HofmeisterAn merged commit db745e7 into develop Mar 6, 2026
83 checks passed
@HofmeisterAn
HofmeisterAn deleted the feature/add-openssf-scorecard branch March 6, 2026 19:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore A change that doesn't impact the existing functionality, e.g. internal refactorings or cleanups

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant