mirror of
https://github.com/cert-manager/webhook-example.git
synced 2025-07-01 22:35:49 +02:00

* restructure source and templates to follow helm best-practices * add basic actions for more complex workflows * workflows for pr ands tags (along with required fixes to go code) * re-add helm chart and automated chart release * fix errors in workflows * improve documentation * fix finding existing records * add missing namespace to workflow * cleanup of kubernetes pipeline * Fixed and documented tagging workflow
25 lines
421 B
Docker
25 lines
421 B
Docker
FROM golang:1.22-alpine AS build_deps
|
|
|
|
RUN apk add --no-cache git
|
|
|
|
WORKDIR /workspace
|
|
ENV GO111MODULE=on
|
|
|
|
COPY src/go.mod .
|
|
COPY src/go.sum .
|
|
|
|
RUN go mod download
|
|
|
|
FROM build_deps AS build
|
|
|
|
COPY src .
|
|
|
|
RUN CGO_ENABLED=0 go build -o webhook -ldflags '-w -extldflags "-static"' .
|
|
|
|
FROM alpine:3.17
|
|
|
|
RUN apk add --no-cache ca-certificates
|
|
|
|
COPY --from=build /workspace/webhook /usr/local/bin/webhook
|
|
|
|
ENTRYPOINT ["webhook"]
|