From bcf21d2cba5aecf52da875b344f52515d94abe51 Mon Sep 17 00:00:00 2001 From: Ali Najafizadeh Date: Thu, 18 Apr 2024 01:41:50 -0400 Subject: [PATCH] Add args to dockerfile to passing version and git hash --- Dockerfile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Dockerfile b/Dockerfile index 8cdc3c7..bea1d73 100644 --- a/Dockerfile +++ b/Dockerfile @@ -21,6 +21,9 @@ ENV GOPRIVATE=ella.to/* ## TEST GO UNIT TESTS RUN go test -race -timeout 50s ./... -v +ARG GIT_COMMIT +ARG VERSION + ## BUILD API RUN go build -ldflags="-w -s -X main.GitCommit=${GIT_COMMIT} -X main.Version=${VERSION}" -o ./bus-server cmd/server/main.go