diff --git a/portainer/Dockerfile b/portainer/Dockerfile index 97b2fdea5..81c5f9f6e 100644 --- a/portainer/Dockerfile +++ b/portainer/Dockerfile @@ -24,17 +24,18 @@ FROM ${BUILD_FROM} SHELL ["/bin/bash", "-o", "pipefail", "-c"] # Setup base -ARG BUILD_ARCH=amd64 ARG BUILD_UPSTREAM="2.11.0" RUN \ BUILD_ARCH=$(uname -m) \ && echo "${BUILD_ARCH}" \ - && if [ "${BUILD_ARCH}" = "*aarch64*" ]; then ARCH="arm64"; fi \ - && if [ "${BUILD_ARCH}" = "*armv8*" ]; then ARCH="arm64"; fi \ - && if [ "${BUILD_ARCH}" = "*armhf*" ]; then ARCH="arm"; fi \ - && if [ "${BUILD_ARCH}" = "*armv7*" ]; then ARCH="arm"; fi \ - && if [ "${BUILD_ARCH}" = "*x86*" ]; then ARCH="amd64"; fi \ + && if [[ "${BUILD_ARCH}" == *aarch64* ]]; then ARCH="arm64"; fi \ + && if [[ "${BUILD_ARCH}" == *armv8* ]]; then ARCH="arm64"; fi \ + && if [[ "${BUILD_ARCH}" == *arm64* ]]; then ARCH="arm64"; fi \ + && if [[ "${BUILD_ARCH}" == *armhf* ]]; then ARCH="arm"; fi \ + && if [[ "${BUILD_ARCH}" == *armv7* ]]; then echo ARCH="arm"; fi \ + && if [[ "${BUILD_ARCH}" == arm ]]; then echo ARCH="arm"; fi \ + && if [[ "${BUILD_ARCH}" == *x86* ]]; then ARCH="amd64"; fi \ \ && curl -L -s \ "https://github.com/portainer/portainer/releases/download/${BUILD_UPSTREAM}/portainer-${BUILD_UPSTREAM}-linux-${ARCH}.tar.gz" \