fix(keycloak): look up admin-permissions over the API, fix the bootstrap runbook #917

Sammanfogat
supernaut sammanfogade 1 incheckning från fix/keycloak-admin-permissions-lookup in i main 2026-11-29 20:20:55 +00:00
Ägare

Follow-up to #915, from the 2026-11-29 prod upgrade to Keycloak 26.8.2.

  • opentofu/keycloak: the full realm plan failed with 403 on data.keycloak_openid_client.admin_permissions, which also reads the client secret. It now looks the client up over the admin API, the same way as realm-management. The id is the same, so no resource changes.
  • Runbook, bootstrap and break-glass commands: use the isolated values (bitborg-id, uid 2001, bitborg-id-data, keycloak-postgres) and pass --optimized. Without it, bootstrap-admin rebuilds the server without the image's build options and fails on the database URL.
  • Runbook, 26.8.1 to 26.8.2: list each client's default scopes before the plan, because the new resources show as creates and cannot reveal a removed scope. Note that the plan may also narrow opentofu (#826). Record what happened on prod.

After merge, a full realm plan as opentofu should be empty.

Refs bitborg/bitborg-keycloak#33

Follow-up to #915, from the 2026-11-29 prod upgrade to Keycloak 26.8.2. - `opentofu/keycloak`: the full realm plan failed with 403 on `data.keycloak_openid_client.admin_permissions`, which also reads the client secret. It now looks the client up over the admin API, the same way as `realm-management`. The id is the same, so no resource changes. - Runbook, bootstrap and break-glass commands: use the isolated values (`bitborg-id`, uid 2001, `bitborg-id-data`, `keycloak-postgres`) and pass `--optimized`. Without it, `bootstrap-admin` rebuilds the server without the image's build options and fails on the database URL. - Runbook, 26.8.1 to 26.8.2: list each client's default scopes before the plan, because the new resources show as creates and cannot reveal a removed scope. Note that the plan may also narrow `opentofu` (#826). Record what happened on prod. After merge, a full realm plan as `opentofu` should be empty. Refs bitborg/bitborg-keycloak#33
supernaut lade till 1 incheckning 2026-11-29 19:58:08 +00:00
fix(keycloak): look up admin-permissions over the API, fix the bootstrap runbook
Alla kontroller lyckades
ci / ci (pull_request) Successful in 22m13s
b1f0cd5e74
supernaut schemalade den här ändringsförfrågan för automatisk sammanfogning när alla kontroller lyckas 2026-11-29 20:00:24 +00:00
supernaut sammanfogade incheckning 6014b972e8 till main 2026-11-29 20:20:55 +00:00
supernaut tog bort grenen fix/keycloak-admin-permissions-lookup 2026-11-29 20:20:55 +00:00
Logga in för att delta i denna konversation.
Inga granskare
Ingen milstolpe
Inget projekt
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Förfallodatumet är ogiltigt eller utanför gränserna. Använd formatet "åååå-mm-dd".

Inget förfallodatum satt.

Beroenden

Inga beroenden satta

Referens
bitborg/bitborg-infra!917
Ingen beskrivning angiven.