Initial commit

This commit is contained in:
jonasen1988
2026-03-26 21:14:16 +08:00
commit d2e679401e
18 changed files with 2055 additions and 0 deletions

25
Dockerfile Normal file
View File

@@ -0,0 +1,25 @@
# 构建阶段(使用完整 Debian 镜像,内置 gcc避免 alpine apk 问题)
FROM golang:1.25 AS builder
WORKDIR /app
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN CGO_ENABLED=1 GOOS=linux go build -o proxy-pool .
# 运行阶段(使用轻量 debian-slim
FROM debian:bookworm-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates tzdata && \
rm -rf /var/lib/apt/lists/*
ENV TZ=Asia/Shanghai
WORKDIR /app
COPY --from=builder /app/proxy-pool .
EXPOSE 7777 7778
CMD ["./proxy-pool"]