Spaces:
No application file
No application file
Download dockerfile from imenebenzerga99/web: direct link, hf CLI and curl.
- Browser
- Download file 754 Bytes
-
https://huggingface.co/spaces/imenebenzerga99/web/resolve/main/dockerfile
- Command line
-
hf download hf://spaces/imenebenzerga99/web/dockerfile
-
curl -L -o dockerfile https://huggingface.co/spaces/imenebenzerga99/web/resolve/main/dockerfile
754 Bytes
| # Image de base Python 3.10 (légère et stable) | |
| FROM python:3.10-slim | |
| # Définition du répertoire de travail | |
| WORKDIR /app | |
| # Installation des dépendances système (pour Tesseract, etc.) | |
| RUN apt-get update && apt-get install -y \ | |
| tesseract-ocr \ | |
| libgl1-mesa-glx \ | |
| libglib2.0-0 \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Copie des fichiers de dépendances | |
| COPY requirements.txt . | |
| # Installation des dépendances Python | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| # Copie du code source | |
| COPY main2.py . | |
| # Exposition du port (FastAPI utilise 8000 par défaut) | |
| EXPOSE 8000 | |
| # Commande de démarrage | |
| CMD ["uvicorn", "main2:app", "--host", "0.0.0.0", "--port", "8000","--allow-websocket-origins","web.space.com"] |