From 5787b756fe63fd143f5f900fe09794efea39d2b9 Mon Sep 17 00:00:00 2001 From: itqop Date: Wed, 23 Oct 2024 00:06:16 +0300 Subject: [PATCH] Fix app path --- Dockerfile | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/Dockerfile b/Dockerfile index f0d0904..ac52367 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,25 +9,15 @@ RUN apk update && apk add --no-cache \ openssl-dev \ && rm -rf /var/cache/apk/* -# Установка зависимостей Python -COPY app/requirements.txt /app/requirements.txt -WORKDIR /app +COPY app /app # Установка зависимостей RUN pip install --upgrade pip -RUN pip install --no-cache-dir -r requirements.txt +RUN pip install --no-cache-dir -r app/requirements.txt RUN pip install torch --index-url https://download.pytorch.org/whl/cpu - -# Копирование исходного кода -COPY app /app - -ENV PYTHONPATH=/app # Экспонирование порта EXPOSE 8002 -# Установка Gunicorn -RUN pip install gunicorn - # Команда запуска приложения с использованием Gunicorn и Uvicorn workers CMD ["gunicorn", "main:app", "--worker-class", "uvicorn.workers.UvicornWorker", "--bind", "0.0.0.0:8002", "--workers", "4"]