mirror of
https://github.com/zeromicro/go-zero.git
synced 2025-01-23 09:00:20 +08:00
check go.mod before build docker image (#225)
This commit is contained in:
parent
6e57f6c527
commit
8d4951c990
@ -18,6 +18,7 @@ ENV GOPROXY https://goproxy.cn,direct
|
||||
|
||||
WORKDIR /build/zero
|
||||
COPY . .
|
||||
RUN sh -c "[ -f go.mod ]" || exit
|
||||
COPY {{.goRelPath}}/etc /app/etc
|
||||
RUN go build -ldflags="-s -w" -o /app/{{.exeFile}} {{.goRelPath}}/{{.goFile}}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user