Groups
Groups
Sign in
Groups
Groups
Ansible Project
Conversations
About
Send feedback
Help
host patterns doesn't work in group inventory
24 views
Skip to first unread message
Oliver markey
unread,
Mar 25, 2019, 3:51:56 AM
3/25/19
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Ansible Project
I got a predefined group `monitor` with many monitoring parameters that will be used in prometheus/alertmanager/node-exporter.
inventory/hosts
`
[monitor]
10.1.1.1
10.2.2.2
10.3.3.3
`
group_vars/monitor.yml
`
prometheus_version: xxx
prometheus
_port: xxx
`
playbooks/monitor.yml
`
- hosts: monitor
roles:
- {role: prometheus}
`
There was a problem when using dynamic inventory. No hosts were selected when using host patterns in group inventory.
`
[monitor]
us-west:!tags_k8s*:!tags_win*
`
Brian Coca
unread,
Apr 22, 2019, 10:43:21 PM
4/22/19
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Ansible Project
They were never meant to work in inventory, they are used to 'select
FROM inventory' but not to define it.
See group_by and 'constructed' inventory plugin instead.
--
----------
Brian Coca
Reply all
Reply to author
Forward
0 new messages