More at More Faalis


This guide will get you through Faalis authentication.

After reading this guide, you will know:


  1. Devise
  2. User Model

1 Devise

Devise is one the well known gems for authentication which offers flexible authentication solutions. We use Devise in Faalis, so basically you can do what ever you used to do with Devise in Faalis too. Checkout Devise README and Devise Wiki for more information.

2 User Model

The default user model for Devise inside the Faalis ecosystem is Faalis::User model.

So if you want to make a relation to user you should use Faalis::User. For instance:

class Post < ActiveRecord::Base
  belongs_to :user, class_name: 'Faalis::User'

We don't provides any solution to replace this model, but you can override or extend this model by simply using ruby class_eval method. For example if you want to add extra stuff to this model or override something, just add an initializer script to your config/initializers and do as follow:

Faalis::User.class_eval do
  # ...
  # Do your business here

or even you can load different files in this initializer script and patch Faalis::User model in your thirdparty scripts.


You're encouraged to help improve the quality of this guide.

Please contribute if you see any typos or factual errors. To get started, you can read our documentation contributions section.

You may also find incomplete content, or stuff that is not up to date. Please do add any missing documentation for master. Make sure to check Edge Guides first to verify if the issues are already fixed or not on the master branch. Check the Faalis Guides Guidelines for style and conventions.

If for whatever reason you spot something to fix but cannot patch it yourself, please open an issue.

And last but not least, any kind of discussion regarding Ruby on Rails documentation is very welcome in the rubyonrails-docs mailing list.