Merge pull request #8 from PatrykIti/fix/workflow_pat
fix: Add PAT authentication to Docker workflow for README updates
This commit is contained in:
8
.github/workflows/auto-version.yml
vendored
8
.github/workflows/auto-version.yml
vendored
@@ -184,12 +184,12 @@ jobs:
|
|||||||
This PR triggered a Docker image build because of the \`+docker\` suffix in the title.
|
This PR triggered a Docker image build because of the \`+docker\` suffix in the title.
|
||||||
|
|
||||||
**Expected Image Tags:**
|
**Expected Image Tags:**
|
||||||
- \`ghcr.io/${{ github.repository_owner }}/gemini-mcp-server:pr-${{ github.event.pull_request.number }}\`
|
- \`ghcr.io/${{ github.repository_owner }}/zen-mcp-server:pr-${{ github.event.pull_request.number }}\`
|
||||||
- \`ghcr.io/${{ github.repository_owner }}/gemini-mcp-server:main-${{ github.sha }}\`
|
- \`ghcr.io/${{ github.repository_owner }}/zen-mcp-server:main-${{ github.sha }}\`
|
||||||
|
|
||||||
**To test the image after build completes:**
|
**To test the image after build completes:**
|
||||||
\`\`\`bash
|
\`\`\`bash
|
||||||
docker pull ghcr.io/${{ github.repository_owner }}/gemini-mcp-server:pr-${{ github.event.pull_request.number }}
|
docker pull ghcr.io/${{ github.repository_owner }}/zen-mcp-server:pr-${{ github.event.pull_request.number }}
|
||||||
\`\`\`
|
\`\`\`
|
||||||
|
|
||||||
**Claude Desktop config for testing:**
|
**Claude Desktop config for testing:**
|
||||||
@@ -201,7 +201,7 @@ jobs:
|
|||||||
\"args\": [
|
\"args\": [
|
||||||
\"run\", \"--rm\", \"-i\",
|
\"run\", \"--rm\", \"-i\",
|
||||||
\"-e\", \"GEMINI_API_KEY\",
|
\"-e\", \"GEMINI_API_KEY\",
|
||||||
\"ghcr.io/${{ github.repository_owner }}/gemini-mcp-server:pr-${{ github.event.pull_request.number }}\"
|
\"ghcr.io/${{ github.repository_owner }}/zen-mcp-server:pr-${{ github.event.pull_request.number }}\"
|
||||||
],
|
],
|
||||||
\"env\": {
|
\"env\": {
|
||||||
\"GEMINI_API_KEY\": \"your-api-key-here\"
|
\"GEMINI_API_KEY\": \"your-api-key-here\"
|
||||||
|
|||||||
12
.github/workflows/build_and_publish_docker.yml
vendored
12
.github/workflows/build_and_publish_docker.yml
vendored
@@ -8,7 +8,7 @@ on:
|
|||||||
|
|
||||||
env:
|
env:
|
||||||
REGISTRY: ghcr.io
|
REGISTRY: ghcr.io
|
||||||
IMAGE_NAME: ${{ github.repository }}
|
IMAGE_NAME: patrykiti/zen-mcp-server
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-push:
|
build-and-push:
|
||||||
@@ -22,6 +22,8 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.PAT }}
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
@@ -114,7 +116,7 @@ jobs:
|
|||||||
|
|
||||||
echo "" >> $GITHUB_STEP_SUMMARY
|
echo "" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "### 📦 View in GitHub Container Registry" >> $GITHUB_STEP_SUMMARY
|
echo "### 📦 View in GitHub Container Registry" >> $GITHUB_STEP_SUMMARY
|
||||||
echo "[View all versions and tags →](https://github.com/${{ github.repository }}/pkgs/container/gemini-mcp-server)" >> $GITHUB_STEP_SUMMARY
|
echo "[View all versions and tags →](https://github.com/${{ github.repository }}/pkgs/container/zen-mcp-server)" >> $GITHUB_STEP_SUMMARY
|
||||||
|
|
||||||
- name: Update README with latest image info
|
- name: Update README with latest image info
|
||||||
if: github.ref_type == 'tag' || (github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '')
|
if: github.ref_type == 'tag' || (github.event_name == 'repository_dispatch' && github.event.client_payload.pr_number != '')
|
||||||
@@ -137,13 +139,13 @@ jobs:
|
|||||||
echo "Updating README.md with latest Docker image: $LATEST_TAG"
|
echo "Updating README.md with latest Docker image: $LATEST_TAG"
|
||||||
|
|
||||||
# Update README.md with the latest image tag
|
# Update README.md with the latest image tag
|
||||||
sed -i.bak "s|ghcr\.io/${{ github.repository_owner }}/gemini-mcp-server:[a-zA-Z0-9\._-]*|$LATEST_TAG|g" README.md
|
sed -i.bak "s|ghcr\.io/patrykiti/zen-mcp-server:[a-zA-Z0-9\._-]*|$LATEST_TAG|g" README.md
|
||||||
|
|
||||||
# Also update docs/user-guides/installation.md
|
# Also update docs/user-guides/installation.md
|
||||||
sed -i.bak "s|ghcr\.io/${{ github.repository_owner }}/gemini-mcp-server:[a-zA-Z0-9\._-]*|$LATEST_TAG|g" docs/user-guides/installation.md
|
sed -i.bak "s|ghcr\.io/patrykiti/zen-mcp-server:[a-zA-Z0-9\._-]*|$LATEST_TAG|g" docs/user-guides/installation.md
|
||||||
|
|
||||||
# Also update docs/user-guides/configuration.md
|
# Also update docs/user-guides/configuration.md
|
||||||
sed -i.bak "s|ghcr\.io/${{ github.repository_owner }}/gemini-mcp-server:[a-zA-Z0-9\._-]*|$LATEST_TAG|g" docs/user-guides/configuration.md
|
sed -i.bak "s|ghcr\.io/patrykiti/zen-mcp-server:[a-zA-Z0-9\._-]*|$LATEST_TAG|g" docs/user-guides/configuration.md
|
||||||
|
|
||||||
# Check if there are any changes
|
# Check if there are any changes
|
||||||
if git diff --quiet README.md docs/user-guides/installation.md docs/user-guides/configuration.md; then
|
if git diff --quiet README.md docs/user-guides/installation.md docs/user-guides/configuration.md; then
|
||||||
|
|||||||
@@ -199,7 +199,7 @@ have produced a configuration for you to copy:
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Pull the latest published image
|
# Pull the latest published image
|
||||||
docker pull ghcr.io/patrykiti/gemini-mcp-server:latest
|
docker pull ghcr.io/patrykiti/zen-mcp-server:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
**Claude Desktop Configuration:**
|
**Claude Desktop Configuration:**
|
||||||
@@ -211,7 +211,7 @@ docker pull ghcr.io/patrykiti/gemini-mcp-server:latest
|
|||||||
"args": [
|
"args": [
|
||||||
"run", "--rm", "-i",
|
"run", "--rm", "-i",
|
||||||
"-e", "GEMINI_API_KEY",
|
"-e", "GEMINI_API_KEY",
|
||||||
"ghcr.io/patrykiti/gemini-mcp-server:latest"
|
"ghcr.io/patrykiti/zen-mcp-server:latest"
|
||||||
],
|
],
|
||||||
"env": {
|
"env": {
|
||||||
"GEMINI_API_KEY": "your-gemini-api-key-here"
|
"GEMINI_API_KEY": "your-gemini-api-key-here"
|
||||||
@@ -237,7 +237,7 @@ You can customize the server behavior by adding additional environment variables
|
|||||||
"-e", "DEFAULT_THINKING_MODE_THINKDEEP",
|
"-e", "DEFAULT_THINKING_MODE_THINKDEEP",
|
||||||
"-e", "LOG_LEVEL",
|
"-e", "LOG_LEVEL",
|
||||||
"-e", "MCP_PROJECT_ROOT",
|
"-e", "MCP_PROJECT_ROOT",
|
||||||
"ghcr.io/patrykiti/gemini-mcp-server:latest"
|
"ghcr.io/patrykiti/zen-mcp-server:latest"
|
||||||
],
|
],
|
||||||
"env": {
|
"env": {
|
||||||
"GEMINI_API_KEY": "your-gemini-api-key-here",
|
"GEMINI_API_KEY": "your-gemini-api-key-here",
|
||||||
|
|||||||
Reference in New Issue
Block a user