- Replace YAML merge keys (<<:) with module_defaults block in main.yml - Simplify connection variables to individual vars instead of dictionary - Remove redundant connection params from individual task files - Document standalone task usage requires play-level module_defaults - Update README examples with new variable pattern
15 lines
350 B
YAML
Executable File
15 lines
350 B
YAML
Executable File
---
|
|
- name: Query Proxmox for existing LXCs
|
|
community.proxmox.proxmox_lxc_info: {}
|
|
register: proxmox_lxcs
|
|
|
|
- name: Check if LXC with hostname already exists
|
|
ansible.builtin.set_fact:
|
|
lxc_exists: >-
|
|
{{
|
|
proxmox_lxcs.proxmox_lxcs
|
|
| selectattr('name', 'equalto', lxc_hostname)
|
|
| list
|
|
| length > 0
|
|
}}
|