Low commit activity in last 3 years
A long-lived project that still receives updates
Rails engine to do user roles in an RDBMS for hydra-head
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Project Readme

hydra-role-management

Code: Gem Version Build Status Coverage Status

Docs: Contribution Guidelines Apache 2.0 License

Community Support: Samvera Community Slack

What is hydra-role-management?

An engine gem to provide a RDBMS backed list of roles and their associated user. This replaces the hydra default role mapper.

As of version 1.0, this gem only supports Rails 5.

Product Owner & Maintenance

hydra-role-management was a Core Component of the Samvera Community. Given a decline in available labor required for maintenance, this project no longer has a dedicated Product Owner. The documentation for what this means can be found here.

Product Owner

Vacant

Until a Product Owner has been identified, we ask that you please direct all requests for support, bug reports, and general questions to the #dev Channel on the Samvera Slack.

Help

The Samvera community is here to help. Please see our support guide.

Installing:

  • Add: gem 'hydra-role-management' to your Gemfile and then bundle install
  • rails generate roles
  • rake db:migrate
  • Add the following cancan abilities:
  # app/models/ability.rb
  if current_user.admin?
    can [:create, :show, :add_user, :remove_user, :index, :edit, :update, :destroy], Role
  end

Testing:

  • Install a system javascript runtime or uncomment therubyracer in spec/support/Gemfile

  • Ensure that the testing app does not exist: bundle exec rake engine_cart:clean

  • Set Rails version you want to test against. For example:

    • export RAILS_VERSION=5.1.4
  • Ensure that the correct version of Rails is installed: bundle update

  • Build test app: bundle exec rake engine_cart:generate

  • And run tests: bundle exec rake ci

Releasing

  1. bundle install
  2. Increase the version number in lib/hydra/role_management/version.rb
  3. Increase the same version number in .github_changelog_generator
  4. Update CHANGELOG.md by running this command:
github_changelog_generator --user samvera --project hydra-role-management --token YOUR_GITHUB_TOKEN_HERE
  1. Commit these changes to the main branch

  2. Run rake release

Acknowledgments

This software has been developed by and is brought to you by the Samvera community. Learn more at the Samvera website.

Samvera Logo