feature/apache-sso #12

Merged
vop merged 31 commits from feature/apache-sso into main 2026-07-03 12:13:46 +00:00
Owner

Add optional sso authentication via apache and keycloak

Add optional sso authentication via apache and keycloak
vop added 24 commits 2026-06-25 13:02:29 +00:00
jem requested changes 2026-06-26 12:10:02 +00:00
@ -0,0 +11,4 @@
@init
def initialize(project):
Owner

Wenn wir ein neues buildfile einbauen, dann muss im root dir noch die referenz drauf gesetzt werden.

Sonst funktioniert das übergreifende versionieren nicht.

Wenn wir ein neues buildfile einbauen, dann muss im root dir noch die referenz drauf gesetzt werden. Sonst funktioniert das übergreifende versionieren nicht.
vop marked this conversation as resolved
@ -0,0 +24,4 @@
::apache-sso-crypto-passphrase]
:opt-un []))
(defn-spec replace-all-matching-prefixes map?
Owner

So eine funkton sollte eher nach c4k-common ...
Dort dann gerne mit einem Hauch Doku ...

So eine funkton sollte eher nach c4k-common ... Dort dann gerne mit einem Hauch Doku ...
Author
Owner

Yess, wo würde ich die Doku am besten anlegen?

Yess, wo würde ich die Doku am besten anlegen?
vop marked this conversation as resolved
@ -0,0 +75,4 @@
(->
(ns/load-and-adjust-namespace "apache-sso/secret.yaml" name)
(replace-all-matching-prefixes "NAME" name)
(#(assoc-in % [:stringData :oidc-secret.conf]
Owner

vielleicht ist das auch eine funktion in c4k-common wert ?
Sowas hat mir auch schon öfter gefehlt.

vielleicht ist das auch eine funktion in c4k-common wert ? Sowas hat mir auch schon öfter gefehlt.
Author
Owner

Mir ist beim Implementieren eben aufgefallen, dass es in common modul die funktion replace-map-value die glaube genau das tut. Hab den test mal um diesen case erweitert

Mir ist beim Implementieren eben aufgefallen, dass es in common modul die funktion replace-map-value die glaube genau das tut. Hab den test mal um diesen case erweitert
vop marked this conversation as resolved
@ -0,0 +64,4 @@
(let [{:keys [name]} config]
(->
(ns/load-and-adjust-namespace "apache-sso/deployment.yaml" name)
(assoc-in [:metadata :namespace] name)
Owner

das passiert schon in der zeile drübert :-)

das passiert schon in der zeile drübert :-)
vop marked this conversation as resolved
@ -136,1 +145,4 @@
(cm/replace-all-matching "BASIC_AUTH_NAME" basic-auth-secret)
(cm/replace-all-matching "BASIC_AUTH_USERNAME" (b64/encode basic-auth-user))
(cm/replace-all-matching "BASIC_AUTH_PASSWORD" (b64/encode basic-auth-password)))
[])))
Owner

Im einen Fall eine Map und sonst ein [] ??
Gibt es hier einen Test ?

Im einen Fall eine Map und sonst ein [] ?? Gibt es hier einen Test ?
vop marked this conversation as resolved
@ -214,0 +234,4 @@
name (replace-dots-by-minus unique-name)]
[(generate-build-secret config auth)
(generate-basic-auth-secret config auth)
(if (some? ssoauth)
Owner

if braucht immer das else noch mit dazu, sonst musst du ein when einsetzen. Dürfte so nicht compilieren ....

Schreibst du hier noch einen Test für ?

if braucht immer das else noch mit dazu, sonst musst du ein when einsetzen. Dürfte so nicht compilieren .... Schreibst du hier noch einen Test für ?
vop marked this conversation as resolved
jem requested changes 2026-07-02 14:02:25 +00:00
jem left a comment

nice :-)

nice :-)
@ -187,0 +182,4 @@
[config websiteconfig?]
(let [{:keys [unique-name ssoconf]} config
name (replace-dots-by-minus unique-name)]
(if (some? ssoconf) (str name "-sso") name)))
Owner

let's switch to (contains? config :ssoconf) - not mutch difference but a clean way to go.

let's switch to `(contains? config :ssoconf)` - not mutch difference but a clean way to go.
vop marked this conversation as resolved
@ -206,2 +205,3 @@
:burst-rate burst-rate
:namespace name}))])))
:namespace name}))
(when (some? ssoconf)
Owner

let's switch to (contains? config :ssoconf)

let's switch to `(contains? config :ssoconf)`
vop marked this conversation as resolved
@ -214,0 +213,4 @@
(let [{:keys [unique-name ssoconf]} config
{:keys [ssoauth]} auth
name (replace-dots-by-minus unique-name)]
[(generate-build-secret config auth)
Owner

If we've (when ...) statements in a sequence, when might lead to a nil.

Means the sequence might look like [{the build secret}, nil, ...].
concat-vec has a filter inside, so the nil elements will vanish ...

If we've (when ...) statements in a sequence, when might lead to a nil. Means the sequence might look like `[{the build secret}, nil, ...]`. concat-vec has a filter inside, so the nil elements will vanish ...
vop marked this conversation as resolved
@ -214,0 +214,4 @@
{:keys [ssoauth]} auth
name (replace-dots-by-minus unique-name)]
[(generate-build-secret config auth)
(when (do-basic-auth auth)
Owner

let's switch to (contains? config :....)

let's switch to `(contains? config :....)`
vop marked this conversation as resolved
@ -214,0 +216,4 @@
[(generate-build-secret config auth)
(when (do-basic-auth auth)
(generate-basic-auth-secret config auth))
(when (some? ssoauth)
Owner

let's switch to (contains? config :....) - lets use config as the leading info point.

let's switch to `(contains? config :....)` - lets use config as the leading info point.
vop marked this conversation as resolved
vop changed title from WIP:feature/apache-sso to feature/apache-sso 2026-07-03 12:13:20 +00:00
vop merged commit ef35f5c0ba into main 2026-07-03 12:13:46 +00:00
vop deleted branch feature/apache-sso 2026-07-03 12:13:46 +00:00
vop referenced this pull request from a commit 2026-07-03 12:13:47 +00:00
Sign in to join this conversation.
No reviewers
jem
No labels
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
meissa/c4k-website!12
No description provided.