Uploaded image for project: 'Automation Hub'
  1. Automation Hub
  2. AAH-1092

[PoC] Define System Roles

    • Icon: Task Task
    • Resolution: Done
    • Icon: Normal Normal
    • cloud-2022-04-12, 2.3
    • None
    • Backend
    • None
    • False
    • False
    • Hide

      Verify that the roles defined in the system exist in the database after a migration is run and that they are marked as "locked" and have the correct permissions.

      Show
      Verify that the roles defined in the system exist in the database after a migration is run and that they are marked as "locked" and have the correct permissions.
    • ANSTRAT-423 - Direct LDAP connection from Private Hub in App without another VM being required
    • 4.5.0a Sprint 2, 4.5.0a Sprint 3, 4.5.0a Sprint 5, 4.5.0 Sprint 6, 4.5.0 Sprint 7, 4.5.0a Sprint 4

      Pulp plugins can provide a set of default roles out of the box that cannot be changed. These roles are stored in the roles database and are marked as "locked". Traditionally, these are added directly to each viewset using the LOCKED_ROLES attribute, however the galaxy_ng viewsets aren't hooked into the pulp router, so this method can't be used for defining system roles.

      To fix this, we need to:

      • Create a file under galaxy_ng/access_control/ to store our role definitions. This should be similar to how access policies are stored now.
      • Create a post migration hook that loads the role definitions into the database. The post migration hook can be initialized in the same way that we set the pulp container access policies, and should follow the same logic as the populate_roles function

      Role definitions are still TBD, so for now just create a few test roles with arbitrary permissions.

            bmclaugh@redhat.com Brian McLaughlin
            dnewswan David Newswanger
            Christian Torrens Christian Torrens
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: