summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMohammed Naser <mnaser@vexxhost.com>2018-04-16 10:11:45 -0700
committerMohammed Naser <mnaser@vexxhost.com>2018-04-16 10:12:47 -0700
commit5342c16687e712add95e7068f8ec7d44ec1476f9 (patch)
tree9d7e5a48eed0cdd9fe1b971aca0e4d572b7b9ac8
parent6f66c913d1e7a23855f142ce5f87f3946cdc7016 (diff)
Dynamically determine image architecture
The image architecture is currently hardcoded, this patch removes that hardcoded value to allow for ARM64 builds to go through. Change-Id: If0ee75f1bc8f688a35ad63ecc5ca413fb073490f Issue-ID: CIMAN-154 Signed-off-by: Mohammed Naser <mnaser@vexxhost.com>
-rw-r--r--distribution/src/main/assembly/Dockerfile6
1 files changed, 3 insertions, 3 deletions
diff --git a/distribution/src/main/assembly/Dockerfile b/distribution/src/main/assembly/Dockerfile
index e88bc2d..5dd1b18 100644
--- a/distribution/src/main/assembly/Dockerfile
+++ b/distribution/src/main/assembly/Dockerfile
@@ -10,9 +10,9 @@ RUN apt-get update
RUN apt-get install -y openjdk-8-jdk
#configure the JDK
-RUN sed -i 's|#networkaddress.cache.ttl=-1|networkaddress.cache.ttl=10|' /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/security/java.security
-ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64
-ENV PATH $PATH:/usr/lib/jvm/java-8-openjdk-amd64/jre/bin:/usr/lib/jvm/java-8-openjdk-amd64/bin
+RUN sed -i 's|#networkaddress.cache.ttl=-1|networkaddress.cache.ttl=10|' /usr/lib/jvm/java-8-openjdk-$(dpkg --print-architecture)/jre/lib/security/java.security
+ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-$(dpkg --print-architecture)
+ENV PATH $PATH:/usr/lib/jvm/java-8-openjdk-$(dpkg --print-architecture)/jre/bin:/usr/lib/jvm/java-8-openjdk-$(dpkg --print-architecture)/bin
ENV CLASSPATH .:${JAVA_HOME}/lib:${JRE_HOME}/lib
ENV JRE_HOME ${JAVA_HOME}/jre