Skip to content

Commit

Permalink
Fix case sensitivity and wait a bit longer
Browse files Browse the repository at this point in the history
Signed-off-by: John Gomersall <thegoms@gmail.com>
  • Loading branch information
john-gom committed Dec 20, 2024
1 parent cb04d6e commit cf8e2ef
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions runtime-scripts/after_startup.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
function wait_for_keycloak() {
local -r MAX_WAIT=60
local -r MAX_WAIT=120
local config_command
local wait_time

Expand Down Expand Up @@ -91,8 +91,8 @@ do
"$CLIENT_SECRET" \
> /etc/off/interpolated_client_$CLIENT_ID.json
/opt/keycloak/bin/kcadm.sh create clients -r open-products-facts -f /etc/off/interpolated_client_$CLIENT_ID.json
# Can't import client role mappings with the user
/opt/keycloak/bin/kcadm.sh add-roles -r open-products-facts --uusername service-account-$CLIENT_ID --cclientid realm-management --rolename manage-users --rolename query-users
# Can't import client role mappings with the user. Note generated user name is always in lower case
/opt/keycloak/bin/kcadm.sh add-roles -r open-products-facts --uusername service-account-${CLIENT_ID,,} --cclientid realm-management --rolename manage-users --rolename query-users
fi
done

Expand Down

0 comments on commit cf8e2ef

Please sign in to comment.