Skip to content

Latest commit

 

History

History
90 lines (51 loc) · 1.9 KB

README.md

File metadata and controls

90 lines (51 loc) · 1.9 KB

Gem Keycloak - example

Versions

  • ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-linux]
  • Rails 5.1.6
  • gem 'keycloak', '~> 2.3', '>= 2.3.2'

Description

This is a simple example of how to build an application using gem Keycloak and using the views from your own application.

Step by Step

1. Clone this project

2. Create a new realm:

Alt text

3. Configure a email to send then "forgot password" email:

Alt text

4. Create a new client in the realm:

Alt text

5. Create a new role in the client:

Alt text

6. Export installation.json file and paste in application folder. The gem will get client information at this file.:

Alt text

7. Install application gems:

$ bundle

8. Create database:

$ rails db:create
$ rails db:migrate

9. Start application:

$ rails s

10. Access application

Alt text

11. Create a new user:

Alt text Alt text

12. See the new user in Keycloak:

Alt text

13. Sign In and access the main screen:

Alt text

14. Click in "Logout":

Alt text

15. Click in "Logout":

Alt text

16. Click in "I forgot my password":

Alt text

17. See your email:

Alt text

In docs folder there are the realm file exported and all images of this documentation.