Docker gd module for PHP 7
<p>I've got docker file, which is configured for Drupal 8, but after I fired up "docker-compose up", everything went smooth but in installation of Drupal it's showing me that "gd" module for PHP is not enabled.</p>

<p>here is my Dockerfile:</p>

<pre><code>FROM php:7-fpm
# Install modules
RUN apt-get update

RUN apt-get install -y software-properties-common

RUN DEBIAN_FRONTEND="noninteractive" add-apt-repository ppa:ondrej/php

RUN apt-get update

RUN apt-get install -y vim curl wget build-essential software-properties-common git ca-certificates

RUN apt-get install -y \
    libbz2-dev \
    libfreetype6-dev \
    libjpeg62-turbo-dev \
    libpng12-dev \
    libxpm-dev \
    libvpx-dev \
    libmcrypt-dev \
    libmemcached-dev \
    &amp;&amp; \

apt-get clean &amp;&amp; \
    rm -rf /var/lib/apt/lists/* &amp;&amp; \

docker-php-ext-configure gd \
        --with-freetype-dir=/usr/lib/x86_64-linux-gnu/ \
        --with-jpeg-dir=/usr/lib/x86_64-linux-gnu/ \
        --with-xpm-dir=/usr/lib/x86_64-linux-gnu/ \
        --with-vpx-dir=/usr/lib/x86_64-linux-gnu/ \
    &amp;&amp; \

docker-php-ext-install \
        bcmath \
        bz2 \
        exif \
        ftp \
        gd \
        gettext \
        mbstring \
        mcrypt \
        mysqli \
        opcache \
        pdo_mysql \
        shmop \
        sockets \
        sysvmsg \
        sysvsem \
        sysvshm \
        zip \
    &amp;&amp; \

    pecl install apcu memcached &amp;&amp; \
    echo 'extension = apcu.so' &gt; /usr/local/etc/php/conf.d/apcu.ini &amp;&amp; \
    echo 'extension = memcached.so' &gt; /usr/local/etc/php/conf.d/memcached.ini
</code></pre>

<p>I try this method: <a href="https://stackoverflow.com/questions/10565521/error-in-php5-unable-to-load-dynamic-library">Error In PHP5 ..Unable to load dynamic library</a>
But no use</p>