FROM openshift/golang-builder:1.10 AS builder
ENV OS_GIT_MAJOR=4 OS_GIT_MINOR=1 OS_GIT_PATCH=37 OS_GIT_VERSION=4.1.37-202003021622-3c2f857 OS_GIT_TREE_STATE=clean SOURCE_GIT_COMMIT=3c2f85724078cbf7ffab56886ff32d677c386afe SOURCE_GIT_TAG=v0.2.2-17-g3c2f857 SOURCE_GIT_URL=https://github.com/openshift/configmap-reload SOURCE_DATE_EPOCH=1545120384 OS_GIT_COMMIT=3c2f857 BUILD_VERSION=v4.1.37 BUILD_RELEASE=202003021622
WORKDIR /go/src/github.com/jimmidyson/configmap-reload
COPY . .
RUN make out/configmap-reload

FROM openshift/ose-base:v4.1.37.20200302.165904
ENV OS_GIT_MAJOR=4 OS_GIT_MINOR=1 OS_GIT_PATCH=37 OS_GIT_VERSION=4.1.37-202003021622-3c2f857 OS_GIT_TREE_STATE=clean SOURCE_GIT_COMMIT=3c2f85724078cbf7ffab56886ff32d677c386afe SOURCE_GIT_TAG=v0.2.2-17-g3c2f857 SOURCE_GIT_URL=https://github.com/openshift/configmap-reload SOURCE_DATE_EPOCH=1545120384 OS_GIT_COMMIT=3c2f857 BUILD_VERSION=v4.1.37 BUILD_RELEASE=202003021622

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" \
        maintainer="Frederic Branczyk <fbranczy@redhat.com>" \
        License="ASL 2.0" \
        vendor="Red Hat" \
        name="openshift/ose-configmap-reloader" \
        com.redhat.component="configmap-reload-container" \
        version="v4.1.37" \
        release="202003021622" \
        io.openshift.build.commit.id="3c2f85724078cbf7ffab56886ff32d677c386afe" \
        io.openshift.build.source-location="https://github.com/openshift/configmap-reload" \
        io.openshift.build.commit.url="https://github.com/openshift/configmap-reload/commit/3c2f85724078cbf7ffab56886ff32d677c386afe"

