Files
ansible/roles/awx_create-inventory-from-list/tasks/main.yml
2024-07-12 12:58:40 +02:00

23 lines
679 B
YAML

---
# tasks file for awx_create-inventory-from-list
- name: Add inventory
awx.awx.inventory:
name: "Azure Arc enabled hosts (dynamic)"
description: "Hosts synced from the azure arc prd resource group"
organization: "Aperam"
state: present
controller_host: https://awx-prd.aperam.internal
controller_oauthtoken: "{{oauth}}"
validate_certs: false
- name: add hosts to inventory
awx.awx.host:
inventory: "Azure Arc enabled hosts (dynamic)"
name: "{{item}}"
state: present
controller_host: https://awx-prd.aperam.internal
controller_oauthtoken: "{{oauth}}"
validate_certs: false
enabled: true
with_items: "{{namen}}"