diff options
author | Tilo Spannagel <development@tilosp.de> | 2017-06-29 18:40:05 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-06-29 18:40:05 +0200 |
commit | 58b8d167192fe77b825e843fdfa96ef5c07b5af3 (patch) | |
tree | febe1e122b1378288ba9d5e120187b75af787a7d | |
parent | 034ea8be5a2fa4fdaebdde2057c9de3de054789e (diff) | |
parent | 0bd790309e71d629a2cd5f21feb096557b1ca087 (diff) |
Merge pull request #113 from nextcloud/multi-arch
Add multi arch support
-rw-r--r-- | .travis.yml | 19 | ||||
-rw-r--r-- | 10.0/apache/Dockerfile | 5 | ||||
-rw-r--r-- | 10.0/fpm/Dockerfile | 5 | ||||
-rw-r--r-- | 11.0/apache/Dockerfile | 5 | ||||
-rw-r--r-- | 11.0/fpm/Dockerfile | 5 | ||||
-rw-r--r-- | 12.0/apache/Dockerfile | 5 | ||||
-rw-r--r-- | 12.0/fpm/Dockerfile | 5 | ||||
-rw-r--r-- | Dockerfile-php7.template | 5 | ||||
-rw-r--r-- | Dockerfile.template | 5 | ||||
-rwxr-xr-x | generate-stackbrew-library.sh | 1 | ||||
-rwxr-xr-x | update.sh | 4 |
11 files changed, 41 insertions, 23 deletions
diff --git a/.travis.yml b/.travis.yml index 5165ceb3..83276eef 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,6 +11,7 @@ install: before_script: - env | sort - image="nextcloud:${VERSION}${VARIANT:+-$VARIANT}" + - if [[ "$ARCH" == 'i386' ]]; then sed -i -e 's/FROM php/FROM i386\/php/g' "${VERSION}/${VARIANT}/Dockerfile"; fi script: - travis_retry docker build -t "$image" "${VERSION}/${VARIANT}" @@ -40,9 +41,15 @@ jobs: - ./generate-stackbrew-library.sh - stage: test images - env: VERSION=10.0 VARIANT=fpm - - env: VERSION=10.0 VARIANT=apache - - env: VERSION=11.0 VARIANT=fpm - - env: VERSION=11.0 VARIANT=apache - - env: VERSION=12.0 VARIANT=fpm - - env: VERSION=12.0 VARIANT=apache + env: VERSION=10.0 VARIANT=fpm ARCH=amd64 + - env: VERSION=10.0 VARIANT=fpm ARCH=i386 + - env: VERSION=10.0 VARIANT=apache ARCH=amd64 + - env: VERSION=10.0 VARIANT=apache ARCH=i386 + - env: VERSION=11.0 VARIANT=fpm ARCH=amd64 + - env: VERSION=11.0 VARIANT=fpm ARCH=i386 + - env: VERSION=11.0 VARIANT=apache ARCH=amd64 + - env: VERSION=11.0 VARIANT=apache ARCH=i386 + - env: VERSION=12.0 VARIANT=fpm ARCH=amd64 + - env: VERSION=12.0 VARIANT=fpm ARCH=i386 + - env: VERSION=12.0 VARIANT=apache ARCH=amd64 + - env: VERSION=12.0 VARIANT=apache ARCH=i386 diff --git a/10.0/apache/Dockerfile b/10.0/apache/Dockerfile index 570aef6c..d8b15972 100644 --- a/10.0/apache/Dockerfile +++ b/10.0/apache/Dockerfile @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysql opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/10.0/fpm/Dockerfile b/10.0/fpm/Dockerfile index b60b57f2..b160a46c 100644 --- a/10.0/fpm/Dockerfile +++ b/10.0/fpm/Dockerfile @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysql opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/11.0/apache/Dockerfile b/11.0/apache/Dockerfile index 71978ad8..d4c0ff52 100644 --- a/11.0/apache/Dockerfile +++ b/11.0/apache/Dockerfile @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysqli opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/11.0/fpm/Dockerfile b/11.0/fpm/Dockerfile index 78890a39..9aa10e0b 100644 --- a/11.0/fpm/Dockerfile +++ b/11.0/fpm/Dockerfile @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysqli opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/12.0/apache/Dockerfile b/12.0/apache/Dockerfile index 4bcc5f03..1b05272b 100644 --- a/12.0/apache/Dockerfile +++ b/12.0/apache/Dockerfile @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysqli opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/12.0/fpm/Dockerfile b/12.0/fpm/Dockerfile index d69e770e..41b7365f 100644 --- a/12.0/fpm/Dockerfile +++ b/12.0/fpm/Dockerfile @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysqli opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/Dockerfile-php7.template b/Dockerfile-php7.template index 203ba662..ef49df7d 100644 --- a/Dockerfile-php7.template +++ b/Dockerfile-php7.template @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysqli opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/Dockerfile.template b/Dockerfile.template index 14cf3626..581e9122 100644 --- a/Dockerfile.template +++ b/Dockerfile.template @@ -16,8 +16,9 @@ RUN apt-get update && apt-get install -y \ && rm -rf /var/lib/apt/lists/* # https://docs.nextcloud.com/server/9/admin_manual/installation/source_installation.html -RUN docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ - && docker-php-ext-configure ldap --with-libdir=lib/x86_64-linux-gnu \ +RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)" \ + && docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \ + && docker-php-ext-configure ldap --with-libdir="lib/$debMultiarch" \ && docker-php-ext-install gd exif intl mbstring mcrypt ldap mysql opcache pdo_mysql pdo_pgsql pgsql zip # set recommended PHP.ini settings diff --git a/generate-stackbrew-library.sh b/generate-stackbrew-library.sh index 9ede46c9..d016b36a 100755 --- a/generate-stackbrew-library.sh +++ b/generate-stackbrew-library.sh @@ -73,6 +73,7 @@ for version in "${versions[@]}"; do cat <<-EOE Tags: $(join ', ' "${variantAliases[@]}") + Architectures: amd64, arm32v7, arm64v8, i386, ppc64le, s390x GitCommit: $commit Directory: $version/$variant EOE @@ -59,7 +59,9 @@ for latest in "${latests[@]}"; do # Copy apps.config.php cp apps.config.php "$version/$variant/apps.config.php" - travisEnv='\n - env: VERSION='"$version"' VARIANT='"$variant$travisEnv" + for arch in i386 amd64; do + travisEnv='\n - env: VERSION='"$version"' VARIANT='"$variant"' ARCH='"$arch$travisEnv" + done done fi done |