Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: run everything in docker-compose #476

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 47 additions & 13 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,47 @@
db:
image: mysql:latest
ports:
- "3306:3306"
environment:
MYSQL_ROOT_PASSWORD: password
MYSQL_USER: rdoc
MYSQL_PASSWORD: password
MYSQL_DATABASE: rdocs
redis:
image: redis
ports:
- "6379:6379"
version: '3.7'
services:
rdocs-app:
container_name: rdocs-app
build:
context: .
dockerfile: ./Dockerfile
restart: always
ports:
- '3000:3000'
env_file:
- .env
environment:
- DATABASE_HOST=mysql-db
- DATABASE_USERNAME=root
- DATABASE_PASSWORD=password
- DATABASE_NAME=rdocs
- DATABASE_PORT=3306
- REDIS_URL=redis://redis:6379
depends_on:
- db
- redis
networks:
- gateway
db:
container_name: mysql-db
image: mysql:latest
command: --default-authentication-plugin=mysql_native_password
restart: always
ports:
- "3308:3306"
environment:
- MYSQL_ROOT_PASSWORD=password
- MYSQL_USER=rdoc
- MYSQL_PASSWORD=password
- MYSQL_DATABASE=rdocs
networks:
- gateway
redis:
container_name: redis
image: redis
ports:
- "6379:6379"
networks:
- gateway
networks:
gateway: {}