Setup Keycloak for VRS

Setup Keycloak for VRS

Follow the steps below for setting up Keycloak for VRS

  1. Go to FQDN:8088/auth and click on the Administration console

  2. Log in to the administration console using the password set in environment variables (KEYCLOAK_USER and KEYCLOAK_PASSWORD). The default username is admin, and the password is admin

  3. Bring the cursor to the Master  (below the Keycloak logo) and click on the Create realm button 

  1. Enter the Realm name and click on the Create button

  1. Once the Realm is created, click on clients under the created realm, and then click the create client button

  1. Enter Client ID vrs and click on Next.

  1. Toggle the Client authentication and Authorization to ON, click Next, and click Save

  1. Once the client is saved, go to the Credentials tab and copy the client secret. The Client ID (vrs) and Secret will be used in environment variables (KEYCLOAK_CLIENT_ID and KEYCLOAK_CLIENT_SECRET)

  1. Click on Realm Roles in the left panel and create the desired roles, i.e., admin and agent.

  1. Go to Users and create user by entering Username and click Create.

  1. Go to the Credentials tab of the created user and set a password, toggle the Temporary button to OFF, and click Save.

  1. Go to the Roles Mappings tab on the created user details, click on Assign Role, select the desired role, and click on Assign.

image-20260415-125601.png

While role mapping, the default roles should be kept assigned to the user for the purpose of authentication and authorization.

  1. For Admin user only,

    1. Assign the admin role other than the default roles assigned previously.

    2. Now, click on the Assign Role button again, and then select the Filter by clients option in the dropdown.


      image-20260506-104942.png



    3. Open the items per page drop-down and select 50 items per page.


      image-20260506-105102.png



    4. Now type realm in the search box and press Enter or click the Next button.


      image-20260506-105204.png

       

    5. Upon searching, all the realm-management roles will appear; assign all the realm roles to the Admin user.

 

Creation of Keycloak Agent Group for VRS Finesse Gadget

For deployments using the VRS Finesse gadget. The following steps are required as well:

  1. Open the target realm, i.e., VRS.

  2. Navigate to the Groups section in Keycloak.

  3. Click the Create group button.

  4. Create a group named AGENT_GROUP.

  5. Open AGENT_GROUP and navigate to the Role mapping tab.

  6. Assign the realm role agent to this group.

  7. If the agent role does not exist, first create it under Realm roles, then return to AGENT_GROUP and assign it.

  • The group name should be exactly AGENT_GROUP.

  • New users added to this group will inherit the agent role through Keycloak group-to-role mapping.