From ac1e38a1f492f8a0c62196f44419bc74b65e0274 Mon Sep 17 00:00:00 2001 From: Dwi Siswanto Date: Mon, 11 Jul 2022 14:56:31 +0700 Subject: [PATCH] fix(build:Docker): disable CGO --- Dockerfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index ef90ff7a..bed28cf0 100644 --- a/Dockerfile +++ b/Dockerfile @@ -11,11 +11,13 @@ COPY ./go.mod . RUN go mod download COPY . . -RUN go build -ldflags "-s -w -X teler.app/common.Version=${VERSION}" \ +RUN CGO_ENABLED=0 go build -ldflags \ + "-s -w -X teler.app/common.Version=${VERSION}" \ -o ./bin/teler . FROM alpine:latest COPY --from=build /app/bin/teler /bin/teler ENV HOME / + ENTRYPOINT ["/bin/teler"]