Skip to content

Instantly share code, notes, and snippets.

@eskibars
Created December 10, 2025 19:44
Show Gist options
  • Select an option

  • Save eskibars/aae5dbc649cd3e5ff98fdfd642490906 to your computer and use it in GitHub Desktop.

Select an option

Save eskibars/aae5dbc649cd3e5ff98fdfd642490906 to your computer and use it in GitHub Desktop.
Dockerfile for ssh-mcp
# First, clone https://github.com/blakerouse/ssh-mcp, then put this Dockerfile in that directory locally to build
# First Docker step: build ssh-mcp
FROM golang:1.25-alpine AS builder
WORKDIR /src
COPY . .
RUN go build -o ssh-mcp .
# Swap to our final container
FROM node:20-alpine
WORKDIR /app
RUN npm install -g supergateway
RUN apk add --no-cache openssh
COPY --from=builder /src/ssh-mcp /app/ssh-mcp
EXPOSE 8004
CMD ["sh", "-c", "\
npx -y supergateway \
--stdio \"./ssh-mcp\" \
--port 8004 \
--baseUrl http://0.0.0.0:8004 \
"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment