Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Description of problem:
hammer hostgroup create/update --compute-resource fails to query CR since it uses wrong api call for the query:
GET /api/compute_resources
Params: { "name" => "libvirt" }
This call basically returns all compute resources:
Could not create the hostgroup:
Error: Found more than one compute_resource.
Version-Release number of selected component (if applicable):
6.4.0 (Snap16)
How reproducible:
deterministic
Steps to Reproduce:
1. Have more than 1 CR
# hammer compute-resource list
---|---------------|---------
ID | NAME | PROVIDER
---|---------------|---------
1 | docker | Docker
2 | libvirt | Libvirt
---|---------------|---------
2. Try to create/update a hostgroup querying CR by name
# hammer hostgroup create --name 'libvirt hosts' --compute-resource libvirt
Could not create the hostgroup:
Error: Found more than one compute_resource.
Actual results:
fails to create/update HG when referring CR by name (by id works)
Expected results:
successful HG creation/update when referring CR also by name
When referring to compute profile by name it also uses wrong api call listing all 3 compute profiles:
# hammer hostgroup create --name 'libvirt hosts' --compute-resource-id 2 --compute-profile 1-Small
Could not create the hostgroup:
Error: Found more than one compute_profile.
...
[ INFO 2018-08-09T10:05:47 API] GET /api/compute_profiles
[DEBUG 2018-08-09T10:05:47 API] Params: {
"name" => "1-Small"
}
[DEBUG 2018-08-09T10:05:47 API] Headers: {
:params => {
"name" => "1-Small"
}
}
[DEBUG 2018-08-09T10:05:47 API] Using authenticator: HammerCLIForeman::Api::InteractiveBasicAuth
[DEBUG 2018-08-09T10:05:48 API] Response: {
"total" => 3,
...
With --compute-resource option it can't be regression since the option doesn't exist on 6.3
With --compute-profile option I tested it is broken the same way on 6.3, so no regression too.
Description of problem: hammer hostgroup create/update --compute-resource fails to query CR since it uses wrong api call for the query: GET /api/compute_resources Params: { "name" => "libvirt" } This call basically returns all compute resources: Could not create the hostgroup: Error: Found more than one compute_resource. Version-Release number of selected component (if applicable): 6.4.0 (Snap16) How reproducible: deterministic Steps to Reproduce: 1. Have more than 1 CR # hammer compute-resource list ---|---------------|--------- ID | NAME | PROVIDER ---|---------------|--------- 1 | docker | Docker 2 | libvirt | Libvirt ---|---------------|--------- 2. Try to create/update a hostgroup querying CR by name # hammer hostgroup create --name 'libvirt hosts' --compute-resource libvirt Could not create the hostgroup: Error: Found more than one compute_resource. Actual results: fails to create/update HG when referring CR by name (by id works) Expected results: successful HG creation/update when referring CR also by name