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

fix: docker-compose.deploy.yml 추가, docker db 삭제, frontend Dockerfile … #154

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ celerybeat.pid
*.sage.py

# Environments
db.env
.env
haruProject/.env
.venv
Expand Down
19 changes: 19 additions & 0 deletions docker-compose.deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
version: "3.8"

volumes:
build_folder: null

services:

nginx:
image: movvoo/haru:nginx
build:
context: ./nginx

backend:
image: movvoo/haru:backend
build: ./haruProject

frontend:
image: movvoo/haru:frontend
build: ../frontend
96 changes: 0 additions & 96 deletions docker-compose.prod.yml

This file was deleted.

34 changes: 0 additions & 34 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,6 @@ version: "3.8"

services:

db:
image: mysql:8.0
container_name: mysqldb
ports:
- "3306:3306"
environment:
MYSQL_DATABASE: "haru"
MYSQL_ROOT_PASSWORD: "12345678"

volumes:
- db_data:/var/lib/mysql

# healthcheck:
# test: [ "CMD", "mysql", "-h", "localhost", "-u", "root", "-p${DB_ROOT_PASSWORD}", "-e", "SELECT 1" ]
# timeout: 20s
# retries: 10
networks:
- haru

# 가상 네트워크 연결

frontend: #프론트 엔드 서비스를 만듬
build:
context: ../frontend #프론트 엔드 소스코드는 이 경로에 있다.
Expand Down Expand Up @@ -52,9 +31,6 @@ services:
- build_folder:/var/www/frontend
- ./nginx/logs:/var/log/nginx

# - ./nginx/nginx.conf:/etc/nginx/nginx.conf
# - ./certbot/conf:/etc/letsencrypt:rw
# - ./certbot/www:/var/www/certbot:rw
depends_on:
- frontend
expose:
Expand Down Expand Up @@ -83,17 +59,10 @@ services:

ports:
- "8000:8000"
# volumes:
## - static_volume:/backend/staticfiles
## - media_volume:/backend/mediafiles
# - build_folder:/var/www/frontend
expose:
- "8000"
# networks:
restart: always
tty: true
depends_on:
- db
networks:
- haru

Expand Down Expand Up @@ -121,8 +90,6 @@ services:

celery:
container_name: celery
# env_file:
# - ./settings/.env
command: celery -A config.celery worker --pool=gevent --max-tasks-per-child=1
build:
context: ../backend
Expand Down Expand Up @@ -153,4 +120,3 @@ networks:

volumes:
build_folder: { }
db_data: { }
Loading