Skip to content

Commit

Permalink
Revise settings for keycloak admin
Browse files Browse the repository at this point in the history
  • Loading branch information
ianmcorvidae committed Dec 12, 2024
1 parent 0109a8b commit 67cc5f4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/terrain/clients/keycloak/admin.clj
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
(defn- keycloak-admin-url
"Builds a Keycloak admin API URL with the given path components."
[& components]
(str (apply curl/url (config/keycloak-admin-base-uri) "realms" (config/keycloak-realm) components)))
(str (apply curl/url (config/keycloak-admin-base-uri) "admin" "realms" (config/keycloak-realm) components)))

(defn- keycloak-admin-token-url
"Like keycloak-admin-url but for the 'master' realm to get a token to use with the API"
[& components]
(str (apply curl/url (config/keycloak-base-uri) "realms" "master" components)))
(str (apply curl/url (config/keycloak-admin-base-uri) "realms" "master" components)))

(defn get-token
"Obtains authorization token data for the admin service account. You'll probably want the access_token field in the return value."
Expand Down
2 changes: 1 addition & 1 deletion src/terrain/util/config.clj
Original file line number Diff line number Diff line change
Expand Up @@ -700,7 +700,7 @@
(cc/defprop-optstr keycloak-admin-base-uri
"The base URI to use for administrative requests to Keycloak."
[props config-valid configs]
"terrain.keycloak.admin-base-uri" "https://keycloaktest2.cyverse.org/auth/admin")
"terrain.keycloak.admin-base-uri" "https://keycloaktest2.cyverse.org/auth")

(declare keycloak-admin-client-id)
(cc/defprop-str keycloak-admin-client-id
Expand Down

0 comments on commit 67cc5f4

Please sign in to comment.