mirror of
https://github.com/hoellen/dockerfiles.git
synced 2025-04-20 04:19:18 +00:00
lychee: add imagick (faster processing)
This commit is contained in:
parent
2bdcf2e997
commit
f2dc774049
@ -1,16 +1,25 @@
|
|||||||
FROM alpine:3.3
|
FROM alpine:edge
|
||||||
MAINTAINER Wonderfall <wonderfall@schrodinger.io>
|
MAINTAINER Wonderfall <wonderfall@schrodinger.io>
|
||||||
|
|
||||||
ARG VERSION=3.1.1
|
ARG LYCHEE_VERSION=3.1.1
|
||||||
|
ARG IMAGICK_EXT_VERSION=3.4.2
|
||||||
|
|
||||||
ENV UID=991 GID=991
|
ENV UID=991 GID=991
|
||||||
|
|
||||||
RUN echo "@commuedge http://nl.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \
|
RUN echo "@commuedge http://nl.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \
|
||||||
&& echo "@testing http://nl.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories \
|
&& echo "@testing http://nl.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories \
|
||||||
&& echo "@edge http://nl.alpinelinux.org/alpine/edge/main" >> /etc/apk/repositories \
|
&& BUILD_DEPS=" \
|
||||||
|
imagemagick-dev \
|
||||||
|
tar \
|
||||||
|
openssl \
|
||||||
|
ca-certificates \
|
||||||
|
build-base \
|
||||||
|
autoconf \
|
||||||
|
libtool" \
|
||||||
&& apk -U add \
|
&& apk -U add \
|
||||||
|
${BUILD_DEPS} \
|
||||||
nginx \
|
nginx \
|
||||||
libwebp@edge \
|
libwebp \
|
||||||
php7-mbstring@testing \
|
php7-mbstring@testing \
|
||||||
php7-fpm@testing \
|
php7-fpm@testing \
|
||||||
php7-exif@testing \
|
php7-exif@testing \
|
||||||
@ -19,9 +28,10 @@ RUN echo "@commuedge http://nl.alpinelinux.org/alpine/edge/community" >> /etc/ap
|
|||||||
php7-mysqli@testing \
|
php7-mysqli@testing \
|
||||||
php7-zip@testing \
|
php7-zip@testing \
|
||||||
php7-session@testing \
|
php7-session@testing \
|
||||||
tar \
|
php7-pear@testing \
|
||||||
|
php7-dev@testing \
|
||||||
supervisor \
|
supervisor \
|
||||||
ca-certificates \
|
imagemagick \
|
||||||
tini@commuedge \
|
tini@commuedge \
|
||||||
&& sed -i -e "s/max_execution_time = 30/max_execution_time = 200/g" \
|
&& sed -i -e "s/max_execution_time = 30/max_execution_time = 200/g" \
|
||||||
-e "s/post_max_size = 8M/post_max_size = 100M/g" \
|
-e "s/post_max_size = 8M/post_max_size = 100M/g" \
|
||||||
@ -29,11 +39,13 @@ RUN echo "@commuedge http://nl.alpinelinux.org/alpine/edge/community" >> /etc/ap
|
|||||||
-e "s/memory_limit = 256M/memory_limit = 512M/g" \
|
-e "s/memory_limit = 256M/memory_limit = 512M/g" \
|
||||||
/etc/php7/php.ini \
|
/etc/php7/php.ini \
|
||||||
&& mkdir /lychee && cd /lychee \
|
&& mkdir /lychee && cd /lychee \
|
||||||
&& wget -qO- https://github.com/electerious/Lychee/archive/v$VERSION.tar.gz | tar xz --strip 1 \
|
&& wget -qO- https://github.com/electerious/Lychee/archive/v${LYCHEE_VERSION}.tar.gz | tar xz --strip 1 \
|
||||||
&& apk del \
|
&& cd /tmp && wget -q https://pecl.php.net/get/imagick-${IMAGICK_EXT_VERSION}.tgz \
|
||||||
tar \
|
&& tar xzf imagick-${IMAGICK_EXT_VERSION}.tgz && cd imagick-${IMAGICK_EXT_VERSION} \
|
||||||
ca-certificates \
|
&& phpize7 && ./configure --with-php-config=/usr/bin/php-config7 && make && make install \
|
||||||
&& rm -f /var/cache/apk/*
|
&& echo "extension=imagick.so" > /etc/php7/conf.d/00_imagick.ini \
|
||||||
|
&& apk del ${BUILD_DEPS} php7-pear php7-dev \
|
||||||
|
&& rm -rf /var/cache/apk/* /tmp/*
|
||||||
|
|
||||||
COPY nginx.conf /etc/nginx/nginx.conf
|
COPY nginx.conf /etc/nginx/nginx.conf
|
||||||
COPY php-fpm.conf /etc/php7/php-fpm.conf
|
COPY php-fpm.conf /etc/php7/php-fpm.conf
|
||||||
|
Loading…
x
Reference in New Issue
Block a user