Closed rhjhunt closed 4 years ago
@wenottingham do we want to file a bug in the ansible repo?
Yep, this looks like it might be a bug upstream in Ansible.
@unxfrek is this coming from a customer?
@awithrow9 yes I was working with a customer on this and I was able to reproduce.
@awithrow9 should I open this issue against ansible rather than AWX?
Also as a workaround, would it be viable to edit /var/lib/awx/venv/awx/lib/python2.7/site-packages/awx/plugins/inventory/foreman.py
and change the '250' to the amount in their inventory? (e.g. 1000). That setting would need to be modified on each tower node if they are clustered correct?
@unxfrek, yes can you also open this up in Ansible.
@AlanCoding, @kdelee are we using the foreman plugin? If not, why?
We are not using the foreman inventory plugin because we do not have a satellite6 server for integration testing.
In terms of our readiness to implement it, core merged this so we can use environment vars for credentials, so we're good for that part of the contract. The configuration options do not give any real reason for concern, it'll take some work. Right now, I don't see any parameters that have no equivalent in the plugin and we also allowed users to use in the script.
I can't say anything about the content it returns until I test it.
So regardless, we need this fixed upstream in ansible first before we can pull it into AWX. Do we have any evidence that the upstream foreman plugin fixes this issue? We should probably track this ticket as part of the work whenever we move to support Sat6 via plugins.
Given timing and that this would potentially need to land in Ansible first, I'd say this should be cut cc @wenottingham
The relevant code in the plugin looks pretty much the same.
@wenottingham I vote we kick this out and work on it as part of "Finish up inventory plugins for all sources" later(do we have a ticket for that?)
No ticket yet, but I can concur if we don't have a test nor fix.
@jladdjr if you're not tracking it already this is also something we can attempt to verify once we switch to the plugin
@jladdjr did you have time to look at this?
@blomquisg yep, will take a look 👍
@elyezer @squidboylan @kdelee is this something any of you and yours have bandwidth to test now that we've merged the plugin?
If it doesn't "just work" in the new plugin, we're unlikely to fix it right now.
cc @blomquisg
Yeah I would say we need to check to see if plugin ever got the reports feature ported to it that the script had -- because that was the fix, and then we need to use it.
I have not been able to reproduce. Given the age of this issue, and our move to the inventory plugins, I propose that this be closed and if anyone is able to reproduce with the plugin that they file a bug in https://github.com/theforeman/foreman-ansible-modules/ because now we rely on what is in https://github.com/theforeman/foreman-ansible-modules/blob/master/plugins/inventory/foreman.py
ISSUE TYPE
COMPONENT NAME
SUMMARY
When using Satellite 6 as a dynamic inventory, and with the source varibles set as the following.
Only 250 of my systems out of 1000 will be imported into the inventory. If I don't set the want hostcollections and host_filters all 1000 systems are imported.
ENVIRONMENT
STEPS TO REPRODUCE
Configure Satellite 6 as a dynamic inventory Modify the source variables and add:
EXPECTED RESULTS
All systems are imported
ACTUAL RESULTS
Only 250 systems are imported
ADDITIONAL INFORMATION
I suspect it is from this in the foreman.py, because if I change the number to 1000 all my hosts are imported.