-
-
Notifications
You must be signed in to change notification settings - Fork 115
Expand file tree
/
Copy pathdocker-compose.oidc-test.yml
More file actions
66 lines (62 loc) · 2.2 KB
/
Copy pathdocker-compose.oidc-test.yml
File metadata and controls
66 lines (62 loc) · 2.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# OIDC integration test harness for issue #114 (Authelia login / null email + CA bundle)
#
# Prerequisites:
# echo "127.0.0.1 authelia.local" | sudo tee -a /etc/hosts
#
# Usage:
# docker compose -f docker-compose.yml -f docker-compose.dev.yml -f docker-compose.oidc-test.yml up -d
# docker compose exec backend alembic upgrade head
#
# Test users (password: reviewpass):
# alice — no email attribute → before the fix: 422; after: logs in, email from ID token
# bob — email bob@example.com → happy path, email from userinfo
#
# Authelia runs over HTTPS with a local CA cert (testing/authelia/ca.pem).
# The CA is mounted into backend/worker as /certs/ca.pem and into frontend
# as NODE_EXTRA_CA_CERTS so NextAuth trusts it. This validates both bugs:
# Bug 1 (null email) and Bug 2 (OIDC_CA_BUNDLE) in a single run.
services:
authelia:
image: authelia/authelia:latest
volumes:
- ./testing/authelia:/config
ports:
- "9091:9091"
extra_hosts:
- "host.docker.internal:host-gateway"
backend:
volumes:
- ./testing/authelia/ca.pem:/certs/ca.pem:ro
environment:
DEBUG: "false"
SECRET_KEY: "review-secret-32charsxxxxxxxxxx"
OIDC_ISSUER_URL: "https://authelia.local:9091"
OIDC_CLIENT_ID: "wardrowbe"
OIDC_CLIENT_SECRET: "review-oidc-secret"
OIDC_CA_BUNDLE: "/certs/ca.pem"
extra_hosts:
- "authelia.local:host-gateway"
worker:
volumes:
- ./testing/authelia/ca.pem:/certs/ca.pem:ro
environment:
DEBUG: "false"
SECRET_KEY: "review-secret-32charsxxxxxxxxxx"
OIDC_ISSUER_URL: "https://authelia.local:9091"
OIDC_CLIENT_ID: "wardrowbe"
OIDC_CLIENT_SECRET: "review-oidc-secret"
OIDC_CA_BUNDLE: "/certs/ca.pem"
extra_hosts:
- "authelia.local:host-gateway"
frontend:
volumes:
- ./testing/authelia/ca.pem:/certs/ca.pem:ro
environment:
NEXTAUTH_URL: "http://localhost:3000"
NEXTAUTH_SECRET: "review-nextauth-secret-xxxxxxxx"
OIDC_ISSUER_URL: "https://authelia.local:9091"
OIDC_CLIENT_ID: "wardrowbe"
OIDC_CLIENT_SECRET: "review-oidc-secret"
NODE_EXTRA_CA_CERTS: "/certs/ca.pem"
extra_hosts:
- "authelia.local:host-gateway"