dockerfile添加go代理,解决拉取三方包的延迟问题

This commit is contained in:
nachuan 2024-05-17 13:41:34 +08:00
parent ed9ed5bdb6
commit e5cfe91c44
1 changed files with 2 additions and 0 deletions

View File

@ -4,6 +4,8 @@ WORKDIR /app
ADD . .
ENV GOPROXY https://goproxy.cn
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o override
FROM alpine:latest