forked from mark3labs/mcp-filesystem-server
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
27 lines (18 loc) · 629 Bytes
/
Dockerfile
File metadata and controls
27 lines (18 loc) · 629 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile
FROM golang:1.23-alpine AS builder
WORKDIR /app
# Copy go.mod and go.sum first for caching dependencies
COPY go.mod go.sum ./
# Download dependencies
RUN go mod download
# Copy the source code
COPY . .
# Build the application
RUN go build -ldflags="-s -w" -o server .
FROM alpine:latest
WORKDIR /app
# Copy the built binary from the builder stage
COPY --from=builder /app/server ./
# The container will by default pass '/app' as the allowed directory if no other command line arguments are provided
ENTRYPOINT ["./server"]
CMD ["/app"]