Skip to content

Instantly share code, notes, and snippets.

@shved270189
Last active October 22, 2016 15:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save shved270189/1fd116289d6efb29e97f76c337ad5fb1 to your computer and use it in GitHub Desktop.
Save shved270189/1fd116289d6efb29e97f76c337ad5fb1 to your computer and use it in GitHub Desktop.
default: &default
adapter: postgresql
encoding: unicode
pool: 5
username: postgres
password:
host: db
development:
<<: *default
database: db_development
test:
<<: *default
database: db_test
production:
<<: *default
database: db_production
version: '2'
services:
web:
build: .
command: bundle exec rails s -p 3000 -b '0.0.0.0'
tty: true
stdin_open: true
volumes:
- .:/app
- ~/.ssh:/root/.ssh
volumes_from:
- box
ports:
- "3000:3000"
depends_on:
- db
db:
image: postgres:9.5
box:
image: busybox
volumes:
- /bundle
FROM ruby:2.2.3
RUN apt-get update -qq
RUN apt-get install -y -qq build-essential
RUN apt-get install -y -qq nodejs
RUN apt-get install -y -qq libpq-dev
ENV APP_HOME /app
ENV BUNDLE_PATH /bundle
ENV BUNDLE_JOBS 5
RUN mkdir -p $APP_HOME
WORKDIR $APP_HOME
RUN gem install bundler --no-ri --no-rdoc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment