Destiny

Simple role managment system

Concepts

Developer should be able to check permission of a user to perform an action. Grant is an opportunity to make a particular action with some class of objects. Role is an aggregation of grants. Roles persisted in the database. Any number of roles may be assigned to user.

Installation

Gem

In the command line

gem install destiny-rails

or in your Gemfile

gem 'destiny-rails'

Rails

rails g destiny:install

Assumptions

  1. Your app has a user model called 'User'
  2. App's controller should have (integration purpose only)
    • 'current_user' method returning instance of a user model
    • 'access_denied' method which contains response logic in this case