-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
40 lines (28 loc) · 874 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
FROM ruby:1.9.3
RUN apt-get update -qq
RUN apt-get install -y build-essential locales
# for mysql
# RUN apt-get install -y libmysql-dev
RUN apt-get install -y nodejs
# for nokogiri
RUN apt-get install -y libxml2-dev libxslt1-dev
RUN echo "en_US.UTF-8 UTF-8" > /etc/locale.gen
RUN locale-gen
RUN export LANG=en_US.UTF-8
RUN export LC_ALL=en_US.UTF-8
# Set an environment variable where the Rails app is installed to inside of Docker image:
ENV APP_HOME /var/www/blezat
RUN mkdir -p $APP_HOME
# Set working directory, where the commands will be ran:
WORKDIR $APP_HOME
COPY ./blezat/Gemfile Gemfile
COPY ./blezat/Gemfile.lock Gemfile.lock
#ENV BUNDLE_GEMFILE=$APP_HOME/Gemfile
ENV BUNDLE_JOBS=2
ENV BUNDLE_PATH=/usr/local/bundle
RUN gem install bundler
RUN bundle update
# Copy the main application.
COPY ./blezat .
#EXPOSE 3000
#CMD bundle exec rails s -b 0.0.0.0