feat: Phase 4 - SQL AST analyzer, audit rules CRUD, Alembic, Docker (128 tests)
This commit is contained in:
1 parent
e45fbf3586
commit
ff0a330e8a
23 files changed
+1404
-159
No files matched your search
+17
-2
@@ -2,15 +2,30 @@ FROM python:3.11-slim
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Install system deps
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
gcc libmariadb-dev libpq-dev && \
|
||||
gcc libffi-dev && \
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Install Python deps
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
# Copy app
|
||||
COPY . .
|
||||
|
||||
# Default env
|
||||
ENV DATABASE_URL="sqlite+aiosqlite:///./data/sqlite3.db"
|
||||
ENV SECRET_KEY="change-me-in-production"
|
||||
ENV ADMIN_USERNAME="admin"
|
||||
ENV ADMIN_PASSWORD="changeme"
|
||||
ENV ENV="production"
|
||||
ENV DEBUG="false"
|
||||
|
||||
# Create data dir
|
||||
RUN mkdir -p /app/data
|
||||
|
||||
EXPOSE 9000
|
||||
|
||||
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "9000", "--reload"]
|
||||
# Run alembic + uvicorn
|
||||
CMD ["sh", "-c", "alembic upgrade head && python -m uvicorn app.main:app --host 0.0.0.0 --port 9000"]
|
||||
Reference in new issue
Block a user