jeevan0704/sequential-model-for-sequential_dataset
0
1# Use Python 3.11 slim image2FROM python:3.11-slim3 4# Set working directory5WORKDIR /app6 7# Install system dependencies (if any needed for pandas/numpy/cv2)8# RUN apt-get update && apt-get install -y --no-install-recommends \9# build-essential \10# && rm -rf /var/lib/apt/lists/*11 12# Copy requirements file13COPY requirements.txt .14 15# Install Python dependencies16# --no-cache-dir reduces image size17RUN pip install --no-cache-dir -r requirements.txt18 19# Copy application code20COPY . .21 22# Create a non-root user to run the app23RUN useradd -m -u 1000 user24USER user25ENV HOME=/home/user \26 PATH=/home/user/.local/bin:$PATH27 28# Expose port (Hugging Face Spaces uses 7860)29EXPOSE 786030 31# Set environment variables32ENV FLASK_APP=app.py33ENV PORT=786034 35# Command to run the application36# Using python directly is fine for this demo, but gunicorn is better for prod37# CMD ["gunicorn", "-b", "0.0.0.0:7860", "app:app"]38CMD ["python", "app.py"]39 