diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 000000000..523c0f405 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,15 @@ +# 최신 Python 이미지 사용 +FROM python:3.12.1-slim + +# 작업 디렉토리 설정 +WORKDIR /app + +# 의존성 파일 복사 및 설치 +COPY requirements.txt . +RUN pip install --no-cache-dir -r requirements.txt + +# 나머지 파일 복사 +COPY . . + +# FastAPI 실행 명령 +CMD ["uvicorn", "main:app", "--reload","--host", "0.0.0.0", "--port", "8000"] \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 000000000..0057f72f5 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,8 @@ +version: '3.8' +services: + web: + build: . + volumes: + - .:/app + ports: + - "8000:8000" \ No newline at end of file