FROM openshift/golang-builder:1.11 AS builder
ENV OS_GIT_MAJOR=4 OS_GIT_MINOR=1 OS_GIT_PATCH=41 OS_GIT_VERSION=4.1.41-202004130646-d1165cf OS_GIT_TREE_STATE=clean SOURCE_GIT_COMMIT=d1165cf12340cb5b748d620c980646d15e56e7a6 SOURCE_GIT_TAG=d1165cf1 SOURCE_GIT_URL=https://github.com/openshift/cluster-kube-controller-manager-operator SOURCE_DATE_EPOCH=1585183401 OS_GIT_COMMIT=d1165cf BUILD_VERSION=v4.1.41 BUILD_RELEASE=202004130646
WORKDIR /go/src/github.com/openshift/cluster-kube-controller-manager-operator
COPY . .
RUN go build ./cmd/cluster-kube-controller-manager-operator

FROM openshift/ose-base:v4.1.41.20200413.064634
ENV OS_GIT_MAJOR=4 OS_GIT_MINOR=1 OS_GIT_PATCH=41 OS_GIT_VERSION=4.1.41-202004130646-d1165cf OS_GIT_TREE_STATE=clean SOURCE_GIT_COMMIT=d1165cf12340cb5b748d620c980646d15e56e7a6 SOURCE_GIT_TAG=d1165cf1 SOURCE_GIT_URL=https://github.com/openshift/cluster-kube-controller-manager-operator SOURCE_DATE_EPOCH=1585183401 OS_GIT_COMMIT=d1165cf BUILD_VERSION=v4.1.41 BUILD_RELEASE=202004130646
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

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.1.41" \
        release="202004130646" \
        io.openshift.build.commit.id="d1165cf12340cb5b748d620c980646d15e56e7a6" \
        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/d1165cf12340cb5b748d620c980646d15e56e7a6"

