Public Repository

Last pushed: 23 days ago
Short Description
Secure, minimal, signed php-fpm alpine image with pre-installed PHP extensions gd, mysqli, opcache.
Full Description

Good for Wordpress, MediaWiki.

Dockerfile


# https://github.com/docker-library/wordpress/blob/master/php7.2/fpm-alpine/Dockerfile
FROM php:7.2.1-fpm-alpine3.7

RUN set -ex; \
    apk add --no-cache --virtual .build-deps \
        libjpeg-turbo-dev \
        libpng-dev \
    ; \
    docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr; \
    docker-php-ext-install gd mysqli opcache; \
    runDeps="$( \
        scanelf --needed --nobanner --format '%n#p' --recursive /usr/local/lib/php/extensions \
            | tr ',' '\n' \
            | sort -u \
            | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' \
    )"; \
    apk add --virtual .phpexts-rundeps $runDeps; \
    apk del .build-deps; \
    { \
        echo 'opcache.memory_consumption=128'; \
        echo 'opcache.interned_strings_buffer=8'; \
        echo 'opcache.max_accelerated_files=4000'; \
        echo 'opcache.revalidate_freq=2'; \
        echo 'opcache.fast_shutdown=1'; \
        echo 'opcache.enable_cli=1'; \
    } > /usr/local/etc/php/conf.d/opcache-recommended.ini

VOLUME /var/www/html

ENTRYPOINT ["php-fpm"]
Docker Pull Command
Owner
quiq