Modernized and simplified the app.
This wasn't a crazy rewrite or anything, I just updated it to the new YouTube Transcript and OpenAI API's, as well as super simplifying the code. On top of that, it now works single threaded, just using multiple gunicorn threads for concurrency. It's a lot simplier and cleaner, although not up to my current standards.
This commit is contained in:
18
Dockerfile
18
Dockerfile
@@ -1,30 +1,20 @@
|
||||
# Use an official Python runtime as a parent image
|
||||
FROM python:3.13-slim
|
||||
FROM ghcr.io/astral-sh/uv:debian
|
||||
|
||||
# Set environment variables
|
||||
ENV PYTHONDONTWRITEBYTECODE=1
|
||||
ENV PYTHONUNBUFFERED=1
|
||||
|
||||
# Install system dependencies
|
||||
RUN apt-get update && apt-get install -y \
|
||||
build-essential \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Set work directory
|
||||
WORKDIR /app
|
||||
|
||||
# Install Python dependencies
|
||||
COPY requirements.txt .
|
||||
RUN pip install --upgrade pip && pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
# Copy application files
|
||||
COPY /app /app
|
||||
COPY ./app /app
|
||||
# Copy the pyproject.toml and uv.lock because this project's structure is chopped
|
||||
COPY ./pyproject.toml ./uv.lock /app
|
||||
|
||||
# Make start.sh executable
|
||||
RUN chmod +x /app/start.sh
|
||||
|
||||
# Expose the port the app runs on
|
||||
EXPOSE 1986
|
||||
|
||||
# Specify the entrypoint script
|
||||
ENTRYPOINT ["/app/start.sh"]
|
||||
|
||||
Reference in New Issue
Block a user