Spaces:
Build error
Build error
Download Dockerfile from zeroone229/bot: direct link, hf CLI and curl.
- Browser
- Download file 731 Bytes
-
https://huggingface.co/spaces/zeroone229/bot/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/zeroone229/bot/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/zeroone229/bot/resolve/main/Dockerfile
731 Bytes
| FROM python:3.10-slim | |
| WORKDIR /code | |
| ENV PIP_NO_CACHE_DIR=1 | |
| # Обновляем pip | |
| RUN pip install --upgrade pip | |
| # Копируем список зависимостей | |
| COPY ./requirements.txt /code/requirements.txt | |
| # Сначала принудительно ставим легкий CPU-PyTorch с официального сервера | |
| RUN pip install torch --index-url https://download.pytorch.org/whl/cpu | |
| # Устанавливаем все остальные библиотеки из requirements.txt | |
| RUN pip install -r /code/requirements.txt | |
| # Копируем код нашего бота | |
| COPY . . | |
| # Открываем порт для Hugging Face | |
| EXPOSE 7860 | |
| # Запуск бота | |
| CMD ["python", "app.py"] | |