Files
open-cluster-management/build/Dockerfile.registration
Jian Qiu 2582ad922d Update deps to 1.30 (#546)
Signed-off-by: Jian Qiu <jqiu@redhat.com>
2024-07-02 14:04:15 +00:00

18 lines
459 B
Docker

FROM golang:1.22-bullseye AS builder
ARG OS=linux
ARG ARCH=amd64
WORKDIR /go/src/open-cluster-management.io/ocm
COPY . .
ENV GO_PACKAGE open-cluster-management.io/ocm
RUN GOOS=${OS} \
GOARCH=${ARCH} \
GO_BUILD_PACKAGES=./cmd/registration \
make build --warn-undefined-variables
FROM registry.access.redhat.com/ubi9/ubi-minimal:latest
ENV USER_UID=10001
COPY --from=builder /go/src/open-cluster-management.io/ocm/registration /
USER ${USER_UID}