FROM python:3.10 # Αποφυγή permission προβλημάτων ENV HF_HOME=/app/hf_cache WORKDIR /app COPY requirements.txt . RUN pip install --no-cache-dir -r requirements.txt # Προφόρτωση μοντέλου για να αποφύγουμε lock files RUN python -c "from transformers import AutoTokenizer, AutoModelForSeq2SeqLM; \ m='kriton/greek-text-summarization'; \ AutoTokenizer.from_pretrained(m, cache_dir='/app/hf_cache'); \ AutoModelForSeq2SeqLM.from_pretrained(m, cache_dir='/app/hf_cache')" COPY . . CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]