From 6df5441cc3da517847dc29ae4c010f15027776f5 Mon Sep 17 00:00:00 2001 From: ejolie Date: Sun, 29 Oct 2023 22:41:59 +0900 Subject: [PATCH] Sync Makefile commands with offbeat --- Makefile | 10 +++++++--- docker-compose.yml | 36 ------------------------------------ 2 files changed, 7 insertions(+), 39 deletions(-) delete mode 100644 docker-compose.yml diff --git a/Makefile b/Makefile index 17aafb2..39b4659 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,8 @@ -.PHONY: run-api -run-api: +.PHONY: build +build: docker build . --force-rm --no-cache --tag birth-tunes-backend - docker run -d -p 8080:8080 --env-file ./.env birth-tunes-backend:latest + docker run -d -p 8081:8080 --env-file ./.env birth-tunes-backend:latest + +.PHONY: down +down: + docker stop $(shell docker ps -q --filter ancestor=birth-tunes-backend:latest) diff --git a/docker-compose.yml b/docker-compose.yml deleted file mode 100644 index 56e9743..0000000 --- a/docker-compose.yml +++ /dev/null @@ -1,36 +0,0 @@ -services: -# api: -# build: . -# command: uvicorn app.main:app --host 0.0.0.0 -# volumes: -# - .:/app -# ports: -# - '8000' -# environment: -# - DATABASE_URL=postgresql://postgres:postgrespwd@db:5432/birth-tunes -# depends_on: -# - postgres - postgres: - container_name: postgres - image: postgres:15-alpine - restart: always - ports: - - '5432:5432' - environment: - - POSTGRES_USER=postgres - - POSTGRES_PASSWORD=postgrespwd - - POSTGRES_DB=birth-tunes - volumes: - - ./data/postgres/:/var/lib/postgresql/data - pgadmin: - container_name: pgadmin - image: dpage/pgadmin4 - restart: always - ports: - - '5050:80' - environment: - - PGADMIN_DEFAULT_EMAIL=pgadmin4@pgadmin.org - - PGADMIN_DEFAULT_PASSWORD=password - # 볼륨 설정 - volumes: - - ./data/pgadmin/:/var/lib/pgadmin