20 lines
553 B
Plaintext
20 lines
553 B
Plaintext
FROM python:3.12-slim
|
|
|
|
WORKDIR /app
|
|
|
|
# 타임존 설정 (로그에 한국 시간이 찍히도록 함)
|
|
ENV TZ=Asia/Seoul
|
|
RUN apt-get update && apt-get install -y tzdata && \
|
|
ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
|
|
|
|
COPY requirements.txt .
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
# 현재 디렉토리의 모든 파일(app.py, utils.py 등)을 복사
|
|
COPY . .
|
|
|
|
# 로그가 즉시 출력되도록 설정
|
|
ENV PYTHONUNBUFFERED=1
|
|
|
|
EXPOSE 8000
|
|
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "8000"] |