Bug 1621885 - Cannot add Ansible Tower or refresh already added Ansible Tower
Summary: Cannot add Ansible Tower or refresh already added Ansible Tower
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Providers
Version: 5.9.3
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: GA
: 5.10.0
Assignee: Bronagh Sorota
QA Contact: Nandini Chandra
URL:
Whiteboard:
Depends On:
Blocks: 1629129
TreeView+ depends on / blocked
 
Reported: 2018-08-23 19:16 UTC by David Luong
Modified: 2021-12-10 17:07 UTC (History)
8 users (show)

Fixed In Version: 5.10.0.15
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1629129 (view as bug list)
Environment:
Last Closed: 2019-02-12 16:50:10 UTC
Category: Bug
Cloudforms Team: CFME Core
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description David Luong 2018-08-23 19:16:38 UTC
Description of problem:
Cannot add new Ansible Tower or refresh already ansible tower due to credentials without usernames.

Version-Release number of selected component (if applicable):
5.9.3

How reproducible:
Always

Steps to Reproduce:
1.  Have a tower instance with credentials without usernames
2.  Attempt to add Tower provider or refresh Tower provider
3.

Actual results:
Unable to add or refresh

Expected results:
Successful add or refresh

Additional info:

Possible solution would be to change the following line:
https://github.com/ManageIQ/manageiq-providers-ansible_tower/blob/aca6bd12d87b7aa1d6f80952da6161eefc377189/app/models/manageiq/providers/ansible_tower/shared/inventory/parser/automation_manager.rb#L125

To:
inventory_object.userid = credential.username || "<no user>"

Comment 4 David Luong 2018-08-24 14:31:05 UTC
PR addressing this bug: https://github.com/ManageIQ/manageiq-providers-ansible_tower/pull/120

Comment 6 CFME Bot 2018-09-06 16:58:28 UTC
New commit detected on ManageIQ/manageiq-providers-ansible_tower/master:

https://github.com/ManageIQ/manageiq-providers-ansible_tower/commit/161df08159f731edfcee0d86dd82c4f2d1c98fd6
commit 161df08159f731edfcee0d86dd82c4f2d1c98fd6
Merge: 7cf45314a0380f8389cba064cc7300876dbbcc9d 78b08fea5267b44fc6f438b1dc097325f563d9bd
Author:     Adam Grare <agrare>
AuthorDate: Tue Aug 14 15:10:56 2018 -0400
Commit:     Adam Grare <agrare>
CommitDate: Tue Aug 14 15:10:56 2018 -0400

    Deal with ansible not having a username

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1621885

 CHANGELOG.md | 6 +
 app/models/manageiq/providers/ansible_tower/shared/inventory/parser/automation_manager.rb | 2 +-
 2 files changed, 7 insertions(+), 1 deletion(-)

Comment 10 Nandini Chandra 2018-10-03 22:39:25 UTC
Unable to reproduce the issue locally without fix.

Marking the BZ as VERIFIED since the fix resolved the issue for the customer.


Note You need to log in before you can comment on or make changes to this bug.