FROM openshift/golang-builder:1.11 AS builder
ENV SOURCE_GIT_COMMIT=12e7540dea0bc001948af9e7a0028f9da398303e SOURCE_DATE_EPOCH=1575583352 BUILD_VERSION=v4.2.11 SOURCE_GIT_URL=https://github.com/openshift/cluster-samples-operator SOURCE_GIT_TAG=12e7540 BUILD_RELEASE=201912100122
WORKDIR /go/src/github.com/openshift/cluster-samples-operator
COPY . .
RUN make build

FROM openshift/ose-base:ubi7
ENV SOURCE_GIT_COMMIT=12e7540dea0bc001948af9e7a0028f9da398303e SOURCE_DATE_EPOCH=1575583352 BUILD_VERSION=v4.2.11 SOURCE_GIT_URL=https://github.com/openshift/cluster-samples-operator SOURCE_GIT_TAG=12e7540 BUILD_RELEASE=201912100122
COPY --from=builder /go/src/github.com/openshift/cluster-samples-operator/cluster-samples-operator /usr/bin/
COPY manifests/image-references manifests/0* /manifests/
COPY tmp/build/assets /opt/openshift/
RUN useradd cluster-samples-operator
USER cluster-samples-operator
ENTRYPOINT []
CMD ["/usr/bin/cluster-samples-operator"]

LABEL \
        com.redhat.component="ose-cluster-samples-operator-container" \
        name="openshift/ose-cluster-samples-operator" \
        io.openshift.build.source-location="https://github.com/openshift/cluster-samples-operator" \
        io.openshift.release.operator="true" \
        io.openshift.build.commit.url="https://github.com/openshift/cluster-samples-operator/commit/12e7540dea0bc001948af9e7a0028f9da398303e" \
        version="v4.2.11" \
        io.openshift.build.commit.id="12e7540dea0bc001948af9e7a0028f9da398303e" \
        release="201912100122"

