Closed AlexisLessard closed 7 years ago
The groups also exists, as I've made a test in postman and got this result
On Fri, May 12, 2017 at 10:58:52AM -0700, AlexisLessard wrote:
So i've just installed a test installation of foreman. Really basic, nothing fancy. We just wanted to test the ansible plugin to see its viability (so far so good). Now I'm trying out the foreman dynamic inventory. While I can access all my hosts when i write
hosts: all
in my playbook. However, I can't seem to access a host in a simple group. I've got a hostfoo
in the groupansibleManaged
. But I never receive anything whatever I put in thehosts
setting. I've tried:
- foreman_ansibleManaged
- ansibleManaged
- foreman_hostgroups_ansibleManaged
- foreman_hostgroup_ansibleManaged
I always receive
How do I select a simple group? I don't have any environment setup, and I know that I can connect to the foreman server because I can connect to my hosts with the
hosts: all
setting. Any idea on what I'm doing wrong?
Check the generated cache file. It has a list of all the available host groups.
Well, in the cache file, I can certainly see the group name
However, that's not different from what is shown by the api...wait...let me check the .index file...
The name of the group is reduced in minuscules? Ok... let me try that
Aaaaaaaaand it works! Awesome! Thanks for the tip. Altoug I propose to write this in the README file, please.
So i've just installed a test installation of foreman. Really basic, nothing fancy. We just wanted to test the ansible plugin to see its viability (so far so good). Now I'm trying out the foreman dynamic inventory. While I can access all my hosts when i write
hosts: all
in my playbook. However, I can't seem to access a host in a simple group. I've got a hostfoo
in the groupansibleManaged
. But I never receive anything whatever I put in thehosts
setting. I've tried:I always receive
How do I select a simple group? I don't have any environment setup, and I know that I can connect to the foreman server because I can connect to my hosts with the
hosts: all
setting. Any idea on what I'm doing wrong?EDIT: I'm using ansible 2.3