-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
53 lines (44 loc) · 1.15 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
FROM alpine:latest
LABEL Maintainer="Anugerah Erlaut <[email protected]>" \
Description="Container based on trafex/alpine-nginx-php7"
# Add User and group, then change directory
RUN addgroup -g 1024 dev && \
adduser -D -u 500 -G dev dev
# Configure nginx
COPY config/nginx.conf /etc/nginx/nginx.conf
# Configure PHP-FPM
COPY config/fpm-pool.conf /etc/php7/php-fpm.d/zz-custom.conf
COPY config/php.ini /etc/php7/conf.d/zz-custom.ini
# Configure supervisord
COPY config/supervisord.conf /etc/supervisor/conf.d/supervisord.conf
# Install packages
RUN apk --no-cache add php7 \
php7-json \
php7-mbstring \
php7-openssl \
php7-pdo_mysql \
php7-pdo_sqlite \
php7-session \
php7-common \
php7-tokenizer \
php7-mcrypt \
php7-fileinfo \
php7-cli \
php7-zip \
php7-fpm \
php7-curl \
php7-xml \
php7-dom \
php7-xmlreader \
php7-ctype \
php7-gd \
php7-opcache \
php7-xdebug \
php7-bcmath\
nginx \
supervisor \
curl
WORKDIR /var/www/html
COPY --chown=root:dev src/ /var/www/html/public/
EXPOSE 80
CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/conf.d/supervisord.conf"]