Azure and Microsoft Entra ID
RDepot can integrate with any OIDC provider, this example specifically demonstrates how to integrate RDepot with Azure and Microsoft Entra ID.
Configuring Azure
-
Log into the Azure Portal
-
Go to the
App registrations
service -
Click on
New registration
-
Fill in a name for the registration
-
Choose
Accounts in this organizational directory only
. Do not use the other options (not even for testing), unless you are aware of the implications. -
In the
Redirect URI
section, chooseSingle-page application (SPA)
and use the following value (replacingrdepot-demo.local
with your domain name):https://rdepot-demo.local/auth
-
The filled in form should look like:
-
Click
Register
-
Go to
Authentication
-
Provide a front-channel logout URL
https://rdepot-demo.local/logout
-
Check
Access tokens
as the tokens to be issued by the authorization endpoint -
Click
Token configuration
to configure optional claims -
Click
Add optional claim
, selectAccess
as token type, search for theemail
andpreferred_name
claims and check them both -
Go back to the
Overview
page and copy theApplication (client) ID
. You will need this in the RDepot web client configuration. -
Click on
Endpoints
and copy theAuthority URL
-
Click on
OpenID Connect metadata document
and copy thejwks_uri
value. You will need this in the RDepot manager app configuration.
Configuring the RDepot web client
Now that you configured Azure and you retrieved all necessary parameters, you can configure the RDepot web client.
-
Set the following environment variables (replacing the examples with the values you retrieved from the Azure portal):
VITE_OIDC_AUTHORITY=https://login.microsoftonline.com/{your-tenant-id}/v2.0 VITE_OIDC_REDIRECT_URI=https://rdepot.local/auth VITE_OIDC_CLIENT_ID={your-client-id} VITE_OIDC_POST_LOGOUT_REDIRECT_URI=https://rdepot.local/logout VITE_OIDC_RESPONSE_TYPE=code VITE_OIDC_SCOPE=openid profile email {your-client-id}/.default
-
Redeploy the RDepot web client
Configuring the RDepot manager app
-
Using the previously fetched
jwks_uri
, configure theapplication.yaml
as followsoauth2: jwk-set-uri: https://login.microsoftonline.com/common/discovery/v2.0/keys login-field: preferred_username app: authentication: oauth2 oauth2: default: admins: - einstein@company.onmicrosoft.com
-
Redeploy the RDepot manager app
You should now be able to log in on RDepot using an Azure user. You can create additional users by going to the Microsoft Entra ID / Users
page in Azure.