Giter Club home page Giter Club logo

Comments (4)

jcoyne avatar jcoyne commented on June 28, 2024

I can't imagine how this could be a use case with default devise. If they haven't made an account, I wouldn't know how to add them to a role, because they haven't yet been assigned a username/email.

from hydra-role-management.

mbklein avatar mbklein commented on June 28, 2024

We're already doing this in Avalon with OmniAuth + Devise, and we haven't done anything funky to Devise to make it work. Users are identified by a string (username, email address, whatever). The table that links users to roles uses the username string instead of the id field from the user table. That way, we can add users to roles by ID before they exist in the User table. This works because they have a university-assigned User ID, and their User record is initialized with it the first time they successfully log in using institutional authentication.

For example, Alice's Northwestern NetID is abc123 whether our Hydra head knows it yet or not. I should be able to add abc123 to an administrator group before she's in the User table, because I know for certain what her ID will be when she finally gets here. I can't necessarily create the User entry beforehand, though, because it gets initialized with additional LDAP information that I won't have access to until she logs in and it shows up in her OmniAuth session.

from hydra-role-management.

jcoyne avatar jcoyne commented on June 28, 2024

@mbklein That approach sounds like it works pretty well.

from hydra-role-management.

jrgriffiniii avatar jrgriffiniii commented on June 28, 2024

After discussing this with @cjcolvar , it was determined that this was an extremely low priority, and could be closed until it is revisited for a future release.

from hydra-role-management.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.