Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- version: '2'
- services:
- # PostgreSQL database
- db:
- image: postgres:9.4
- hostname: db
- environment:
- - POSTGRES_USER=postgres
- - POSTGRES_PASSWORD=postgres
- - POSTGRES_DB=postgres
- ports:
- - "5432:5432"
- # here my database is on AWS RDS
- # don't know how to link here
- sqs:
- # don't know what to write here
- # not sure if it is require here
- # Django web server
- web:
- build:
- context: .
- dockerfile: Dockerfile
- hostname: web
- command: ./docker-entrypoint.sh
- volumes:
- - .:/app # mount current directory inside container
- ports:
- - "8000:8000"
- # set up links so that web knows about db, rabbit and redis
- links:
- - db
- - redis
- depends_on:
- - db
- # Celery worker
- worker:
- build:
- context: .
- dockerfile: Dockerfile
- command: ./run_celery.sh
- volumes:
- - .:/app
- links:
- - db
- - sqs
- depends_on:
- - sqs
Add Comment
Please, Sign In to add comment