rails-unicorn.dockerfile 349 B

1234567891011121314
  1. FROM ruby:2.6
  2. RUN apt-get update -yqq && apt-get install -yqq nginx
  3. ADD ./ /rails
  4. WORKDIR /rails
  5. RUN bundle install --jobs=4 --gemfile=/rails/Gemfile --path=/rails/rails/bundle --without=postgresql
  6. EXPOSE 8080
  7. CMD nginx -c /rails/config/nginx.conf && \
  8. DB_HOST=tfb-database bundle exec unicorn_rails -E production_mysql -c config/unicorn.rb