File size: 388 Bytes
ef2c3c7 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | FROM python:3.11-slim
WORKDIR /app
# Ensure persistent data directory exists
RUN mkdir -p /data && chmod 777 /data
# Declare volume for data persistence across container restarts
VOLUME ["/data"]
# Copy all project files
COPY . .
# Expose default port
EXPOSE 7860
EXPOSE 8080
# Default port for Hugging Face Spaces
ENV PORT=7860
# Start the MAT server
CMD ["python", "server.py"]
|