pratham0011/QueryMate_Text-to-SQL-CSV
0
1# Use an official Python runtime as a parent image2FROM python:3.123 4# Set the working directory in the container5WORKDIR /app6 7# Copy the current directory contents into the container at /app8COPY . /app9 10# Install system dependencies11RUN apt-get update && apt-get install -y \12 build-essential \13 curl \14 software-properties-common \15 && rm -rf /var/lib/apt/lists/*16 17# Install Python dependencies18RUN pip install --no-cache-dir -r requirements.txt19 20# Make port 7860 available to the world outside this container21EXPOSE 786022 23# Create a script to run both FastAPI and Streamlit24RUN echo '#!/bin/bash\n\25uvicorn main:app --host 0.0.0.0 --port 8000 &\n\26streamlit run streamlit_app.py --server.port 7860 --server.address 0.0.0.0\n\27' > /app/run.sh28 29# Make the script executable30RUN chmod +x /app/run.sh31 32# Run the script when the container launches33CMD ["/app/run.sh"]