File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# Build the manager binary
2- FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:633d23bf362cb40dd72b4f277288a8929697d77537f9c801b81aeced19b5bdf3 AS builder
2+ FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:cc9a5d7a008cfe2cbc7ffc752b0d6636ad30fc16e4a648d2e4aac00fd8b25ca3 AS builder
33ARG TARGETOS
44ARG TARGETARCH
55ARG SOURCE_DATE_EPOCH=0
@@ -26,7 +26,7 @@ RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} \
2626
2727# Use distroless as minimal base image to package the manager binary
2828# Refer to https://github.com/GoogleContainerTools/distroless for more details
29- FROM gcr.io/distroless/static:nonroot@sha256:e3f945647ffb95b5839c07038d64f9811adf17308b9121d8a2b87b6a22a80a39
29+ FROM gcr.io/distroless/static:nonroot@sha256:963fa6c544fe5ce420f1f54fb88b6fb01479f054c8056d0f74cc2c6000df5240
3030WORKDIR /
3131COPY --from=builder /workspace/manager .
3232USER 65532:65532
Original file line number Diff line number Diff line change 88# Example build (from repo root):
99# docker build -f Dockerfile.backup -t openbao-backup:dev .
1010
11- FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:633d23bf362cb40dd72b4f277288a8929697d77537f9c801b81aeced19b5bdf3 AS builder
11+ FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:cc9a5d7a008cfe2cbc7ffc752b0d6636ad30fc16e4a648d2e4aac00fd8b25ca3 AS builder
1212ARG TARGETOS
1313ARG TARGETARCH
1414ARG SOURCE_DATE_EPOCH=0
@@ -27,7 +27,7 @@ RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} \
2727 go build -a -mod=vendor -trimpath -buildvcs=false -ldflags="-buildid=" -o bao-backup ./cmd/bao-backup && \
2828 touch -h -d "@${SOURCE_DATE_EPOCH}" bao-backup
2929
30- FROM gcr.io/distroless/static:nonroot@sha256:e3f945647ffb95b5839c07038d64f9811adf17308b9121d8a2b87b6a22a80a39
30+ FROM gcr.io/distroless/static:nonroot@sha256:963fa6c544fe5ce420f1f54fb88b6fb01479f054c8056d0f74cc2c6000df5240
3131
3232# The backup executor binary is designed to run as a non-root user. We align the
3333# container user and group IDs with the IDs used by the operator-managed
Original file line number Diff line number Diff line change 1- FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:633d23bf362cb40dd72b4f277288a8929697d77537f9c801b81aeced19b5bdf3 AS builder
1+ FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:cc9a5d7a008cfe2cbc7ffc752b0d6636ad30fc16e4a648d2e4aac00fd8b25ca3 AS builder
22ARG TARGETOS
33ARG TARGETARCH
44ARG SOURCE_DATE_EPOCH=0
@@ -28,7 +28,7 @@ RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} \
2828 go build -a -mod=vendor -trimpath -buildvcs=false -ldflags="-buildid=" -o bao-probe ./cmd/bao-probe && \
2929 touch -h -d "@${SOURCE_DATE_EPOCH}" bao-probe
3030
31- FROM gcr.io/distroless/static:nonroot@sha256:e3f945647ffb95b5839c07038d64f9811adf17308b9121d8a2b87b6a22a80a39
31+ FROM gcr.io/distroless/static:nonroot@sha256:963fa6c544fe5ce420f1f54fb88b6fb01479f054c8056d0f74cc2c6000df5240
3232
3333# The config-init binary is designed to run as a non-root user. We align the
3434# container user and group IDs with the IDs used by the operator-managed
Original file line number Diff line number Diff line change 77# Example build (from repo root):
88# docker build -f Dockerfile.upgrade -t openbao-upgrade:dev .
99
10- FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:633d23bf362cb40dd72b4f277288a8929697d77537f9c801b81aeced19b5bdf3 AS builder
10+ FROM --platform=$BUILDPLATFORM golang:1.26.3@sha256:cc9a5d7a008cfe2cbc7ffc752b0d6636ad30fc16e4a648d2e4aac00fd8b25ca3 AS builder
1111ARG TARGETOS
1212ARG TARGETARCH
1313ARG SOURCE_DATE_EPOCH=0
@@ -26,7 +26,7 @@ RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} \
2626 go build -a -mod=vendor -trimpath -buildvcs=false -ldflags="-buildid=" -o bao-upgrade-executor ./cmd/bao-upgrade && \
2727 touch -h -d "@${SOURCE_DATE_EPOCH}" bao-upgrade-executor
2828
29- FROM gcr.io/distroless/static:nonroot@sha256:e3f945647ffb95b5839c07038d64f9811adf17308b9121d8a2b87b6a22a80a39
29+ FROM gcr.io/distroless/static:nonroot@sha256:963fa6c544fe5ce420f1f54fb88b6fb01479f054c8056d0f74cc2c6000df5240
3030
3131USER 1000:1000
3232WORKDIR /
You can’t perform that action at this time.
0 commit comments