Flatten packages list to allow condition
This commit is contained in:
parent
2f30ef5954
commit
78b0528362
|
@ -1,3 +1,9 @@
|
||||||
|
## v1.3.1
|
||||||
|
|
||||||
|
### Enhancement
|
||||||
|
|
||||||
|
* Flatten packages list to allow condition.
|
||||||
|
|
||||||
## v1.3.0
|
## v1.3.0
|
||||||
|
|
||||||
### Fix
|
### Fix
|
||||||
|
|
|
@ -17,10 +17,8 @@
|
||||||
# Manage dependent packages [[[1
|
# Manage dependent packages [[[1
|
||||||
- name: Ensure dependent packages are installed
|
- name: Ensure dependent packages are installed
|
||||||
package:
|
package:
|
||||||
name: '{{ item }}'
|
name: '{{ fusioninventory__agent_depend_packages | flatten }}'
|
||||||
state: 'present'
|
state: 'present'
|
||||||
with_flattened:
|
|
||||||
- '{{ fusioninventory__agent_depend_packages | to_nice_json }}'
|
|
||||||
register: pkg_dep_result
|
register: pkg_dep_result
|
||||||
until: pkg_dep_result is success
|
until: pkg_dep_result is success
|
||||||
when: fusioninventory__agent_deploy_state == "present"
|
when: fusioninventory__agent_deploy_state == "present"
|
||||||
|
@ -38,7 +36,7 @@
|
||||||
|
|
||||||
- name: Ensure fusioninventory-agent package from REPOS
|
- name: Ensure fusioninventory-agent package from REPOS
|
||||||
package:
|
package:
|
||||||
name: '{{ fusioninventory__agent_packages }}'
|
name: '{{ fusioninventory__agent_packages | flatten }}'
|
||||||
state: '{{ "present" if (fusioninventory__agent_deploy_state == "present")
|
state: '{{ "present" if (fusioninventory__agent_deploy_state == "present")
|
||||||
else "absent" }}'
|
else "absent" }}'
|
||||||
register: pkg_agent_repo_result
|
register: pkg_agent_repo_result
|
||||||
|
|
Reference in New Issue