fix: pin all external refs to cryptographic identity (closes #118)
All checks were successful
Check / check (pull_request) Successful in 11m41s
All checks were successful
Check / check (pull_request) Successful in 11m41s
- Pin Docker base images to sha256 digests (golang, alpine) - Pin go install commands to commit SHAs (not version tags) - golangci-lint: 5d1e709b7be35cb2025444e19de266b056b7b7ee (v2.10.1) - goimports: 009367f5c17a8d4c45a961a3a509277190a9a6f0 (v0.42.0) - CI workflow was already correctly pinned to commit SHAs All references now use cryptographic identity, eliminating RCE risk from mutable tags.
This commit is contained in:
parent
ab526fc93d
commit
0ed2d02dfe
@ -1,11 +1,11 @@
|
||||
# Build stage
|
||||
FROM golang:1.25-alpine AS builder
|
||||
FROM golang@sha256:f6751d823c26342f9506c03797d2527668d095b0a15f1862cddb4d927a7a4ced AS builder # golang:1.25-alpine
|
||||
|
||||
RUN apk add --no-cache git make gcc musl-dev
|
||||
|
||||
# Install golangci-lint v2
|
||||
RUN go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@latest
|
||||
RUN go install golang.org/x/tools/cmd/goimports@latest
|
||||
RUN go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@5d1e709b7be35cb2025444e19de266b056b7b7ee # v2.10.1
|
||||
RUN go install golang.org/x/tools/cmd/goimports@009367f5c17a8d4c45a961a3a509277190a9a6f0 # v0.42.0
|
||||
|
||||
WORKDIR /src
|
||||
COPY go.mod go.sum ./
|
||||
@ -20,7 +20,7 @@ RUN make check
|
||||
RUN make build
|
||||
|
||||
# Runtime stage
|
||||
FROM alpine:3.19
|
||||
FROM alpine@sha256:6baf43584bcb78f2e5847d1de515f23499913ac9f12bdf834811a3145eb11ca1 # alpine:3.19
|
||||
|
||||
RUN apk add --no-cache ca-certificates tzdata git openssh-client docker-cli
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user