Remove go mod tidy from Docker build
CI/CD / test (push) Successful in 38s
CI/CD / build (push) Successful in 39s
CI/CD / docker (push) Successful in 3m33s

go mod tidy in Docker build causes disk space issues on CI runners
(compiling modernc.org/ccgo pulls many C files). go.mod/go.sum are
committed to repo, so go mod download + go build is sufficient.
This commit is contained in:
Mrixs committed 2026-10-18 09:28:08 +03:00
1 parent 7ddf43158a
commit 03ef94b033
1 file changed
+2 -2
+2 -2
View File
@@ -13,8 +13,8 @@ RUN go mod download
# Copy source # Copy source
COPY . . COPY . .
# Tidy and build binary # Build binary
RUN go mod tidy && CGO_ENABLED=0 GOOS=linux go build -o /ym-dl ./cmd/ym-dl RUN CGO_ENABLED=0 GOOS=linux go build -o /ym-dl ./cmd/ym-dl
# Runtime stage # Runtime stage
FROM gcr.io/distroless/static-debian12:nonroot FROM gcr.io/distroless/static-debian12:nonroot