Fix version and BuildTime injection
This commit is contained in:
@@ -1,12 +1,12 @@
|
|||||||
# --- BUILD STAGE ---
|
# --- BUILD STAGE ---
|
||||||
FROM golang:1.25.0 AS builder
|
FROM golang:1.25.3 AS builder
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY go.mod go.sum ./
|
COPY go.mod go.sum ./
|
||||||
RUN go mod download
|
RUN go mod download
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
# Fontos: CGO_ENABLED=0 a statikusan linkelt binárisért, ami kompatibilis lesz az Alpine alapú futtatási környezettel.
|
# Fontos: CGO_ENABLED=0 a statikusan linkelt binárisért, ami kompatibilis lesz az Alpine alapú futtatási környezettel.
|
||||||
RUN CGO_ENABLED=0 GOOS=linux go build -a -ldflags="-s -w" -o backend .
|
RUN CGO_ENABLED=0 GOOS=linux go build -a -ldflags="-s -w -X 'main.BuildTime=$(date)'" -o backend .
|
||||||
|
|
||||||
|
|
||||||
# --- DEPLOY STAGE ---
|
# --- DEPLOY STAGE ---
|
||||||
|
|||||||
Reference in New Issue
Block a user