BREAKING CHANGE: Major architecture overhaul removing LaTeX compilation - Removed embedded LaTeX compilation - Added OIDC/OAuth2 authentication with Nextcloud integration - Added email authentication with magic links - Implemented role-based access control (RBAC) - Added PDF template upload and field mapping - Implemented visual form designer capability - Created multi-stage approval workflow - Added voting mechanism for AStA members - Enhanced user dashboard with application tracking - Added comprehensive audit trail and history - Improved security with JWT tokens and encryption New Features: - OIDC single sign-on with automatic role mapping - Dual authentication (OIDC + Email) - Upload fillable PDFs as templates - Graphical field mapping interface - Configurable workflow with reviews and voting - Admin panel for role and permission management - Email notifications for status updates - Docker compose setup with Redis and MailHog Migration Required: - Database schema updates via Alembic - Configuration of OIDC provider - Upload of PDF templates to replace LaTeX - Role mapping configuration
62 lines
1.3 KiB
Docker
62 lines
1.3 KiB
Docker
FROM python:3.11-slim
|
|
|
|
# Set working directory
|
|
WORKDIR /app
|
|
|
|
# Install system dependencies
|
|
RUN apt-get update && apt-get install -y \
|
|
gcc \
|
|
libmariadb-dev \
|
|
pkg-config \
|
|
wget \
|
|
curl \
|
|
# PDF processing tools
|
|
poppler-utils \
|
|
# Clean up
|
|
&& apt-get clean \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# Copy requirements first for better caching
|
|
COPY requirements.txt .
|
|
|
|
# Install Python dependencies
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
# Install additional PDF processing libraries
|
|
RUN pip install --no-cache-dir \
|
|
PyMuPDF \
|
|
pypdf \
|
|
pillow \
|
|
python-multipart \
|
|
httpx \
|
|
redis \
|
|
python-jose[cryptography] \
|
|
passlib \
|
|
bcrypt \
|
|
emails \
|
|
jinja2
|
|
|
|
# Copy application code
|
|
COPY src/ ./src/
|
|
COPY assets/ ./assets/
|
|
|
|
# Create necessary directories
|
|
RUN mkdir -p /app/uploads \
|
|
/app/templates \
|
|
/app/attachments \
|
|
/app/pdf_forms \
|
|
/app/logs
|
|
|
|
# Set permissions
|
|
RUN chmod -R 755 /app
|
|
|
|
# Health check
|
|
HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
|
|
CMD python -c "import urllib.request; urllib.request.urlopen('http://localhost:8000/health')" || exit 1
|
|
|
|
# Expose port
|
|
EXPOSE 8000
|
|
|
|
# Run the application
|
|
CMD ["uvicorn", "src.main:app", "--host", "0.0.0.0", "--port", "8000", "--reload"]
|