forked from hongkongkiwi/docx-mcp
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile.proxy
More file actions
33 lines (23 loc) · 1 KB
/
Dockerfile.proxy
File metadata and controls
33 lines (23 loc) · 1 KB
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
28
29
30
31
32
33
# docx-mcp-sse-proxy — HTTP reverse proxy with PAT auth
FROM rust:1.93-slim-bookworm AS builder
WORKDIR /build
RUN apt-get update && apt-get install -y \
pkg-config protobuf-compiler libssl-dev \
&& rm -rf /var/lib/apt/lists/*
COPY Cargo.toml Cargo.lock ./
COPY proto/ ./proto/
COPY crates/ ./crates/
RUN --mount=type=cache,id=cargo-proxy,target=/usr/local/cargo/registry \
cargo build --release --package docx-mcp-sse-proxy
FROM debian:bookworm-slim
RUN apt-get update && apt-get install -y ca-certificates curl && rm -rf /var/lib/apt/lists/*
RUN useradd -m -u 1000 docx
USER docx
WORKDIR /app
COPY --from=builder /build/target/release/docx-mcp-sse-proxy /app/docx-mcp-sse-proxy
ENV RUST_LOG=info PROXY_HOST=0.0.0.0 PROXY_PORT=8080
EXPOSE 8080
# Required: MCP_BACKEND_URL, CLOUDFLARE_ACCOUNT_ID, CLOUDFLARE_API_TOKEN, D1_DATABASE_ID
HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \
CMD ["curl", "-sf", "http://localhost:8080/health"]
ENTRYPOINT ["/app/docx-mcp-sse-proxy"]