FROM openshift/golang-builder@sha256:4820580c3368f320581eb9e32cf97aeec179a86c5749753a14ed76410a293d83 AS builder
ENV __doozer=update BUILD_RELEASE=202203081809.p0.g78fff55.assembly.stream BUILD_VERSION=v4.10.0 OS_GIT_MAJOR=4 OS_GIT_MINOR=10 OS_GIT_PATCH=0 OS_GIT_TREE_STATE=clean OS_GIT_VERSION=4.10.0-202203081809.p0.g78fff55.assembly.stream SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge OS_GIT_COMMIT=78fff55 OS_GIT_VERSION=4.10.0-202203081809.p0.g78fff55.assembly.stream-78fff55 SOURCE_DATE_EPOCH=1641001451 SOURCE_GIT_COMMIT=78fff5594a5c6fd7252770d12579085e6d19655a SOURCE_GIT_TAG=0.0.0-alpha.4-4988-g78fff5594 SOURCE_GIT_URL=https://github.com/openshift/cluster-api 

WORKDIR /build
COPY . .
RUN GO111MODULE=on CGO_ENABLED=0 GOOS=${GOOS} GOPROXY=${GOPROXY} go build \
  -ldflags="-w -s -X 'main.version=${VERSION}'" \
  -o=cluster-api-controller-manager \
  main.go

FROM openshift/ose-base:v4.10.0.20220308.182903
ENV __doozer=update BUILD_RELEASE=202203081809.p0.g78fff55.assembly.stream BUILD_VERSION=v4.10.0 OS_GIT_MAJOR=4 OS_GIT_MINOR=10 OS_GIT_PATCH=0 OS_GIT_TREE_STATE=clean OS_GIT_VERSION=4.10.0-202203081809.p0.g78fff55.assembly.stream SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge OS_GIT_COMMIT=78fff55 OS_GIT_VERSION=4.10.0-202203081809.p0.g78fff55.assembly.stream-78fff55 SOURCE_DATE_EPOCH=1641001451 SOURCE_GIT_COMMIT=78fff5594a5c6fd7252770d12579085e6d19655a SOURCE_GIT_TAG=0.0.0-alpha.4-4988-g78fff5594 SOURCE_GIT_URL=https://github.com/openshift/cluster-api 


COPY --from=builder /build/cluster-api-controller-manager /bin/cluster-api-controller-manager

ENTRYPOINT [ "/bin/cluster-api-controller-manager" ]

LABEL \
        description="Cluster API Controller Manager" \
        io.openshift.release.operator="true" \
        name="openshift/ose-cluster-capi-controllers" \
        com.redhat.component="ose-cluster-api-container" \
        io.openshift.maintainer.product="OpenShift Container Platform" \
        io.openshift.maintainer.component="Cloud Compute" \
        io.openshift.maintainer.subcomponent="Other Providers" \
        release="202203081809.p0.g78fff55.assembly.stream" \
        io.openshift.build.commit.id="78fff5594a5c6fd7252770d12579085e6d19655a" \
        io.openshift.build.source-location="https://github.com/openshift/cluster-api" \
        io.openshift.build.commit.url="https://github.com/openshift/cluster-api/commit/78fff5594a5c6fd7252770d12579085e6d19655a" \
        version="v4.10.0"

