fix: remove redundant line in Dockerfile for backend and worker services to streamline Go module setup

This commit is contained in:
keven1024
2025-06-02 15:29:41 +08:00
parent 99150f7015
commit a60b19398d
2 changed files with 6 additions and 4 deletions

View File

@@ -7,12 +7,12 @@ WORKDIR /app
# Download Go modules
COPY go.mod go.sum ./
RUN go env -w GO111MODULE=on && go env -w GOPROXY=https://goproxy.cn,direct && go mod download
# Copy the source code. Note the slash at the end, as explained in
# https://docs.docker.com/engine/reference/builder/#copy
COPY *.go ./
RUN go env -w GO111MODULE=on && go env -w GOPROXY=https://goproxy.cn,direct && go mod download
# Build
RUN CGO_ENABLED=0 GOOS=linux go build -o /worker