Skip to content

Instantly share code, notes, and snippets.

@arubacao
Created October 30, 2016 15:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arubacao/5ec3d3cc5ab73b3f34aeec55d31839e3 to your computer and use it in GitHub Desktop.
Save arubacao/5ec3d3cc5ab73b3f34aeec55d31839e3 to your computer and use it in GitHub Desktop.
trying to get php curl updated
FROM php:7.0-fpm
MAINTAINER Christopher Lass <arubacao@gmail.com>
# Software's Installation
#--------------------------------------------------------------------------
#
# Installing tools and PHP extentions using "apt", "docker-php", "pecl",
#
# Install "curl", "libmemcached-dev", "libpq-dev", "libjpeg-dev",
# "libpng12-dev", "libfreetype6-dev", "libssl-dev", "libmcrypt-dev",
RUN apt-get update && \
apt-get install -y --no-install-recommends \
curl \
libz-dev \
libpq-dev \
libjpeg-dev \
libpng12-dev \
libfreetype6-dev \
libssl-dev \
libmcrypt-dev
# Upgrade curl
# @source: https://gist.github.com/fideloper/f72997d2e2c9fbe66459
RUN curl -fsSL 'http://curl.haxx.se/download/curl-7.50.3.tar.gz' -o curl.tar.gz \
&& mkdir -p curl \
&& tar -xf curl.tar.gz -C curl --strip-components=1 \
&& rm curl.tar.gz \
&& ( \
cd curl \
&& make \
&& make install \
&& ldconfig \
) \
&& rm -r curl
# Install the PHP mcrypt extention
RUN docker-php-ext-install mcrypt
# Install the PHP pdo_mysql extention
RUN docker-php-ext-install pdo_mysql
# Install the PHP gd library
RUN docker-php-ext-configure gd \
--enable-gd-native-ttf \
--with-jpeg-dir=/usr/lib \
--with-freetype-dir=/usr/include/freetype2 && \
docker-php-ext-install gd
# Install the PHP exif library
RUN docker-php-ext-install exif
# Install the xdebug extension
RUN pecl install xdebug && \
docker-php-ext-enable xdebug
# Install the mongodb extension
RUN pecl install mongodb && \
docker-php-ext-enable mongodb
EXPOSE 9000
CMD ["php-fpm"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment