feat: add live-test container for the directory adapter
A test stage in the Dockerfile and an opt-in compose profile run the live directory checks against the test OU inside the image, reading the LDAP_* values from .env. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N3t4WL7bd9bdHHNjEsxzqC
This commit is contained in:
@@ -18,6 +18,12 @@ RUN SECRET_KEY=build-time-only-value-not-used-at-runtime-000000 \
|
||||
LDAP_CA_FILE=/app/README.md LDAP_PUBLISHER_GROUP_DN=build LDAP_ADMIN_GROUP_DN=build \
|
||||
/app/.venv/bin/python manage.py collectstatic --noinput
|
||||
|
||||
# Not part of the runtime image: `docker compose --profile test run --rm live-test`
|
||||
FROM builder AS test
|
||||
RUN uv sync --frozen --no-install-project
|
||||
ENV PATH="/app/.venv/bin:$PATH"
|
||||
CMD ["python", "-m", "pytest", "portal/tests/test_directory_live.py", "-v", "-p", "no:cacheprovider"]
|
||||
|
||||
FROM python:3.13-slim
|
||||
ENV PYTHONUNBUFFERED=1 PYTHONDONTWRITEBYTECODE=1 PATH="/app/.venv/bin:$PATH"
|
||||
RUN apt-get update \
|
||||
|
||||
Reference in New Issue
Block a user