| # Use Ubuntu as the base image | |
| FROM ubuntu:22.04 | |
| # Avoid prompts from apt | |
| ENV DEBIAN_FRONTEND=noninteractive | |
| # Update and install dependencies | |
| RUN apt-get update && apt-get install -y \ | |
| mpv \ | |
| libmpv-dev \ | |
| python3 \ | |
| python3-pip \ | |
| && apt-get clean \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Set the working directory in the container | |
| WORKDIR /app | |
| # Copy the current directory contents into the container at /app | |
| COPY . /app | |
| # Install any needed packages specified in requirements.txt | |
| # Uncomment the following line if you have a requirements.txt file | |
| COPY requirements.txt ./ | |
| RUN pip3 install --no-cache-dir -r requirements.txt | |
| # Make port 80 available to the world outside this container | |
| EXPOSE 7860 | |
| # Run app.py when the container launches | |
| # Replace this with your actual command to run your application | |
| CMD ["python3", "app.py" "--port", "7860"] |