# Dockerfile for HR Analytics Gradio App FROM python:3.13-slim # Set working directory WORKDIR /app # Install system dependencies RUN apt-get update && apt-get install -y \ build-essential \ && rm -rf /var/lib/apt/lists/* # Copy requirements COPY requirements.txt . # Install Python dependencies RUN pip install --no-cache-dir -r requirements.txt # Copy application files COPY gradio_app.py . COPY model/best_model_RF_SMOTETomek.pkl . COPY model/scaler.pkl . COPY model/label_encoders.pkl . COPY model/target_encoder.pkl . # Expose port EXPOSE 7860 # Set environment variables ENV GRADIO_SERVER_NAME="0.0.0.0" ENV GRADIO_SERVER_PORT=7860 # Run the application CMD ["python", "gradio_app.py"]