switch to gunicorn

This commit is contained in:
2026-01-24 16:52:12 -05:00
parent d263d73937
commit 3c540e502d
3 changed files with 8 additions and 12 deletions

View File

@@ -1,19 +1,14 @@
# Dockerfile for 'Are We Buried?'
FROM python:3.12-slim
# Set environment
ENV PYTHONUNBUFFERED=1
WORKDIR /app
# Install dependencies
COPY requirements.txt ./
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy application code
COPY . /app
COPY app.py .
COPY templates ./templates
COPY static ./static
# Expose the Flask port
EXPOSE 5000
# Run the Flask app
CMD ["python", "app.py"]
CMD ["gunicorn", "-b", "0.0.0.0:5000", "app:app"]

2
app.py
View File

@@ -189,4 +189,4 @@ def snowfall_api():
if __name__ == "__main__":
app.run(debug=True)
app.run(host="0.0.0.0", port=5000)

View File

@@ -1,2 +1,3 @@
flask
requests
gunicorn