Project

General

Profile

Bug #12473

Cannot assign "Admin" role for User Groups through hammer cli

Added by Bryan Kearney almost 6 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Category:
Foreman commands (obsolete)
Target version:
Difficulty:
Triaged:
Bugzilla link:
Team Backlog:
Fixed in Releases:
Found in Releases:
In Kanboard:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1281300
Description of problem:
Cannot assign "Admin" role for User Groups through hammer cli on Satellite 6.1.3

Version-Release number of selected component (if applicable):
  1. rpm -qa | grep hammer
    rubygem-hammer_cli_foreman_bootdisk-0.1.2.7-1.el7sat.noarch
    rubygem-hammer_cli_katello-0.0.7.18-1.el7sat.noarch
    rubygem-hammer_cli_foreman_tasks-0.0.3.5-1.el7sat.noarch
    rubygem-hammer_cli_import-0.10.20-1.el7sat.noarch
    rubygem-hammer_cli-0.1.4.13-1.el7sat.noarch
    rubygem-hammer_cli_foreman-0.1.4.14-1.el7sat.noarch
    rubygem-hammer_cli_gutterball-0.0.1.3-1.el7sat.noarch
    rubygem-hammer_cli_foreman_docker-0.0.3.9-1.el7sat.noarch
    rubygem-hammer_cli_foreman_discovery-0.0.1.10-1.el7sat.noarch

How reproducible:
100%

Steps to Reproduce:
1. Try creating a usergroup and assign admin role

  1. hammer> role list
    ---|-----------------------
    ID | NAME
    ---|-----------------------
    1 | Discovery Reader
    2 | Discovery Manager
    3 | Tasks Manager
    4 | Tasks Reader
    5 | Red Hat Access Logs
    6 | Access Insights Viewer
    7 | Access Insights Admin
    8 | Boot disk access
    9 | Manager
    10 | Edit partition tables
    11 | View hosts
    12 | Edit hosts
    13 | Viewer
    14 | Site manager
    15 | Default user
    16 | Anonymous
    ---|-----------------------

hammer> user-group create --help
Usage:
user-group create [OPTIONS]

Options:
--name NAME
--role-ids ROLE_IDS Comma separated list of values.
--roles ROLE_NAMES Comma separated list of values.
--user-group-ids, --usergroup-ids USER_GROUP_IDS Comma separated list of values.
--user-groups, --usergroups USER_GROUP_NAMES Comma separated list of values.
--user-ids USER_IDS Comma separated list of values.
--users USER_LOGINS Comma separated list of values.
-h, --help print help

2. As we can see from the output of the hammer user-group create command there is no option to specify the role as "Admin"

3. This option does exists when creating UserGroups through Satellite webUI

Actual results:
No option to specify an Admin Role to a Usergroup created in Satellite 6.1.3

Expected results:
Admin role can be added to the Usergroup using the hammer command

Additional info:

hammer> user create --help >>>>>>> user creation has an option to specify whether the user is an admin or not.
Usage:
user create [OPTIONS]

Options:
--admin ADMIN is an admin account
One of true/false, yes/no, 1/0.
--auth-source-id AUTH_SOURCE_ID
--default-location-id DEFAULT_LOCATION_ID
--default-organization-id DEFAULT_ORGANIZATION_ID
--firstname FIRSTNAME
--lastname LASTNAME
--location-ids LOCATION_IDS Comma separated list of values.
--locations LOCATION_NAMES Comma separated list of values.
--login LOGIN
--mail MAIL
--organization-ids ORGANIZATION_IDS organization ID
Comma separated list of values.
--organizations ORGANIZATION_NAMES Comma separated list of values.
--password PASSWORD
-h, --help print help


Related issues

Blocked by Foreman - Bug #12488: Missing API documentation for "Admin" user groups parameterClosed2015-11-13

Associated revisions

Revision 27f8cca5 (diff)
Added by Martin Bacovsky about 5 years ago

Refs #12473 - show admin flag in user-group listing

History

#1 Updated by Dominic Cleal almost 6 years ago

  • Subject changed from Cannot assign "Admin" role for User Groups through hammer cli on Satellite 6.1.3 to Cannot assign "Admin" role for User Groups through hammer cli
  • Category set to Foreman commands (obsolete)
  • Assignee deleted (Ohad Levy)

#2 Updated by Dominic Cleal almost 6 years ago

  • Copied to Bug #12488: Missing API documentation for "Admin" user groups parameter added

#3 Updated by Dominic Cleal almost 6 years ago

  • Copied to deleted (Bug #12488: Missing API documentation for "Admin" user groups parameter)

#4 Updated by Dominic Cleal almost 6 years ago

  • Blocked by Bug #12488: Missing API documentation for "Admin" user groups parameter added

#5 Updated by Ivan Necas about 5 years ago

  • Target version set to 1.7.0

#6 Updated by Martin Bacovsky about 5 years ago

  • Status changed from New to Assigned
  • Assignee set to Martin Bacovsky

#7 Updated by The Foreman Bot about 5 years ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/3705 added

#8 Updated by The Foreman Bot about 5 years ago

  • Pull request https://github.com/theforeman/hammer-cli-foreman/pull/252 added

#9 Updated by Dominic Cleal about 5 years ago

  • Pull request deleted (https://github.com/theforeman/foreman/pull/3705)

#10 Updated by Ivan Necas about 5 years ago

  • Target version changed from 1.7.0 to 1.6.1

#11 Updated by Adam Ruzicka about 5 years ago

  • Status changed from Ready For Testing to Closed

Both the current and previously attached PRs are merged, closing.

Also available in: Atom PDF