# Dockerfile used by OSBS and by prow CI.
FROM openshift/golang-builder:rhel_8_golang_1.15 AS builder
ENV __doozer=update BUILD_RELEASE=202106011423.p0.git.25dfb67 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-202106011423.p0.git.25dfb67 SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge OS_GIT_COMMIT=25dfb67 OS_GIT_VERSION=4.7.0-202106011423.p0.git.25dfb67-25dfb67 SOURCE_DATE_EPOCH=1602242493 SOURCE_GIT_COMMIT=25dfb671c6ce9a73f5594efe699ed410fbf01d44 SOURCE_GIT_TAG=v0.2.2-50-g25dfb67 SOURCE_GIT_URL=https://github.com/openshift/configmap-reload 
WORKDIR /go/src/github.com/jimmidyson/configmap-reload
COPY . .
ENV GOFLAGS="-mod=vendor"
RUN make out/configmap-reload

FROM openshift/ose-base:v4.7.0.20210601.144050
ENV __doozer=update BUILD_RELEASE=202106011423.p0.git.25dfb67 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-202106011423.p0.git.25dfb67 SOURCE_GIT_TREE_STATE=clean 
ENV __doozer=merge OS_GIT_COMMIT=25dfb67 OS_GIT_VERSION=4.7.0-202106011423.p0.git.25dfb67-25dfb67 SOURCE_DATE_EPOCH=1602242493 SOURCE_GIT_COMMIT=25dfb671c6ce9a73f5594efe699ed410fbf01d44 SOURCE_GIT_TAG=v0.2.2-50-g25dfb67 SOURCE_GIT_URL=https://github.com/openshift/configmap-reload 

ARG FROM_DIRECTORY=/go/src/github.com/jimmidyson/configmap-reload
COPY --from=builder ${FROM_DIRECTORY}/out/configmap-reload  /usr/bin/configmap-reload

USER nobody

ENTRYPOINT ["/usr/bin/configmap-reload"]

LABEL \
        io.k8s.display-name="configmap reload" \
        io.k8s.description="This is a component reloads another process if a configured configmap volume is remounted." \
        io.openshift.tags="kubernetes" \
        summary="This is a component reloads another process if a configured configmap volume is remounted." \
        maintainer="OpenShift Monitoring Team <team-monitoring@redhat.com>" \
        License="ASL 2.0" \
        vendor="Red Hat" \
        name="openshift/ose-configmap-reloader" \
        com.redhat.component="configmap-reload-container" \
        io.openshift.maintainer.product="OpenShift Container Platform" \
        io.openshift.maintainer.component="Monitoring" \
        release="202106011423.p0.git.25dfb67" \
        io.openshift.build.commit.id="25dfb671c6ce9a73f5594efe699ed410fbf01d44" \
        io.openshift.build.source-location="https://github.com/openshift/configmap-reload" \
        io.openshift.build.commit.url="https://github.com/openshift/configmap-reload/commit/25dfb671c6ce9a73f5594efe699ed410fbf01d44" \
        version="v4.7.0"

