Fix deploy: force Docker rebuild, add version check and redeploy script
This commit is contained in:
+5
-1
@@ -9,7 +9,11 @@ COPY go.mod go.sum ./
|
||||
RUN go mod download
|
||||
|
||||
COPY . .
|
||||
RUN CGO_ENABLED=0 GOOS=linux go build -ldflags="-s -w" -o /shop ./cmd/shop
|
||||
ARG APP_VERSION=dev
|
||||
ARG BUILD_TIME=unknown
|
||||
RUN CGO_ENABLED=0 GOOS=linux go build \
|
||||
-ldflags="-s -w -X shop/internal/version.Version=${APP_VERSION}" \
|
||||
-o /shop ./cmd/shop
|
||||
|
||||
# Runtime stage
|
||||
FROM alpine:3.21
|
||||
|
||||
Reference in New Issue
Block a user