Add imagick module to enable TIFF image conversion (#124)
authorThomas B <redacted>
Mon, 18 Jan 2021 20:35:37 +0000 (21:35 +0100)
committerGitHub <redacted>
Mon, 18 Jan 2021 20:35:37 +0000 (21:35 +0100)
* Add imagick module to enable TIFF image conversion

fixes issue #123

apache/Dockerfile
fpm-alpine/Dockerfile
fpm/Dockerfile
templates/Dockerfile-alpine.templ
templates/Dockerfile-debian.templ

index 923432e79617bfbfca828669b0adc386ee79de5c..df2dab8153b6e0c0aff51232f125f2c309ee6f66 100644 (file)
@@ -11,6 +11,7 @@ RUN set -ex; \
                libicu-dev \
                libjpeg62-turbo-dev \
                libldap2-dev \
+               libmagickwand-dev \
                libpng-dev \
                libpq-dev \
                libsqlite3-dev \
@@ -30,6 +31,8 @@ RUN set -ex; \
                pdo_sqlite \
                zip \
        ; \
+       pecl install imagick; \
+       docker-php-ext-enable imagick; \
        \
 # reset apt-mark's "manual" list so that "purge --auto-remove" will remove all build dependencies
        apt-mark auto '.*' > /dev/null; \
@@ -60,7 +63,6 @@ ADD https://getcomposer.org/installer /tmp/composer-installer.php
 RUN php /tmp/composer-installer.php --install-dir=/usr/local/bin/; \
        rm /tmp/composer-installer.php
 
-# enable mod_rewrite
 RUN a2enmod rewrite
 
 # expose these volumes
index 6550b8991c07f2ca6b619973a84966c174491338..e251a16193424de9af0dbabc8e6738fbb9019648 100644 (file)
@@ -13,10 +13,13 @@ RUN set -ex; \
 RUN set -ex; \
        \
        apk add --no-cache --virtual .build-deps \
+               $PHPIZE_DEPS \
                icu-dev \
+               imagemagick-dev \
                libjpeg-turbo-dev \
                libpng-dev \
                libzip-dev \
+               libtool \
                openldap-dev \
                postgresql-dev \
                sqlite-dev \
@@ -34,6 +37,8 @@ RUN set -ex; \
                pdo_sqlite \
                zip \
        ; \
+       pecl install imagick; \
+       docker-php-ext-enable imagick; \
        \
        runDeps="$( \
                scanelf --needed --nobanner --format '%n#p' --recursive /usr/local/lib/php/extensions \
@@ -41,7 +46,7 @@ RUN set -ex; \
                | sort -u \
                | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' \
                )"; \
-       apk add --virtual .roundcubemail-phpext-rundeps $runDeps; \
+       apk add --virtual .roundcubemail-phpext-rundeps imagemagick $runDeps; \
        apk del .build-deps
 
 # add composer.phar
@@ -50,6 +55,7 @@ ADD https://getcomposer.org/installer /tmp/composer-installer.php
 RUN php /tmp/composer-installer.php --install-dir=/usr/local/bin/; \
        rm /tmp/composer-installer.php
 
+
 # expose these volumes
 VOLUME /var/roundcube/config
 VOLUME /var/roundcube/db
index a01c1d22ddaac87acb4ce7658e70b5b23f451d15..a6796433f8b57c1bf7b30b4158774a3d5a4f6e1b 100644 (file)
@@ -11,6 +11,7 @@ RUN set -ex; \
                libicu-dev \
                libjpeg62-turbo-dev \
                libldap2-dev \
+               libmagickwand-dev \
                libpng-dev \
                libpq-dev \
                libsqlite3-dev \
@@ -30,6 +31,8 @@ RUN set -ex; \
                pdo_sqlite \
                zip \
        ; \
+       pecl install imagick; \
+       docker-php-ext-enable imagick; \
        \
 # reset apt-mark's "manual" list so that "purge --auto-remove" will remove all build dependencies
        apt-mark auto '.*' > /dev/null; \
@@ -60,6 +63,7 @@ ADD https://getcomposer.org/installer /tmp/composer-installer.php
 RUN php /tmp/composer-installer.php --install-dir=/usr/local/bin/; \
        rm /tmp/composer-installer.php
 
+
 # expose these volumes
 VOLUME /var/roundcube/config
 VOLUME /var/roundcube/db
index 98831631ba0e6de8d5541b5df85069874d569b26..37a66480f7731ed5729984281be748b25d18d3dc 100644 (file)
@@ -13,10 +13,13 @@ RUN set -ex; \
 RUN set -ex; \
        \
        apk add --no-cache --virtual .build-deps \
+               $PHPIZE_DEPS \
                icu-dev \
+               imagemagick-dev \
                libjpeg-turbo-dev \
                libpng-dev \
                libzip-dev \
+               libtool \
                openldap-dev \
                postgresql-dev \
                sqlite-dev \
@@ -34,6 +37,8 @@ RUN set -ex; \
                pdo_sqlite \
                zip \
        ; \
+       pecl install imagick; \
+       docker-php-ext-enable imagick; \
        \
        runDeps="$( \
                scanelf --needed --nobanner --format '%n#p' --recursive /usr/local/lib/php/extensions \
@@ -41,7 +46,7 @@ RUN set -ex; \
                | sort -u \
                | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' \
                )"; \
-       apk add --virtual .roundcubemail-phpext-rundeps $runDeps; \
+       apk add --virtual .roundcubemail-phpext-rundeps imagemagick $runDeps; \
        apk del .build-deps
 
 # add composer.phar
index b47fef05653bfd18f431d7ab0a32eb3bf9b7b761..89f0b7d6fab12e0be362a34def259178423c748a 100644 (file)
@@ -11,6 +11,7 @@ RUN set -ex; \
                libicu-dev \
                libjpeg62-turbo-dev \
                libldap2-dev \
+               libmagickwand-dev \
                libpng-dev \
                libpq-dev \
                libsqlite3-dev \
@@ -30,6 +31,8 @@ RUN set -ex; \
                pdo_sqlite \
                zip \
        ; \
+       pecl install imagick; \
+       docker-php-ext-enable imagick; \
        \
 # reset apt-mark's "manual" list so that "purge --auto-remove" will remove all build dependencies
        apt-mark auto '.*' > /dev/null; \
git clone https://git.99rst.org/PROJECT