An example of OpenID Connect implementation on React Admin
This example shows how to support OAuth in a react-admin v4 application.
http://localhost:5173/auth-callback
as the authorized origin and http://localhost:5173/auth-callback
as the authorized redirect URI. Copy the client ID and secret..env.template
files in both the app
and api
directory and update the following variables:VITE_OIDC_CLIENT_ID
: Paste the client ID you copied at step 2OIDC_CLIENT_ID
: Paste the client ID you copied at step 2OIDC_CLIENT_SECRET
: Paste the secret you copied at step 2Run the following command:
make install
Start the API by running:
make run-api
In another terminal, start the application by running:
make run-app