fix: Dockerfile
This commit is contained in:
parent
bdf42ccf99
commit
ceacd302ac
22
Dockerfile
22
Dockerfile
|
|
@ -1,14 +1,14 @@
|
||||||
FROM registry.cn-chengdu.aliyuncs.com/go_ls/go-zero:v1 AS builder
|
#FROM registry.cn-chengdu.aliyuncs.com/go_ls/go-zero:v1 AS builder
|
||||||
|
#
|
||||||
LABEL stage=gobuilder
|
#LABEL stage=gobuilder
|
||||||
ENV CGO_ENABLED 0
|
#ENV CGO_ENABLED 0
|
||||||
ENV GOPROXY https://goproxy.cn,direct
|
#ENV GOPROXY https://goproxy.cn,direct
|
||||||
|
#
|
||||||
WORKDIR /src
|
#WORKDIR /src
|
||||||
|
#
|
||||||
COPY ../.. .
|
#COPY ../.. .
|
||||||
RUN go mod tidy
|
#RUN go mod tidy
|
||||||
RUN go build -ldflags="-s -w" -o /src/cmd/api/yl cmd/api/yl.go
|
#RUN go build -ldflags="-s -w" -o /src/cmd/api/yl cmd/api/yl.go
|
||||||
|
|
||||||
|
|
||||||
FROM alpine AS runtime
|
FROM alpine AS runtime
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue