version: '2' services: rabbitmq: image: rabbitmq:latest environment: RABBITMQ_DEFAULT_USER: sapience RABBITMQ_DEFAULT_PASS: tests postgres: image: postgres:latest environment: POSTGRES_USER: sapience POSTGRES_PASSWORD: tests base: image: ruby:2.3 cpu_shares: 4 # Specify the directory from where all commands sent to the container will be # issued to where the code is mounted: working_dir: /usr/src/app # Keep the stdin open, so we can attach to our app container's process # and do things such as byebug, etc: stdin_open: true # Enable sending signals (CTRL+C, CTRL+P + CTRL+Q) into the container: tty: true volumes: # - vendor/bundle:/usr/local/bundle # Mount our app code directory (".") into our app containers at the # "/usr/src/app" folder: - .:/usr/src/app rspec: extends: service: base entrypoint: /usr/src/app/dev-entrypoint.sh command: bundle exec rake depends_on: - rabbitmq environment: CODECLIMATE_REPO_TOKEN: 204dc055302da6aed94379e249aa0645636d1d1794920c62db05c5fa968215de PATH: /usr/src/app/bin:/usr/local/bundle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin rails32: extends: service: base image: ruby:2.1 working_dir: /usr/src/app/test_apps/rails_3_2 entrypoint: /usr/src/app/dev-entrypoint.sh command: bundle exec rspec depends_on: - rabbitmq - postgres environment: APP_NAME: rails_3_2 POSTGRES_HOST: postgres POSTGRES_USER: sapience POSTGRES_PASSWORD: tests AMQP: amqp://sapience:tests@rabbitmq:5672 PATH: /usr/src/app/bin:/usr/local/bundle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin rails42: extends: service: base working_dir: /usr/src/app/test_apps/rails_4_2 entrypoint: /usr/src/app/dev-entrypoint.sh command: bundle exec rspec depends_on: - rabbitmq - postgres environment: APP_NAME: rails_4_2 POSTGRES_HOST: postgres POSTGRES_USER: sapience POSTGRES_PASSWORD: tests AMQP: amqp://sapience:tests@rabbitmq:5672 PATH: /usr/src/app/bin:/usr/local/bundle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin rails50: extends: service: base working_dir: /usr/src/app/test_apps/rails_5_0 entrypoint: /usr/src/app/dev-entrypoint.sh command: bundle exec rspec depends_on: - rabbitmq - postgres environment: APP_NAME: rails_5_0 POSTGRES_HOST: postgres POSTGRES_USER: sapience POSTGRES_PASSWORD: tests AMQP: amqp://sapience:tests@rabbitmq:5672 PATH: /usr/src/app/bin:/usr/local/bundle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin grape: extends: service: base working_dir: /usr/src/app/test_apps/grape entrypoint: /usr/src/app/dev-entrypoint.sh command: bundle exec rspec environment: APP_NAME: grape_app PATH: /usr/src/app/bin:/usr/local/bundle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin sinatra: extends: service: base working_dir: /usr/src/app/test_apps/sinatra entrypoint: /usr/src/app/dev-entrypoint.sh command: bundle exec rspec environment: APP_NAME: sinatra_app PATH: /usr/src/app/bin:/usr/local/bundle/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin