fix: toolchain removal and in-container go tidy

This commit is contained in:
KV-Tube Deployer 2026-03-24 22:53:18 +07:00
parent 0c51e3c888
commit 80bfc4f602

View file

@ -3,7 +3,7 @@ FROM golang:1.24-alpine AS backend-builder
WORKDIR /app
RUN apk add --no-cache git gcc musl-dev
COPY backend/go.mod backend/go.sum ./
RUN sed -i 's/^go .*/go 1.24.0/' go.mod && cat go.mod
RUN sed -i 's/^go .*/go 1.24.0/' go.mod && sed -i '/^toolchain /d' go.mod && go mod tidy
RUN go mod download
COPY backend/ ./
RUN CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build -o kv-tube .