forked from linuxserver/docker-nginx
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
90 lines (86 loc) · 2.33 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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:3.13
# set version label
ARG BUILD_DATE
ARG VERSION
ARG NGINX_VERSION
LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DATE}"
LABEL maintainer="aptalca"
# environment settings
ENV S6_BEHAVIOUR_IF_STAGE2_FAILS=2
# install packages
RUN \
apk add --no-cache --upgrade \
curl && \
if [ -z ${NGINX_VERSION+x} ]; then \
NGINX_VERSION=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.13/main/x86_64/APKINDEX.tar.gz" | tar -xz -C /tmp \
&& awk '/^P:nginx$/,/V:/' /tmp/APKINDEX | sed -n 2p | sed 's/^V://'); \
fi && \
apk add --no-cache --upgrade \
memcached \
nginx==${NGINX_VERSION} \
nginx-mod-http-brotli==${NGINX_VERSION} \
nginx-mod-http-dav-ext==${NGINX_VERSION} \
nginx-mod-http-echo==${NGINX_VERSION} \
nginx-mod-http-fancyindex==${NGINX_VERSION} \
nginx-mod-http-geoip==${NGINX_VERSION} \
nginx-mod-http-geoip2==${NGINX_VERSION} \
nginx-mod-http-headers-more==${NGINX_VERSION} \
nginx-mod-http-image-filter==${NGINX_VERSION} \
nginx-mod-http-nchan==${NGINX_VERSION} \
nginx-mod-http-perl==${NGINX_VERSION} \
nginx-mod-http-redis2==${NGINX_VERSION} \
nginx-mod-http-set-misc==${NGINX_VERSION} \
nginx-mod-http-upload-progress==${NGINX_VERSION} \
nginx-mod-http-xslt-filter==${NGINX_VERSION} \
nginx-mod-mail==${NGINX_VERSION} \
nginx-mod-rtmp==${NGINX_VERSION} \
nginx-mod-stream==${NGINX_VERSION} \
nginx-mod-stream-geoip==${NGINX_VERSION} \
nginx-mod-stream-geoip2==${NGINX_VERSION} \
nginx-vim==${NGINX_VERSION} \
php7-bcmath \
php7-bz2 \
php7-ctype \
php7-curl \
php7-dom \
php7-exif \
php7-ftp \
php7-gd \
php7-gmp \
php7-iconv \
php7-imap \
php7-intl \
php7-ldap \
php7-mcrypt \
php7-memcached \
php7-mysqli \
php7-mysqlnd \
php7-opcache \
php7-pdo_mysql \
php7-pdo_odbc \
php7-pdo_pgsql \
php7-pdo_sqlite \
php7-pear \
php7-pecl-apcu \
php7-pecl-mailparse \
php7-pecl-redis \
php7-pgsql \
php7-phar \
php7-posix \
php7-soap \
php7-sockets \
php7-sodium \
php7-sqlite3 \
php7-tokenizer \
php7-xml \
php7-xmlreader \
php7-xmlrpc \
php7-xsl \
php7-zip && \
echo "**** configure nginx ****" && \
rm -f /etc/nginx/conf.d/default.conf && \
sed -i \
's|include /config/nginx/site-confs/\*;|include /config/nginx/site-confs/\*;\n\t#Removed lua. Do not remove this comment|g' \
/defaults/nginx.conf
# add local files
COPY root/ /