FROM openshift/golang-builder:1.13 AS builder
ENV __doozer=update BUILD_RELEASE=202010081339.p0 BUILD_VERSION=v4.4.0 OS_GIT_MAJOR=4 OS_GIT_MINOR=4 OS_GIT_PATCH=0 OS_GIT_TREE_STATE=clean OS_GIT_VERSION=4.4.0-202010081339.p0 SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge OS_GIT_COMMIT=054e15e OS_GIT_VERSION=4.4.0-202010081339.p0-054e15e SOURCE_DATE_EPOCH=1587401222 SOURCE_GIT_COMMIT=054e15e5f629395d4a0b5457b5b594790149d26e SOURCE_GIT_TAG=v0.0.0-alpha.0-49-g054e15e5 SOURCE_GIT_URL=https://github.com/openshift/oauth-server 
WORKDIR /go/src/github.com/openshift/oauth-server
COPY . .
ENV GO_PACKAGE github.com/openshift/oauth-server
RUN make build --warn-undefined-variables

FROM openshift/ose-base:v4.4.0.20201008.151351
ENV __doozer=update BUILD_RELEASE=202010081339.p0 BUILD_VERSION=v4.4.0 OS_GIT_MAJOR=4 OS_GIT_MINOR=4 OS_GIT_PATCH=0 OS_GIT_TREE_STATE=clean OS_GIT_VERSION=4.4.0-202010081339.p0 SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge OS_GIT_COMMIT=054e15e OS_GIT_VERSION=4.4.0-202010081339.p0-054e15e SOURCE_DATE_EPOCH=1587401222 SOURCE_GIT_COMMIT=054e15e5f629395d4a0b5457b5b594790149d26e SOURCE_GIT_TAG=v0.0.0-alpha.0-49-g054e15e5 SOURCE_GIT_URL=https://github.com/openshift/oauth-server 
COPY --from=builder /go/src/github.com/openshift/oauth-server/oauth-server /usr/bin/
ENTRYPOINT ["/usr/bin/oauth-server"]

LABEL \
        io.k8s.display-name="OpenShift OAuth Server" \
        io.k8s.description="This is a component of OpenShift and enables cluster authentication" \
        com.redhat.component="oauth-server-container" \
        name="openshift/ose-oauth-server" \
        io.openshift.tags="openshift, oauth-server" \
        io.openshift.maintainer.product="OpenShift Container Platform" \
        io.openshift.maintainer.component="apiserver-auth" \
        release="202010081339.p0" \
        io.openshift.build.commit.id="054e15e5f629395d4a0b5457b5b594790149d26e" \
        io.openshift.build.source-location="https://github.com/openshift/oauth-server" \
        io.openshift.build.commit.url="https://github.com/openshift/oauth-server/commit/054e15e5f629395d4a0b5457b5b594790149d26e" \
        version="v4.4.0"

