Skip to content

Commit

Permalink
Merge pull request #20 from CAUSOLDOUTMEN/fix/19-fix-dockerfile
Browse files Browse the repository at this point in the history
fix: 컨테이너가 제대로 실행되도 Dockerfile 재작성 (#19)
  • Loading branch information
synoti21 authored Nov 11, 2023
2 parents ecf5b4a + cb6fd38 commit ba17276
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 6 deletions.
3 changes: 2 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
.gitignore
README.md
README.md
boto.conf.dev
23 changes: 18 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,27 @@
FROM python:3.11.3-slim-buster
FROM amd64/ubuntu:22.04

WORKDIR /app

ENV PYTHONUNBUFFERED=1
ENV DEBIAN_FRONTEND=noninteractive

COPY Pipfile Pipfile.lock /app/

RUN pip install pipenv && \
pipenv install --deploy --ignore-pipfile
COPY Pipfile Pipfile.lock /app/
RUN apt -y update && apt -y upgrade
RUN apt install -y pip && pip install pipenv
RUN apt install software-properties-common -y
RUN add-apt-repository ppa:deadsnakes/ppa && apt -y update
RUN apt install -y python3.11
RUN pipenv --python /usr/bin/python3
RUN pipenv install

COPY . /app/

CMD ["pipenv", "run", "uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]
RUN pipenv run pip install cmake
RUN pipenv run pip install easyocr

EXPOSE 8000


CMD ["pipenv", "run","uvicorn", "main:app", "--reload"]

0 comments on commit ba17276

Please sign in to comment.