From 248c58f1d2be662fde86edab09aa8ef937d7cf77 Mon Sep 17 00:00:00 2001 From: matus Date: Wed, 30 Oct 2019 13:59:46 +0100 Subject: [PATCH] add oc client --- Dockerfile | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 8515a8b..fbe6996 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,12 +1,22 @@ FROM maven:3.6.0-jdk-8 as build +ENV OC_VERSION=v3.11.0 \ + OC_TAG_SHA=0cbc58b + RUN curl "https://get.helm.sh/helm-v2.14.3-linux-amd64.tar.gz" -o "helm.tar.gz" \ && tar xzvf helm.tar.gz \ + && curl -sLo /tmp/oc.tar.gz https://github.com/openshift/origin/releases/download/${OC_VERSION}/openshift-origin-client-tools-${OC_VERSION}-${OC_TAG_SHA}-linux-64bit.tar.gz \ + && tar xzvf /tmp/oc.tar.gz -C /tmp/ \ + && mv /tmp/openshift-origin-client-tools-${OC_VERSION}-${OC_TAG_SHA}-linux-64bit/oc /tmp/ \ + && rm -rf /tmp/oc.tar.gz /tmp/openshift-origin-client-tools-${OC_VERSION}-${OC_TAG_SHA}-linux-64bit \ && ls -all . + + COPY .m2 /root/.m2 FROM maven:3.6.0-jdk-8 +COPY --from=build /tmp/oc /usr/local/bin/ COPY --from=build linux-amd64 /usr/local/bin -COPY --from=build /root/.m2 /root/.m2 \ No newline at end of file +COPY --from=build /root/.m2 /root/.m2