generated from madebymode/docker-centos7-php71
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
executable file
·62 lines (52 loc) · 1.41 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
FROM php:8.0-fpm-alpine3.14
# Add Repositories
RUN rm -f /etc/apk/repositories &&\
echo "http://dl-cdn.alpinelinux.org/alpine/v3.14/main" >> /etc/apk/repositories && \
echo "http://dl-cdn.alpinelinux.org/alpine/v3.14/community" >> /etc/apk/repositories
# Add Build Dependencies
RUN apk add --no-cache --virtual .build-deps \
zlib-dev \
libjpeg-turbo-dev \
libpng-dev \
libxml2-dev \
bzip2-dev \
zip
# Add App Dependencies
RUN apk add --update --no-cache \
jpegoptim \
pngquant \
optipng \
vim \
icu-dev \
freetype-dev \
mysql-client \
libzip-dev \
bash \
shared-mime-info \
git \
curl \
wget
# Configure & Install Extension
RUN docker-php-ext-configure gd --with-jpeg=/usr/include/ --with-freetype=/usr/include/ && \
docker-php-ext-install \
bcmath \
bz2 \
gd \
intl \
mysqli \
pcntl \
pdo_mysql \
sockets \
zip
RUN ln -sf "$PHP_INI_DIR/php.ini-development" "$PHP_INI_DIR/conf.d/php.ini"
#composer 1.10
RUN curl -sS https://getcomposer.org/installer | php -- --version=1.10.22 --install-dir=/usr/local/bin --filename=composer
#composer 2
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer2
ENV COMPOSER_ALLOW_SUPERUSER=1
ENV PATH="./vendor/bin:$PATH"
RUN apk update
# Remove Build Dependencies
RUN apk del -f .build-deps
# Setup Working Dir
WORKDIR /app