Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/the-teacher/the_role
Authorization for Rails + GUI. Semantic, Flexible, Lightweight
https://github.com/the-teacher/the_role
Last synced: 11 days ago
JSON representation
Authorization for Rails + GUI. Semantic, Flexible, Lightweight
- Host: GitHub
- URL: https://github.com/the-teacher/the_role
- Owner: the-teacher
- Created: 2011-10-29T07:36:07.000Z (about 13 years ago)
- Default Branch: master
- Last Pushed: 2023-10-07T04:11:27.000Z (about 1 year ago)
- Last Synced: 2024-05-12T08:03:20.209Z (6 months ago)
- Language: Ruby
- Homepage:
- Size: 920 KB
- Stars: 771
- Watchers: 32
- Forks: 84
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
TheRole 3.0
Authorization gem for Ruby on Rails
with Management Panel
Semantic. Flexible. Lightweight
Strongly recommended to upgrade from TheRole2 to TheRole3. Please, do it ASAP.
### INTRO
TheRole is an authorization library for Ruby on Rails which restricts what resources a given user is allowed to access. All permissions are defined in with **2-level-hash**, and **stored in the database as a JSON string**.
Using hashes, makes role system extremely easy to configure and use
* Any Role is a two-level hash, consisting of the sections and nested rules
* A Section may be associated with a controller name
* A Rule may be associated with an action name
* A Section can have many rules
* A Rule can be true or false
* Sections and nested Rules provide an ACL (Access Control List)#### Management Panel
http://localhost:3000/admin/roles
**Import/Export operations provided via TheRole Management Panel.** If you have 2 Rails apps, based on TheRole - you can move roles between them via export/import abilities of TheRole Management Panel.
It can be usefull for Rails apps based on one engine.
#### Limitations by Design
TheRole uses few conventions over configuration.
It gives simplicity of code, but also some limitations.
You have to know about them before using of TheRole:
Limitations list
### FAQ
Customization, Rake tasks, code generators
Migration form TheRole 2 to TheRole 3
PSQL: how to use native :json column?
### We need your feedback!
If you have to say something about TheRole, or if you need help, there are few ways to contact us:
0. SKYPE: **ilya.killich**
0. Email: [email protected]
0. TWITTER: [@iam_teacher](https://twitter.com/iam_teacher)
0. Hash tag: [#the_role](https://twitter.com/hashtag/the_role)
0. Google group: [about the_role](https://groups.google.com/forum/#!forum/the_role)
#### Test matrix
* **RAILS:** 3.2.21, 4.0, 4.1, 4.2
* **RUBY:** 1.9.3, 2.0, 2.1, 2.2
* **DB**: sqlite, mysql, postgresqltotally: 48 environments
**Supported locales:**
[the_role_api](https://github.com/TheRole/the_role_api/tree/master/config/locales) |
[the_role_management_panel](https://github.com/TheRole/the_role_management_panel/tree/master/config/locales)
(please, help us with them)
### MIT License
[MIT License](https://github.com/TheRole/docs/blob/master/LICENSE.md)
Copyright (c) 2012-2015 [Ilya N.Zykin](https://github.com/the-teacher)#### Maintainers
[@the-teacher](https://github.com/the-teacher),
[@sedx](https://github.com/sedx),
[@seuros](https://github.com/seuros)#### Contributors
[@igmarin](https://github.com/igmarin)
[@doabit](https://github.com/doabit)
[@linjunpop](https://github.com/linjunpop)
[@egb3](https://github.com/egb3)
[@klacointe](https://github.com/klacointe)
[@niltonvasques](https://github.com/niltonvasques)[Thanks for contributors](https://github.com/the-teacher/the_role/graphs/contributors)