Skip to content

Simple example of combining Django + React + Keycloak

License

Notifications You must be signed in to change notification settings

itstar-tech/keycloak-playground

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Django + React + Keycloak Example

This repository shows bare minimum for integrating keycloak with Django and React

Note that this is just an example, source code is not in the best shape

Prerequisites

  • Docker and docker-compose

Running

  • Run docker-compose up

Configuring Keycloak

  • Open localhost:8080
  • Open Administration Console and login with default admin credentials
    • Login: admin Password: admin
  • Open Realm settings (found at bottom left)
  • Set Frontend URL to http://localhost:8080
    • Save
  • Open Clients (found at top left)
  • Click on Create client
  • Put Client ID as react
  • Click Next until you see Root URL option
  • Set Root URL to http://localhost:5173/
  • Click Save
  • Open Clients (found at top left)
  • Click on Create client
  • Put Client ID as backend
  • Click Next until you see Root URL option
  • Set Root URL to http://localhost:8000/
  • Click Save

Adding Registration

  • Open localhost:8080
  • Open Administration Console and login with default admin credentials
  • Open Realm settings (found at bottom left)
  • Click on Login tab
  • Turn on User registration

Now you are ready to open http://localhost:5173 to play with React app

About

Simple example of combining Django + React + Keycloak

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 56.3%
  • JavaScript 35.9%
  • HTML 4.4%
  • Dockerfile 1.7%
  • Makefile 1.7%