-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dockerfile
46 lines (33 loc) · 984 Bytes
/
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
# DOCKER-VERSION 1.6.0, build 4749651
# habd.as Dockerfile
# Runs Jekyll under Nginx with Passenger
FROM phusion/passenger-ruby27:1.0.10
MAINTAINER Arturo Volpe "[email protected]"
# Set environment variables
ENV HOME /home/deployer
# Set default locale for the environment
ENV LC_ALL C.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US.UTF-8
# Use baseimage-docker's init process
CMD ["/sbin/my_init"]
# Expose Nginx HTTP service
EXPOSE 80
# Start Nginx / Passenger
RUN rm -f /etc/service/nginx/down
# Remove the default site
RUN rm /etc/nginx/sites-enabled/default
# Add the Nginx site and config
COPY nginx.conf /etc/nginx/sites-enabled/webapp.conf
# Install bundle of gems
WORKDIR /tmp
COPY Gemfile /tmp/
COPY Gemfile.lock /tmp/
RUN bundle install
#RUN gem install jekyll --no-rdoc --no-ri -v 4.1.1
# Add the Passenger app
COPY . /home/app/webapp
RUN chown -R app:app /home/app/webapp
# Build the app with Jekyll
WORKDIR /home/app/webapp
RUN bundle exec jekyll build