Skip to content

Instantly share code, notes, and snippets.

@codekitchen
Created March 13, 2015 00:20
Show Gist options
  • Save codekitchen/01d2bbb84a46b0514b80 to your computer and use it in GitHub Desktop.
Save codekitchen/01d2bbb84a46b0514b80 to your computer and use it in GitHub Desktop.
example of what docker-compose + cloudgate might look like
db:
image: postgres:9.3
expose:
- "5432"
redis:
image: redis:2.8
expose:
- "6379"
web:
build: .
links:
- db
- redis
expose:
- "3000"
command: bundle exec rackup -p 3000
worker:
build: .
links:
- db
- redis
command: bin/canvas_job run
db:
extends:
file: common.yml
service: db
redis:
extends:
file: common.yml
service: redis
web:
extends:
file: common.yml
service: web
volumes:
- .:/app
links:
- db
- redis
environment:
VIRTUAL_HOST: notorious.docker
worker:
extends:
file: common.yml
service: worker
volumes:
- .:/app
web:
extends:
file: common.yml
service: web
links:
- db
- redis
flavor: web
instance_type: m3.large
min_size: 2
max_size: 10
ssl_cert_arn: "arn:aws:iam::..."
health_check_path: '/health_check'
worker:
extends:
file: common.yml
service: worker
links:
- db
- redis
flavor: work
instance_type: m3.large
min_size: 1
max_size: 10
db:
cg_type: rds
db_instance_class: db.m3.large
allocated_storage: 100
redis:
cg_type: elasticache
num_cache_nodes: 1
cache_node_type: cache.r3.large
db:
extends:
file: common.yml
service: db
redis:
extends:
file: common.yml
service: redis
test:
extends:
file: common.yml
service: web
volumes:
- coverage:/app/coverage
environment:
RAILS_ENV: test
command: bundle exec rake
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment