Blog platform
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

29 lines
840 B

FROM phusion/passenger-ruby26
#Yarn
RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add -
RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list
RUN apt-get update -qq && \
apt-get install -y build-essential libpq-dev sudo tzdata yarn imagemagick
RUN bash -lc 'rvm install ruby-2.6.4'
RUN bash -lc 'rvm --default use ruby-2.6.4'
RUN gem install bundler
RUN sudo -u app mkdir /home/app/pressr
COPY Gemfile Gemfile.lock /home/app/pressr/
WORKDIR /home/app/pressr
ENV RAILS_ENV production
RUN sudo -u app bundle install --deployment
COPY --chown=app:app . /home/app/pressr/
ADD dockerstart.sh /dockerstart.sh
RUN rm -f /etc/service/nginx/down
RUN rm /etc/nginx/sites-enabled/default
ADD webapp.conf /etc/nginx/sites-enabled/webapp.conf
CMD ["/dockerstart.sh"]
EXPOSE 3000