main #2

Merged
hitanshu merged 9 commits from hitanshu/Gitea_Event_Bridge:main into main 2026-04-07 21:52:51 +00:00
Showing only changes of commit 2664a0c301 - Show all commits

28
Dockerfile Normal file
View File

@ -0,0 +1,28 @@
FROM python:3.11-slim
# Set working directory
WORKDIR /app
# Set environment variables
ENV PYTHONDONTWRITEBYTECODE=1
ENV PYTHONUNBUFFERED=1
# Install dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Create non-root user
RUN useradd --create-home --shell /bin/bash appuser && \
chown -R appuser:appuser /app
# Copy application files
COPY --chown=appuser:appuser . .
# Switch to non-root user
USER appuser
# Expose port
EXPOSE 5000
# Run with Gunicorn (4 workers)
CMD ["gunicorn", "--bind", "0.0.0.0:5000", "--workers", "4", "--timeout", "120", "app:app"]