The data bundle brings no people. Who may sign in is decided by KIMS's Keycloak (the cms-access client role on the environment's CMS client). What a person may do is decided by the CMS's own roles, on its People screen. Everyone needs both.
#Before you start
- deploy/content-load is done.
- The values file had the first Admin's email in
KIMS_BOOTSTRAP_ADMINS(deploy/helm-values). -
https://<CMS_HOST>opens from where people will use it (the internet or KIMS's VPN): deploy/first-deploy. - The CMS client in Keycloak is set up, with the
cms-accessrole (keycloak/client).
#The first Admin
#Step 1: give the first Admin cms-access in Keycloak
In KIMS's Keycloak admin console, in the realm:
- Users > find the first Admin's account > open it.
- Check Email verified is On (the Details tab). The CMS refuses accounts whose email is not verified.
- Role mapping > Assign role.
- Change the filter to Filter by clients, search
cms-access, tick the role on the environment's CMS client. - Assign.
Expected: cms-access listed under the user's role mapping, next to the client's id. Details and group-based alternatives: keycloak/users.
#Step 2: the first Admin signs in
- They open
https://<CMS_HOST>. - The CMS sends them to Keycloak; they sign in with their KIMS account.
- Keycloak sends them back to
https://<CMS_HOST>/api/auth/callback/keycloak.
Because the CMS has nobody yet, KIMS_BOOTSTRAP_ADMINS makes them its first Admin. Expected: the Dashboard, with the loaded content (183 doctors, 72 specialties, 320 conditions, 1,331 treatments), and People in the navigation.
KIMS_BOOTSTRAP_ADMINS is only read while the CMS has no people, so it can stay set.
#Everyone else
#Step 3: add each person on the People screen
The first Admin:
- Opens People.
- Adds each person by their KIMS email (the email on their Keycloak account), with their CMS roles (for example editor, reviewer, Admin).
- Saves.
There are no invitations and no passwords in the CMS. Each person needs both:
| Where | What |
|---|---|
| Keycloak | cms-access on the environment's CMS client, and a verified email |
| CMS People screen | A row with their email and roles |
Plan at least: one more Admin (so access does not depend on one person), editors, and reviewers. A person cannot approve their own change, so reviewers must be different people from the editors whose work they approve.
ClinicSpots staff who work on the content need KIMS Keycloak accounts like anyone else.
#Check
| Check | Expected |
|---|---|
| The first Admin signs in | The Dashboard, with the content |
A KIMS account without cms-access signs in |
The CMS's "no access" page |
Someone with cms-access but not on the People screen |
The "no access" page too (sign-in refuses anyone not on the People screen) |
| Someone added on the People screen signs in | The CMS, with what their roles allow |
| An Admin signs out, then opens the CMS again | Keycloak's sign-in page, not straight back in |
#UAT and production
| UAT | Production | |
|---|---|---|
| Keycloak client | UAT's CMS client: its own cms-access |
Production's CMS client: its own cms-access |
| People list | In UAT's database | In production's database, separate |
| Who | Testers, ClinicSpots, KIMS reviewers | Usually fewer people: the real editors, reviewers and Admins |
| First Admin | KIMS_BOOTSTRAP_ADMINS in UAT's values |
KIMS_BOOTSTRAP_ADMINS in production's values |
Giving cms-access on UAT never gives access to production, and the reverse.
#If it goes wrong
| What you see | Cause | Fix |
|---|---|---|
| Sign-in loops, or "access unavailable" | Issuer URL, client secret, redirect URI, or the CMS cannot reach Keycloak | keycloak/troubleshooting |
| The first Admin gets "no access" | No cms-access, cms-access not in the token (the roles scope), or email not verified |
Step 1; keycloak/client |
| The first Admin is in, but not an Admin | Their email was not in KIMS_BOOTSTRAP_ADMINS (exact spelling), or someone else signed in first |
If someone else became the first Admin, they make the right person an Admin on People |
| Nobody can open People | KIMS_BOOTSTRAP_ADMINS was empty when the first person signed in |
Set it in the values file, update kims-helm-values, rerun kims-platform. If someone is already in cms_users without Admin, ask ClinicSpots: the bootstrap is ignored once anyone is in the table |
| The CMS host does not open | DNS, the ingress or the VPN | deploy/first-deploy |
#Sources
kims-v2/docs/ON-SITE-DEPLOYMENT.md(main, step 7)kims-v2/docs/CONFIG.md(Keycloak)kims-v2/apps/cms/src/lib/auth/config.tskims-v2/apps/cms/src/lib/auth/policy.tskims-deploy-info/kims/09-people.md- https://www.keycloak.org/docs/latest/server_admin/#assigning-role-mappings