Skip to content

fix(ci): use DOCKERHUB_USERNAME secret instead of hardcoded registry namespace - #152

Open
EliShteinman wants to merge 2 commits into
crystaldba:mainfrom
EliShteinman:fix/dockerhub-hardcoded-namespace
Open

EliShteinman wants to merge 2 commits into
crystaldba:mainfrom
EliShteinman:fix/dockerhub-hardcoded-namespace

Conversation

@EliShteinman

Copy link
Copy Markdown

Summary

  • The DockerHub workflow had crystaldba/postgres-mcp hardcoded as the image name and cache registry references
  • This caused Docker builds to fail on forks, since the forked repo's DockerHub credentials don't have push access to crystaldba/postgres-mcp
  • Replaced all hardcoded crystaldba references with ${{ secrets.DOCKERHUB_USERNAME }} so each fork can configure its own DockerHub namespace

…namespace

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings February 12, 2026 08:57

Copilot AI 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.

Pull request overview

This PR updates the DockerHub build/push GitHub Actions workflow to make the Docker image namespace configurable via a secret, avoiding hardcoded crystaldba/... references that break builds on forks.

Changes:

  • Replace hardcoded crystaldba/postgres-mcp image name with ${{ secrets.DOCKERHUB_USERNAME }}/postgres-mcp
  • Update registry build cache ref values to use ${{ secrets.DOCKERHUB_USERNAME }} as well

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

@jssmith jssmith left a comment

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.

Review — concise

Verdict: Approve. Simple, correct CI fix.

Summary

Replaces hardcoded crystaldba/postgres-mcp Docker Hub namespace with ${{ secrets.DOCKERHUB_USERNAME }}/postgres-mcp in the Docker build workflow. Applied to image tags and build cache references.

Correctness

  • All four references updated consistently: images, cache-from, cache-to, and the metadata action.
  • Using a secret for the namespace is the right approach — avoids hardcoding org names in CI config.
  • No logic changes, just variable substitution.

Minor (non-blocking)

  • Verify DOCKERHUB_USERNAME secret is set in the repo settings before merging, otherwise the build will push to /postgres-mcp (empty namespace).

This review was created by an AI agent (OpenHands) on behalf of @jssmith.

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.

3 participants