FROM golang:alpine AS builder | |
RUN apk --no-cache add git | |
RUN git clone https://github.com/Harry-zklcdc/go-proxy-bingai.git /workspace/app | |
WORKDIR /workspace/app | |
RUN go build -ldflags="-s -w" -tags netgo -trimpath -o go-proxy-bingai main.go | |
FROM alpine | |
WORKDIR /workspace/app | |
COPY --from=builder /workspace/app/go-proxy-bingai . | |
ENV Go_Proxy_BingAI_USER_TOKEN_1="kJs8hD92ncMzLaoQWYtX5rG6bE3fZ4i0" | |
EXPOSE 8000 | |
CMD ["/workspace/app/go-proxy-bingai"] | |