forked from merorafael/docker-php
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
76 lines (69 loc) · 2 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
FROM php:5.6-zts
# Get repository and install wget and vim
RUN apt-get update && apt-get install --no-install-recommends -y \
wget \
vim \
git \
unzip
# Add PostgreSQL repository
RUN echo "deb http://apt.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/apt/sources.list.d/pgdg.list
RUN wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | \
apt-key add -
# Install PHP extensions deps
RUN apt-get update \
&& apt-get install --no-install-recommends -y \
postgresql-server-dev-9.5 \
libfreetype6-dev \
libjpeg62-turbo-dev \
libmcrypt-dev \
libpng12-dev \
zlib1g-dev \
libicu-dev \
g++ \
unixodbc-dev \
libxml2-dev \
libaio-dev \
libgearman-dev \
libmemcached-dev \
freetds-dev \
libssl-dev \
openssl
# Install Composer
RUN curl -sS https://getcomposer.org/installer | php -- \
--install-dir=/usr/local/bin \
--filename=composer
# Install PHP extensions
RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \
&& docker-php-ext-configure pdo_dblib --with-libdir=/lib/x86_64-linux-gnu \
&& pecl install apcu-4.0.10 \
&& pecl install redis-2.2.8 \
&& pecl install memcached-2.2.0 \
&& pecl install xdebug \
&& docker-php-ext-install \
iconv \
mbstring \
intl \
mcrypt \
gd \
pgsql \
mysqli \
pdo_pgsql \
pdo_mysql \
pdo_dblib \
soap \
sockets \
zip \
pcntl \
ftp \
&& docker-php-ext-enable \
apcu \
memcached \
redis \
opcache \
xdebug
# Install PHPUnit
RUN wget https://phar.phpunit.de/phpunit.phar -O /usr/local/bin/phpunit \
&& chmod +x /usr/local/bin/phpunit
# Clean repository
RUN apt-get clean \
&& rm -rf /var/lib/apt/lists/*