FROM openshift/golang-builder:rhel_8_golang_1.15 AS builder
ENV __doozer=update BUILD_RELEASE=202104030128.p0 BUILD_VERSION=v4.7.0 OS_GIT_MAJOR=4 OS_GIT_MINOR=7 OS_GIT_PATCH=0 OS_GIT_TREE_STATE=clean OS_GIT_VERSION=4.7.0-202104030128.p0 SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge KUBE_GIT_COMMIT=69f527e90f599e0f509cfce73ba7b95656f03f7f KUBE_GIT_MAJOR=1 KUBE_GIT_MINOR=20+ KUBE_GIT_TREE_STATE=clean KUBE_GIT_VERSION=v1.20.1+69f527e OS_GIT_COMMIT=69f527e OS_GIT_VERSION=4.7.0-202104030128.p0-69f527e SOURCE_DATE_EPOCH=1616500876 SOURCE_GIT_COMMIT=69f527e90f599e0f509cfce73ba7b95656f03f7f SOURCE_GIT_TAG=69f527e SOURCE_GIT_URL=https://github.com/openshift/oauth-apiserver 
WORKDIR /go/src/github.com/openshift/oauth-apiserver
COPY . .
RUN make build --warn-undefined-variables

FROM openshift/ose-base:v4.7.0.20210403.020833
ENV __doozer=update BUILD_RELEASE=202104030128.p0 BUILD_VERSION=v4.7.0 OS_GIT_MAJOR=4 OS_GIT_MINOR=7 OS_GIT_PATCH=0 OS_GIT_TREE_STATE=clean OS_GIT_VERSION=4.7.0-202104030128.p0 SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge KUBE_GIT_COMMIT=69f527e90f599e0f509cfce73ba7b95656f03f7f KUBE_GIT_MAJOR=1 KUBE_GIT_MINOR=20+ KUBE_GIT_TREE_STATE=clean KUBE_GIT_VERSION=v1.20.1+69f527e OS_GIT_COMMIT=69f527e OS_GIT_VERSION=4.7.0-202104030128.p0-69f527e SOURCE_DATE_EPOCH=1616500876 SOURCE_GIT_COMMIT=69f527e90f599e0f509cfce73ba7b95656f03f7f SOURCE_GIT_TAG=69f527e SOURCE_GIT_URL=https://github.com/openshift/oauth-apiserver 
COPY --from=builder /go/src/github.com/openshift/oauth-apiserver/oauth-apiserver /usr/bin/
ENTRYPOINT ["/usr/bin/oauth-apiserver"]

LABEL \
        io.k8s.display-name="OpenShift OAuth API Server Command" \
        io.k8s.description="OpenShift is a platform for developing, building, and deploying containerized applications." \
        io.openshift.tags="openshift,oauth-apiserver" \
        name="openshift/ose-oauth-apiserver" \
        com.redhat.component="ose-oauth-apiserver-container" \
        io.openshift.maintainer.product="OpenShift Container Platform" \
        io.openshift.maintainer.component="oauth-apiserver" \
        release="202104030128.p0" \
        io.openshift.build.commit.id="69f527e90f599e0f509cfce73ba7b95656f03f7f" \
        io.openshift.build.source-location="https://github.com/openshift/oauth-apiserver" \
        io.openshift.build.commit.url="https://github.com/openshift/oauth-apiserver/commit/69f527e90f599e0f509cfce73ba7b95656f03f7f" \
        version="v4.7.0"

