FROM openshift/golang-builder:1.12 AS builder
ENV SOURCE_GIT_COMMIT=3ac077fa8097fb851532453fa6e772e1dcfcb3bb SOURCE_DATE_EPOCH=1573452672 BUILD_VERSION=v4.2.9 SOURCE_GIT_URL=https://github.com/openshift/oauth-server SOURCE_GIT_TAG=v0.0.0-alpha.0-15-g3ac077fa BUILD_RELEASE=201911261133
WORKDIR /go/src/github.com/openshift/oauth-server
COPY . .
RUN make build --warn-undefined-variables

FROM openshift/ose-base:v4.2.9.20191126.113339
ENV SOURCE_GIT_COMMIT=3ac077fa8097fb851532453fa6e772e1dcfcb3bb SOURCE_DATE_EPOCH=1573452672 BUILD_VERSION=v4.2.9 SOURCE_GIT_URL=https://github.com/openshift/oauth-server SOURCE_GIT_TAG=v0.0.0-alpha.0-15-g3ac077fa BUILD_RELEASE=201911261133
COPY --from=builder /go/src/github.com/openshift/oauth-server/oauth-server /usr/bin/
ENTRYPOINT ["/usr/bin/oauth-server"]

LABEL \
        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.k8s.display-name="OpenShift OAuth Server" \
        io.openshift.build.source-location="https://github.com/openshift/oauth-server" \
        io.openshift.build.commit.url="https://github.com/openshift/oauth-server/commit/3ac077fa8097fb851532453fa6e772e1dcfcb3bb" \
        version="v4.2.9" \
        io.openshift.build.commit.id="3ac077fa8097fb851532453fa6e772e1dcfcb3bb" \
        release="201911261133" \
        io.openshift.tags="openshift, oauth-server"

