Last active
September 17, 2019 06:14
-
-
Save channainfo/2622b4a7cb54aab90db7d4b15c48307d to your computer and use it in GitHub Desktop.
docker-compose rails-4.2.1 sidekiq mysql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
db: | |
image: mysql:5.7 | |
environment: | |
MYSQL_ALLOW_EMPTY_PASSWORD: 'yes' | |
volumes: | |
- db:/var/lib/mysql | |
web: | |
build: | |
context: . | |
dockerfile: Dockerfile.dev | |
command: bash -c "rm -f tmp/pids/server.pid && bundle exec rails s -b '0.0.0.0'" | |
volumes: | |
- .:/app | |
- bundle:/usr/local/bundle | |
tmpfs: /app/tmp | |
ports: | |
- "3000:3000" | |
depends_on: | |
- db | |
environment: | |
RAILS_ENV: 'development' | |
REDIS_URL: 'redis://redis:6379/12' | |
redis: | |
image: redis | |
volumes: | |
- redis:/data | |
sidekiq: | |
build: | |
context: . | |
dockerfile: Dockerfile.dev | |
command: bundle exec sidekiq -C config/sidekiq.yml | |
volumes: | |
- '.:/app' | |
- bundle:/usr/local/bundle | |
depends_on: | |
- db | |
- redis | |
environment: | |
RAILS_ENV: 'development' | |
REDIS_URL: 'redis://redis:6379/12' | |
volumes: | |
db: | |
redis: | |
bundle: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment