repositories
/
mbt-docker.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add hardware architecture check at SAP machine installation
[mbt-docker.git]
/
Dockerfile
diff --git
a/Dockerfile
b/Dockerfile
index cc013d88fb3700a039a895c9e2d8b209b4460fac..5be6ec411f7b673f670f7343af8a57c2073b9f47 100644
(file)
--- a/
Dockerfile
+++ b/
Dockerfile
@@
-113,12
+113,17
@@
RUN set -ex \
ARG SAPMACHINE_VERSION=11.0.16.1
ARG SAPMACHINE_VERSION=11.0.16.1
-RUN set -ex \
+RUN ARCH= && dpkgArch="$(dpkg --print-architecture)" \
+ && case "${dpkgArch##*-}" in \
+ amd64) ARCH='amd64';; \
+ *) echo "unsupported architecture"; exit 1 ;; \
+ esac \
+ && set -ex \
&& apt-get update \
&& apt-get install -y ca-certificates wget --no-install-recommends \
&& rm -rf /var/lib/apt/lists/* \
&& wget -q -O - https://dist.sapmachine.io/debian/sapmachine.key | tee /etc/apt/trusted.gpg.d/sapmachine.gpg.asc \
&& apt-get update \
&& apt-get install -y ca-certificates wget --no-install-recommends \
&& rm -rf /var/lib/apt/lists/* \
&& wget -q -O - https://dist.sapmachine.io/debian/sapmachine.key | tee /etc/apt/trusted.gpg.d/sapmachine.gpg.asc \
- && echo "deb http://dist.sapmachine.io/debian/
amd64
/ ./" | tee /etc/apt/sources.list.d/sapmachine.list \
+ && echo "deb http://dist.sapmachine.io/debian/
${ARCH}
/ ./" | tee /etc/apt/sources.list.d/sapmachine.list \
&& apt-get update \
&& apt-get install -y sapmachine-$(echo ${SAPMACHINE_VERSION} | cut -d. -f1)-jdk=${SAPMACHINE_VERSION} --no-install-recommends \
&& rm -rf /var/lib/apt/lists/* \
&& apt-get update \
&& apt-get install -y sapmachine-$(echo ${SAPMACHINE_VERSION} | cut -d. -f1)-jdk=${SAPMACHINE_VERSION} --no-install-recommends \
&& rm -rf /var/lib/apt/lists/* \