Skip to content

Commit 9a98c6c

Browse files
authored
initial commit
1 parent 735a5ce commit 9a98c6c

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

Dockerfile

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Pull base image.
2+
FROM ubuntu:xenial
3+
4+
# Install Nginx.
5+
RUN \
6+
add-apt-repository -y ppa:nginx/stable && \
7+
apt-get update && \
8+
apt-get install -y nginx && \
9+
rm -rf /var/lib/apt/lists/* && \
10+
echo "\ndaemon off;" >> /etc/nginx/nginx.conf && \
11+
chown -R www-data:www-data /var/lib/nginx
12+
13+
# Define mountable directories.
14+
VOLUME ["/etc/nginx/sites-enabled", "/etc/nginx/certs", "/etc/nginx/conf.d", "/var/log/nginx", "/var/www/html"]
15+
16+
# Define working directory.
17+
WORKDIR /etc/nginx
18+
19+
# Define default command.
20+
CMD ["nginx"]
21+
22+
# Expose ports.
23+
EXPOSE 80
24+
EXPOSE 443

0 commit comments

Comments
 (0)