Skip to content

Commit 0348335

Browse files
enable and update hydra deployment
1 parent 5f44643 commit 0348335

File tree

4 files changed

+61
-5
lines changed

4 files changed

+61
-5
lines changed

etc/base.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ kratos_ui:
221221
_extra_timeout: 0
222222

223223
hydra:
224-
_install: false
224+
_install: true
225225
_chart_version: 0.41.0
226226
_extra_timeout: 0
227227

etc/hydra/values.yaml

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,36 @@ hydra:
4444
leak_sensitive_values: false
4545

4646
strategies:
47-
access_token: jwt
47+
access_token: jwt
48+
49+
oauth2:
50+
allowed_top_level_claims: scope,roles,authorities,sources,user_name
51+
mirror_top_level_claims: false
52+
53+
serve:
54+
public:
55+
base_url: https://localhost/hydra/
56+
cors:
57+
enabled: true
58+
allowed_origins:
59+
- "*"
60+
allowed_methods:
61+
- POST
62+
- GET
63+
- PUT
64+
- PATCH
65+
- DELETE
66+
allowed_headers:
67+
- Authorization
68+
- Cookie
69+
- Content-Type
70+
- Accept
71+
exposed_headers:
72+
- Content-Type
73+
- Set-Cookie
74+
- Accept
75+
allow_credentials: true
76+
admin:
77+
base_url: https://localhost/admin/hydra/
78+
cors:
79+
enabled: true

etc/kratos/values.yaml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,14 @@ kratos:
196196
use: link
197197
after:
198198
default_browser_return_url: https://localhost/kratos-ui
199+
hooks:
200+
- hook: web_hook
201+
config:
202+
method: POST
203+
url: http://management-portal:8080/managementportal/api/kratos/subjects/activate
204+
body: /etc/config/kratos/webhook_body.jsonnet
205+
response:
206+
ignore: true
199207

200208
logout:
201209
after:
@@ -209,7 +217,14 @@ kratos:
209217
after:
210218
password:
211219
hooks:
212-
- hook: session
220+
- hook: web_hook
221+
config:
222+
method: POST
223+
url: http://management-portal:8080/managementportal/api/kratos/subjects
224+
body: /etc/config/kratos/webhook_body.jsonnet
225+
response:
226+
ignore: true
227+
- hook: session
213228
oidc:
214229
hooks:
215230
- hook: session

helmfile.d/10-services.yaml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,12 @@ releases:
342342
values:
343343
- {{ .Values.server_name }}
344344
- name: kratos.config.oauth2_provider.url
345-
value: http://hydra-admin
345+
value: http://{{ .Values.server_name }}/admin/hydra
346+
- name: kratos.config.selfservice.flows.registration.after.password.hooks[0].config.url
347+
value: https://{{ .Values.server_name }}/managementportal/api/kratos/subjects
348+
- name: kratos.config.selfservice.flows.verification.after.hooks[0].config.url
349+
value: https://{{ .Values.server_name }}/managementportal/api/kratos/subjects/activate
350+
346351

347352
- name: kratos-selfservice-ui-node
348353
chart: radar/kratos-selfservice-ui-node
@@ -378,7 +383,11 @@ releases:
378383
- name: serverName
379384
value: {{ .Values.server_name }}
380385
- name: hydra.config.dsn
381-
value: postgres://{{ .Values.management_portal.postgres.user }}:{{ .Values.management_portal.postgres.password }}@{{ .Values.management_portal.postgres.host }}:{{ .Values.management_portal.postgres.port }}/{{ .Values | get "hydra.jdbc.database" "hydra" }}
386+
value: postgres://{{ .Values.management_portal.postgres.user }}:{{ .Values.management_portal.postgres.password }}@{{ .Values.management_portal.postgres.host }}:{{ .Values.management_portal.postgres.port }}/{{ .Values | get "hydra.jdbc.database" "hydra" }} - name: kratos.config.serve.public.base_url
387+
- name: hydra.config.serve.public.base_url
388+
value: https://{{ .Values.server_name }}/hydra/
389+
- name: hydra.config.serve.admin.base_url
390+
value: https://{{ .Values.server_name }}/admin/hydra/
382391
- name: hydra.config.urls.self.issuer
383392
value: https://{{ .Values.server_name }}/hydra/
384393
- name: hydra.config.urls.login

0 commit comments

Comments
 (0)