Skip to content

Instantly share code, notes, and snippets.

@samuelloza
Created March 27, 2020 00:05
Show Gist options
  • Save samuelloza/6cd58a61b663557187935a8a2ef930f4 to your computer and use it in GitHub Desktop.
Save samuelloza/6cd58a61b663557187935a8a2ef930f4 to your computer and use it in GitHub Desktop.
version: '3'
services:
db:
image: postgres:9.6
environment:
POSTGRES_PASSWORD: mysecretpassword
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
web:
build:
context: ./rails/
working_dir: /mnt/rails
env_file: .env
command: bundle exec rails s -p 5000 -b '0.0.0.0'
volumes:
- ./rails:/mnt/rails
ports:
- "80:5000"
links:
- db
depends_on:
- db
volumes:
postgres_data:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment