From fdfa912e44c764224adfda4bcf81e80c3f4f8eaf Mon Sep 17 00:00:00 2001 From: Asif Iqbal Date: Sat, 5 Apr 2025 12:54:48 +0600 Subject: [PATCH 1/4] Fix Dockerfile for distroless compatibility --- Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 05fe1ddd2..cf49ed556 100644 --- a/Dockerfile +++ b/Dockerfile @@ -24,4 +24,5 @@ WORKDIR /server # Copy the binary from the build stage COPY --from=build /build/github-mcp-server . # Command to run the server -CMD ["./github-mcp-server", "stdio"] +ENTRYPOINT ["./github-mcp-server"] +CMD ["stdio"] \ No newline at end of file From cc796ed86beddfd7007802ad075d9e563e3a5892 Mon Sep 17 00:00:00 2001 From: Asif Iqbal Date: Sat, 5 Apr 2025 13:01:51 +0600 Subject: [PATCH 2/4] Update for Smithery.ai compatibility --- Dockerfile | 8 ++++---- smithery.yaml | 17 +++++++++++++++++ 2 files changed, 21 insertions(+), 4 deletions(-) create mode 100644 smithery.yaml diff --git a/Dockerfile b/Dockerfile index cf49ed556..90c3ab97b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,12 +17,12 @@ COPY . ./ RUN --mount=type=cache,target=/root/.cache/go-build CGO_ENABLED=0 go build -ldflags="-s -w -X main.version=${VERSION} -X main.commit=$(git rev-parse HEAD) -X main.date=$(date -u +%Y-%m-%dT%H:%M:%SZ)" \ -o github-mcp-server cmd/github-mcp-server/main.go -# Make a stage to run the app -FROM gcr.io/distroless/base-debian12 +# Make a stage to run the app - using debian:12-slim instead of distroless +# This provides a shell that Smithery.ai requires +FROM debian:12-slim # Set the working directory WORKDIR /server # Copy the binary from the build stage COPY --from=build /build/github-mcp-server . # Command to run the server -ENTRYPOINT ["./github-mcp-server"] -CMD ["stdio"] \ No newline at end of file +CMD ["./github-mcp-server", "stdio"] \ No newline at end of file diff --git a/smithery.yaml b/smithery.yaml new file mode 100644 index 000000000..277e573fb --- /dev/null +++ b/smithery.yaml @@ -0,0 +1,17 @@ +# Smithery.ai configuration for GitHub MCP Server +startCommand: + type: stdio + configSchema: + # JSON Schema defining the configuration options for the MCP. + # Update this with any configuration options your MCP server requires + type: object + properties: {} + additionalProperties: false + commandFunction: |- + (config) => ({ + "command": "./github-mcp-server", + "args": [ + "stdio" + ], + "env": {} + }) \ No newline at end of file From bdc16c39c767870682f72c53162c2088a8dfdf44 Mon Sep 17 00:00:00 2001 From: Asif Iqbal Date: Sat, 5 Apr 2025 13:25:47 +0600 Subject: [PATCH 3/4] Add GitHub PAT configuration to smithery.yaml --- smithery.yaml | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/smithery.yaml b/smithery.yaml index 277e573fb..2f9694800 100644 --- a/smithery.yaml +++ b/smithery.yaml @@ -2,10 +2,15 @@ startCommand: type: stdio configSchema: - # JSON Schema defining the configuration options for the MCP. - # Update this with any configuration options your MCP server requires + # JSON Schema defining the configuration options for the MCP type: object - properties: {} + properties: + githubToken: + type: string + title: GitHub Personal Access Token + description: GitHub Personal Access Token with appropriate permissions + secret: true # This marks the field as a secret, so it won't be logged + required: ["githubToken"] additionalProperties: false commandFunction: |- (config) => ({ @@ -13,5 +18,7 @@ startCommand: "args": [ "stdio" ], - "env": {} + "env": { + "GITHUB_PERSONAL_ACCESS_TOKEN": config.githubToken + } }) \ No newline at end of file From 25a339d494d8e19f5c9c49928c7be3525d233e5e Mon Sep 17 00:00:00 2001 From: Asif Iqbal Date: Sat, 5 Apr 2025 13:40:40 +0600 Subject: [PATCH 4/4] Update smithery.yaml to include GitHub Personal Access Token configuration --- smithery.yaml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/smithery.yaml b/smithery.yaml index 2f9694800..bfdd52482 100644 --- a/smithery.yaml +++ b/smithery.yaml @@ -4,13 +4,14 @@ startCommand: configSchema: # JSON Schema defining the configuration options for the MCP type: object + required: + - githubPersonalAccessToken properties: - githubToken: + githubPersonalAccessToken: type: string title: GitHub Personal Access Token - description: GitHub Personal Access Token with appropriate permissions + description: The personal access token for accessing the GitHub API. secret: true # This marks the field as a secret, so it won't be logged - required: ["githubToken"] additionalProperties: false commandFunction: |- (config) => ({ @@ -19,6 +20,6 @@ startCommand: "stdio" ], "env": { - "GITHUB_PERSONAL_ACCESS_TOKEN": config.githubToken + "GITHUB_PERSONAL_ACCESS_TOKEN": config.githubPersonalAccessToken } }) \ No newline at end of file pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy