# Use Alpine-based Python image for a smaller image size FROM python:3.11-alpine # Metadata as described in your project LABEL name="Comet" \ description="Stremio's fastest torrent/debrid search add-on." \ url="https://github.com/g0ldyy/comet" # Set the working directory inside the container WORKDIR /app # Optionally define an environment variable for your database path ARG DATABASE_PATH # Environment variables for Python ENV PYTHONUNBUFFERED=1 \ PYTHONDONTWRITEBYTECODE=1 \ FORCE_COLOR=1 \ TERM=xterm-256color # Install necessary build dependencies RUN apk add --no-cache \ gcc \ musl-dev \ libffi-dev \ make \ python3-dev # Required for building some Python packages # Copy requirements.txt to the working directory COPY requirements.txt ./ # Install dependencies from requirements.txt RUN pip install --no-cache-dir -r requirements.txt # Now copy the rest of your application code to the image COPY . . # Entrypoint to run the application ENTRYPOINT ["python", "-m", "comet.main"]