1+ include :
2+ - docker-compose.oidc.yml
3+
14services :
25 node :
36 image : node:20
@@ -16,123 +19,3 @@ services:
1619 environment :
1720 # Match PHP_MAX_EXECUTION_TIME above
1821 - NGINX_FASTCGI_READ_TIMEOUT=300
19-
20- idp-citizen :
21- image : ghcr.io/soluto/oidc-server-mock:0.8.6
22- profiles :
23- - oidc
24- - test
25- # Let this container be accessible both internally and externally on the same domain.
26- container_name : idp-citizen.${COMPOSE_DOMAIN}
27- networks :
28- - app
29- - frontend
30- ports :
31- # https://github.com/Soluto/oidc-server-mock?tab=readme-ov-file#https
32- # - '80'
33- - " 443"
34- volumes :
35- - .:/tmp/config:ro
36- labels :
37- - " traefik.enable=true"
38- - " traefik.docker.network=frontend"
39- - " traefik.http.routers.${COMPOSE_PROJECT_NAME}_idp-citizen.rule=Host(`idp-citizen.${COMPOSE_DOMAIN}`)"
40- - " traefik.http.services.${COMPOSE_PROJECT_NAME}_idp-citizen.loadbalancer.server.port=443"
41- - " traefik.http.services.${COMPOSE_PROJECT_NAME}_idp-citizen.loadbalancer.server.scheme=https"
42- - " traefik.http.routers.${COMPOSE_PROJECT_NAME}_idp-citizen.middlewares=redirect-to-https"
43- - " traefik.http.middlewares.redirect-to-https.redirectscheme.scheme=https"
44-
45- environment :
46- # https://github.com/Soluto/oidc-server-mock?tab=readme-ov-file#https
47- ASPNETCORE_URLS : https://+:443;http://+:80
48- ASPNETCORE_Kestrel__Certificates__Default__Password : mock
49- ASPNETCORE_Kestrel__Certificates__Default__Path : /tmp/config/.docker/oidc-server-mock/cert/docker.pfx
50-
51- ASPNETCORE_ENVIRONMENT : Development
52- SERVER_OPTIONS_INLINE : |
53- AccessTokenJwtType: JWT
54- Discovery:
55- ShowKeySet: true
56- Authentication:
57- CookieSameSiteMode: Lax
58- CheckSessionCookieSameSiteMode: Lax
59-
60- LOGIN_OPTIONS_INLINE : |
61- {
62- "AllowRememberLogin": false
63- }
64-
65- LOGOUT_OPTIONS_INLINE : |
66- {
67- "AutomaticRedirectAfterSignOut": true
68- }
69-
70- CLIENTS_CONFIGURATION_INLINE : |
71- - ClientId: client-id
72- ClientSecrets: [client-secret]
73- Description: Mock IdP
74- AllowedGrantTypes:
75- # - client_credentials
76- # - implicit
77- - authorization_code
78- # https://github.com/Soluto/oidc-server-mock/issues/46#issuecomment-704963181
79- RequireClientSecret: false
80- AllowAccessTokensViaBrowser: true
81- # https://github.com/Soluto/oidc-server-mock/issues/26#issuecomment-705022941
82- AlwaysIncludeUserClaimsInIdToken: true
83- AllowedScopes:
84- - openid
85- - profile
86- - email
87- ClientClaimsPrefix: ''
88- RedirectUris:
89- - '*'
90- # https://github.com/Soluto/oidc-server-mock/issues/60
91- PostLogoutRedirectUris:
92- - '*'
93- # https://github.com/Soluto/oidc-server-mock/issues/46#issuecomment-704845375
94- RequirePkce: false
95-
96- # Needed to set custom claim types in "profile"
97- # https://github.com/Soluto/oidc-server-mock/issues/123#issuecomment-1427129278
98- # https://github.com/Soluto/oidc-server-mock/blob/master/README.md#simple-configuration
99- # https://docs.docker.com/compose/compose-file/compose-file-v3/#environment
100- OVERRIDE_STANDARD_IDENTITY_RESOURCES : " true"
101- IDENTITY_RESOURCES_INLINE : |
102- # https://auth0.com/docs/get-started/apis/scopes/openid-connect-scopes#standard-claims
103- - Name: openid
104- ClaimTypes:
105- - sub
106- - Name: email
107- ClaimTypes:
108- - email
109- - Name: profile
110- ClaimTypes:
111- # Add your custom claims here
112- - dk_ssn
113- - name
114- - email
115- - zip
116- - uuid
117-
118- USERS_CONFIGURATION_INLINE : |
119- - SubjectId: 1
120- Username: citizen1
121- Password: citizen1
122- Claims:
123- # Claims added here must be defined above in IDENTITY_RESOURCES_INLINE
124- - Type: dk_ssn
125- Value: '1111111111'
126- ValueType: string
127- - Type: name
128- Value: 'Anders And'
129- ValueType: string
130- - Type: email
131- Value: admin@example.com
132- ValueType: string
133- - Type: zip
134- Value: '1111'
135- ValueType: string
136- - Type: uuid
137- Value: '11111111-1111-1111-1111-111111111111'
138- ValueType: string
0 commit comments