FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.15-openshift-4.7 AS builder
WORKDIR /go/src/github.com/openshift/oauth-apiserver
COPY . .
RUN make build --warn-undefined-variables

FROM registry.ci.openshift.org/ocp/4.7:base
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"
