19.5. Installing and Configuring Red Hat Single Sign-On
To use Red Had Single Sign-On as your authorization method, you need to:
- Install Red Hat SSO.
- Configure the LDAP group mapper.
- Configure Apache on the Manager.
- Configure OVN provider credentials.
If Red Hat SSO is configured, previous LDAP sign ons will not work, as only a single authorization protocol may be used at a time.
19.5.1. Installing Red Hat Single Sign-On Copy linkLink copied to clipboard!
You can install Red Hat Single Sign-On by downloading a ZIP file and unpacking it, or by using an RPM file.
Follow the installation instructions at Red Hat SSO Installation
Prepare the following information:
-
Path/location of the
Open ID Connect
server. - The subscription channel for the correct repositories.
- Valid Red Hat subscription login credentials.
19.5.2. Configuring the LDAP group mapper Copy linkLink copied to clipboard!
Add the LDAP groups mapper with the following information:
-
Name
: ldapgroups -
Mapper Type
: group-ldap-mapper -
LDAP Groups DN
: ou=groups,dc=example,dc=com -
Group Object Classes
: groupofuniquenames (adapt this class according to your LDAP server setup) -
Membership LDAP Attribute
: uniquemember (adapt this class according to your LDAP server setup)
-
-
Click
Save
. -
Click
Sync LDAP Groups to KeyCloak
. -
At the bottom of the
User Federation Provider
page, clickSynchronize all users
. -
In the
Clients
tab, underAdd Client
, addovirt-engine
as theClient ID
, and enter the engine url as theRoot URL
. -
Modify the
Client Protocol
toopenid-connect
and theAccess Type
toconfidential
. -
In the
Clients
tab, underOvirt-engine
>Advanced Settings
, increase theAccess Token Lifespan
. -
Add
https://rhvm.example.com:443/*
as a valid redirect URI. - The client secret is generated, and can be viewed in the Credentials tab.
In the
Clients
tab underCreate Mapper Protocol
, create a mapper with the following settings:-
Name
: groups -
Mapper Type
: Group Membership -
Token Claim Name
: groups -
Full group path
:ON
-
Add to ID token
:ON
-
Add to access token
:ON
-
Add to userinfo
:ON
-
-
Add the
Builtin Protocol Mapper
forusername
. -
Create the scopes needed by
ovirt-engine
,ovirt-app-api
andovirt-app-admin
. - Use the scopes created in the previous step to set up optional client scopes for the ovirt-engine client.
19.5.3. Configuring Apache in the Manager Copy linkLink copied to clipboard!
Configure Apache in the Manager.
yum install mod_auth_openidc
# yum install mod_auth_openidc
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Create a new
httpd
config fileovirt-openidc.conf
in/etc/httpd/conf.d
with the following content:Copy to Clipboard Copied! Toggle word wrap Toggle overflow To save the configuration changes, restart httpd and ovirt-engine:
systemctl restart httpd systemctl restart ovirt-engine
# systemctl restart httpd # systemctl restart ovirt-engine
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Create the file
openidc-authn.properties
in/etc/ovirt-engine/extensions.d/
with the following content:Copy to Clipboard Copied! Toggle word wrap Toggle overflow Create the file
openidc-http-mapping.properties
in/etc/ovirt-engine/extensions.d/
with the following content:Copy to Clipboard Copied! Toggle word wrap Toggle overflow Create the file
openidc-authz.properties
in/etc/ovirt-engine/extensions.d/
with the following content:Copy to Clipboard Copied! Toggle word wrap Toggle overflow Create the file
99-enable-external-auth.conf
in/etc/ovirt-engine/engine.conf.d/
with the following content:Copy to Clipboard Copied! Toggle word wrap Toggle overflow
19.5.4. Configuring OVN Copy linkLink copied to clipboard!
If you configured the ovirt-ovn-provider in the Manager, you need to configure the OVN provider credentials.
Create the file
20-setup-ovirt-provider-ovn.conf
in/etc/ovirt-provider-ovn/conf.d/
with the following content, where user1 belongs to the LDAP group ovirt-administrator, and openidchttp is the profile configured for aaa-ldap-misc.[OVIRT] # ovirt-admin-user-name=user1@openidchttp
[OVIRT] # ovirt-admin-user-name=user1@openidchttp
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Restart the
ovirt-provider-ovn
:systemctl restart ovirt-provider-ovn
# systemctl restart ovirt-provider-ovn
Copy to Clipboard Copied! Toggle word wrap Toggle overflow -
Log in to the Administration Portal, navigate to
, select ovirt-provider-ovn, and click to update the password for the ovn provider.