FROM openshift/golang-builder:1.12 AS builder
ENV OS_GIT_MAJOR=4 OS_GIT_MINOR=3 OS_GIT_PATCH=13 OS_GIT_VERSION=4.3.13-202004131016-0b20d60 OS_GIT_TREE_STATE=clean SOURCE_GIT_COMMIT=0b20d6028556a34abf80e55b7b3c0c8ec469d29f SOURCE_GIT_TAG=0b20d602 SOURCE_GIT_URL=https://github.com/openshift/cluster-kube-controller-manager-operator SOURCE_DATE_EPOCH=1584139769 OS_GIT_COMMIT=0b20d60 BUILD_VERSION=v4.3.13 BUILD_RELEASE=202004131016
WORKDIR /go/src/github.com/openshift/cluster-kube-controller-manager-operator
COPY . .
RUN make build --warn-undefined-variables

FROM openshift/ose-base:v4.3.13.20200413.101616
ENV OS_GIT_MAJOR=4 OS_GIT_MINOR=3 OS_GIT_PATCH=13 OS_GIT_VERSION=4.3.13-202004131016-0b20d60 OS_GIT_TREE_STATE=clean SOURCE_GIT_COMMIT=0b20d6028556a34abf80e55b7b3c0c8ec469d29f SOURCE_GIT_TAG=0b20d602 SOURCE_GIT_URL=https://github.com/openshift/cluster-kube-controller-manager-operator SOURCE_DATE_EPOCH=1584139769 OS_GIT_COMMIT=0b20d60 BUILD_VERSION=v4.3.13 BUILD_RELEASE=202004131016
RUN mkdir -p /usr/share/bootkube/manifests/bootstrap-manifests/ /usr/share/bootkube/manifests/config/ /usr/share/bootkube/manifests/manifests/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-controller-manager-operator/bindata/bootkube/bootstrap-manifests /usr/share/bootkube/manifests/bootstrap-manifests/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-controller-manager-operator/bindata/bootkube/config /usr/share/bootkube/manifests/config/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-controller-manager-operator/bindata/bootkube/manifests /usr/share/bootkube/manifests/manifests/
COPY --from=builder /go/src/github.com/openshift/cluster-kube-controller-manager-operator/cluster-kube-controller-manager-operator /usr/bin/
COPY manifests /manifests
COPY vendor/github.com/openshift/api/operator/v1/0000_25_kube-controller-manager-operator_01_config.crd.yaml /manifests

LABEL \
        io.openshift.release.operator="true" \
        name="openshift/ose-cluster-kube-controller-manager-operator" \
        com.redhat.component="ose-cluster-kube-controller-manager-operator-container" \
        io.openshift.maintainer.product="OpenShift Container Platform" \
        io.openshift.maintainer.component="kube-controller-manager" \
        version="v4.3.13" \
        release="202004131016" \
        io.openshift.build.commit.id="0b20d6028556a34abf80e55b7b3c0c8ec469d29f" \
        io.openshift.build.source-location="https://github.com/openshift/cluster-kube-controller-manager-operator" \
        io.openshift.build.commit.url="https://github.com/openshift/cluster-kube-controller-manager-operator/commit/0b20d6028556a34abf80e55b7b3c0c8ec469d29f"

