Skip to content

feat(dockerhub): use OIDC to publish to docker hub when available#101

Merged
JonZeolla merged 3 commits into
mainfrom
feat/dockerhub-auth-by-subscription
Jul 23, 2026
Merged

feat(dockerhub): use OIDC to publish to docker hub when available#101
JonZeolla merged 3 commits into
mainfrom
feat/dockerhub-auth-by-subscription

Conversation

@JonZeolla

@JonZeolla JonZeolla commented Jul 23, 2026

Copy link
Copy Markdown
Member

Summary

  • replace separate Docker Hub questions with one subscription choice
  • disable Docker Hub publishing for none
  • use username/PAT authentication for personal
  • use short-lived OIDC authentication for team and business
  • generate documentation and setup guidance only for the selected path

Testing

  • uv run pytest tests/test_cookiecutter.py::test_dockerhub_subscription_prompt tests/test_cookiecutter.py::test_dockerhub_release_authentication --no-cov
  • full pre-commit suite passed during commit

Based on docker/login-action#1048 and Docker OIDC subscription requirements.

PR Description from Zenable

Replace the binary Docker Hub yes/no question with a single dockerhub_subscription choice (none, personal, team, business) that determines the authentication strategy.

  • none: disables Docker Hub publishing entirely
  • personal: uses username/PAT authentication
  • team / business: uses short-lived OIDC authentication
  • Generated documentation, workflow, README, and Taskfile are conditionally rendered based on the selected subscription tier

Testing

  • uv run pytest tests/test_cookiecutter.py::test_dockerhub_subscription_prompt tests/test_cookiecutter.py::test_dockerhub_release_authentication --no-cov
  • Full pre-commit suite passed during commit

Based on docker/login-action#1048 and Docker OIDC subscription requirements.

@ai-coding-guardrails ai-coding-guardrails 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.

Nice work! 😎

I didn't find anything of concern

Risk: 🟢 Low

Risk analysis

The highest scores are for test_coverage and security_impact. Test coverage is strong with new parametrized tests validating each subscription path, though the OIDC flow isn't fully exercised. Security impact is moderate due to the introduction of new authentication methods (OIDC and PAT-based) which, while following best practices, increase the surface area for credential handling and misconfiguration. The change affects generated project templates rather than runtime code, limiting blast radius and operational risk.

Reviewed with 🤟 by Zenable

@ai-coding-guardrails ai-coding-guardrails Bot added the zenable/risk:low Zenable assessed this PR as LOW risk. label Jul 23, 2026
@JonZeolla
JonZeolla enabled auto-merge (squash) July 23, 2026 19:18
@JonZeolla JonZeolla changed the title feat(dockerhub): select authentication by subscription feat(dockerhub): use OIDC to publish to docker hub when available Jul 23, 2026
@JonZeolla
JonZeolla disabled auto-merge July 23, 2026 19:22
@JonZeolla
JonZeolla enabled auto-merge (squash) July 23, 2026 19:26
@JonZeolla
JonZeolla merged commit 4969496 into main Jul 23, 2026
6 checks passed
@JonZeolla
JonZeolla deleted the feat/dockerhub-auth-by-subscription branch July 23, 2026 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

zenable/risk:low Zenable assessed this PR as LOW risk.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant