-
-
Notifications
You must be signed in to change notification settings - Fork 18
/
Dockerfile
23 lines (22 loc) · 1.05 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
FROM lancachenet/ubuntu:latest
MAINTAINER LanCache.Net Team <[email protected]>
ARG DEBIAN_FRONTEND=noninteractive
COPY overlay/ /
RUN apt-get update && \
apt-get install -y nginx-full inotify-tools --no-install-recommends && \
apt-get -y clean && \
rm -rf /var/lib/apt/lists/*
RUN \
chmod 777 /opt/nginx/startnginx.sh && \
rm /etc/nginx/sites-available/default /etc/nginx/sites-enabled/default && \
mkdir -p /etc/nginx/sites-enabled/ && \
mkdir -p /etc/nginx/stream-enabled/ && \
for SITE in /etc/nginx/sites-available/*; do [ -e "$SITE" ] || continue; ln -s $SITE /etc/nginx/sites-enabled/`basename $SITE`; done && \
for SITE in /etc/nginx/stream-available/*; do [ -e "$SITE" ] || continue; ln -s $SITE /etc/nginx/stream-enabled/`basename $SITE`; done && \
mkdir -p /var/www/html && \
chmod 777 /var/www/html /var/lib/nginx && \
chmod -R 777 /var/log/nginx && \
chmod -R 755 /hooks /init && \
chmod 755 /var/www && \
chmod -R 666 /etc/nginx/sites-* /etc/nginx/conf.d/* /etc/nginx/stream.d/* /etc/nginx/stream-*
EXPOSE 80