FROM openshift/golang-builder:1.12 AS builder
ENV SOURCE_GIT_COMMIT=a5adc1e9012b1dd166681c378c577c070aa376a4 SOURCE_GIT_TAG=v1.0.0-rc2-211-ga5adc1e9 SOURCE_GIT_URL=https://github.com/openshift/csi-external-snapshotter SOURCE_DATE_EPOCH=1571130205 BUILD_VERSION=v4.3.2 BUILD_RELEASE=202002070552
WORKDIR /go/src/github.com/kubernetes-csi/external-snapshotter
COPY . .
RUN make build

FROM openshift/ose-base:v4.3.2.20200207.061618
ENV SOURCE_GIT_COMMIT=a5adc1e9012b1dd166681c378c577c070aa376a4 SOURCE_GIT_TAG=v1.0.0-rc2-211-ga5adc1e9 SOURCE_GIT_URL=https://github.com/openshift/csi-external-snapshotter SOURCE_DATE_EPOCH=1571130205 BUILD_VERSION=v4.3.2 BUILD_RELEASE=202002070552
COPY --from=builder /go/src/github.com/kubernetes-csi/external-snapshotter/bin/csi-snapshotter /usr/bin/
ENTRYPOINT ["/usr/bin/csi-snapshotter"]

LABEL \
        name="openshift/ose-csi-external-snapshotter" \
        com.redhat.component="ose-csi-external-snapshotter-container" \
        version="v4.3.2" \
        release="202002070552" \
        io.openshift.build.commit.id="a5adc1e9012b1dd166681c378c577c070aa376a4" \
        io.openshift.build.source-location="https://github.com/openshift/csi-external-snapshotter" \
        io.openshift.build.commit.url="https://github.com/openshift/csi-external-snapshotter/commit/a5adc1e9012b1dd166681c378c577c070aa376a4"

