Files
ocr_performance_lab/Dockerfile
2025-08-12 10:10:59 +09:00

28 lines
753 B
Docker

FROM paddlepaddle/paddle:3.1.0-gpu-cuda11.8-cudnn8.9
# 1. 필수 apt 패키지 설치
RUN apt-get update && \
apt-get install -y \
poppler-utils \
tesseract-ocr \
tesseract-ocr-kor \
libgl1 \
curl \
tree \
git \
build-essential && \
apt-get clean && rm -rf /var/lib/apt/lists/*
# 3. Python 패키지 설치 (이미 설치된 것과 중복 주의)
COPY requirements.txt .
RUN pip install --upgrade pip && \
pip install --no-cache-dir -r requirements.txt && \
pip install --no-cache-dir paddleocr
# 4. 작업 디렉토리 및 소스 복사
WORKDIR /workspace
COPY . .
# 5. 실행 명령
CMD ["sh", "-c", "uvicorn api:app --workers 2 --host 0.0.0.0 --port ${PORT:-8892}"]