kontor-echo: setup project to show homepage
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
# ---------- Stage 1: Build ----------
|
||||
FROM docker.io/library/golang:1.25-alpine AS builder
|
||||
FROM docker.io/library/golang:1.26-alpine AS builder
|
||||
# Set the working directory
|
||||
WORKDIR /app
|
||||
# Ensure a portable, static-ish binary
|
||||
@@ -9,8 +9,12 @@ COPY go.mod go.sum ./
|
||||
RUN go mod download
|
||||
# Copy the source code
|
||||
COPY . .
|
||||
ARG VERSION="dev"
|
||||
ARG COMMIT="unset"
|
||||
ARG DATE="unset"
|
||||
# Build the Go application (strip debug info for smaller size)
|
||||
RUN go build -trimpath -ldflags="-s -w" -o kontor cmd/kontor/main.go
|
||||
RUN go build -trimpath -ldflags="-s -w -X kontor-api-echo/internal/globals.Version=${VERSION} -X kontor-api-echo/internal/globals.Commit=${COMMIT} -X kontor-api-echo/internal/globals.Date=${DATE}" -o kontor cmd/kontor-echo/main.go
|
||||
|
||||
|
||||
# ---------- Stage 2: Final ----------
|
||||
FROM alpine:latest
|
||||
|
||||
Reference in New Issue
Block a user