Project

General

Profile

Actions

Bug #11303

closed

Filter management with hamemr seems to be missing means of associating resource type

Added by Greg Swift over 8 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
API
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

I'm trying to manage creation of roles and their associated permissions. Haven't figured out how. This was as close as I could determine and it doesnt work.

hammer> filter create --role "Content Viewer" --permissions "view_gpg_keys,view_content_views" 
Could not create the permission filter:
  Permissions Permissions must be of same resource type

hammer> filter update --organization-ids 1 --id 76 --role "Content Viewer" --permissions view_products
Could not update the permission filter:
  Permissions Permissions must be of same resource type
  Organization ids You can't assign organizations to this resource

hammer> filter update --organization-ids 1 --id 76 --role "Content Viewer" --permissions view_products -^t^t
--help               --location-ids       --organization-ids   --permission-ids     --role               --search             
--id                 --locations          --organizations      --permissions        --role-id            -h        

Related issues 2 (0 open2 closed)

Related to Hammer CLI - Bug #11441: Hammer does not check whether it get correct number of resources when translating name to id parametersClosedActions
Related to Foreman - Refactor #28591: remove deprecated permissions api parametersClosedTomer BriskerActions
Actions #1

Updated by The Foreman Bot over 8 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/2595 added
  • Pull request deleted ()
Actions #2

Updated by Eric Helms over 8 years ago

After some investigation this appears to be an error with the expectation of hammer when providing a permission name to go and search the API for a permission with the name supplied by the user. However, permissions aren't currently outfitted for scoped search usage and thus all permissions are returned and a filter is attempted to be created with them and thus the error mentioned is generated.

Actions #3

Updated by Eric Helms over 8 years ago

  • Project changed from Katello to Foreman
  • Category deleted (Hammer)
Actions #4

Updated by Marek Hulán over 8 years ago

  • Related to Bug #11441: Hammer does not check whether it get correct number of resources when translating name to id parameters added
Actions #5

Updated by Marek Hulán over 8 years ago

  • Category set to API
  • Assignee set to Eric Helms
  • Bugzilla link set to 1230884
Actions #6

Updated by Dominic Cleal over 8 years ago

  • translation missing: en.field_release set to 63
Actions #7

Updated by Eric Helms over 8 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100
Actions #8

Updated by Tomer Brisker about 4 years ago

  • Related to Refactor #28591: remove deprecated permissions api parameters added
Actions

Also available in: Atom PDF