File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change 11#!usr/bin/env python3
22
33from ansible .errors import AnsibleFilterError
4- # from ansible.plugins.filter.core imprt FilterModule
54
65class FilterModule (object ):
76 def filters (self ):
Original file line number Diff line number Diff line change 11---
2+ - name : Get facts for control host
3+ hosts : localhost
4+ gather_facts : true
5+ tasks :
6+ - name : Check if kolla_neutron_ml2_mechanism_drivers is defined
7+ ansible.builtin.set_fact :
8+ kolla_neutron_ml2_mechanism_drivers_defined : " {{ kolla_neutron_ml2_mechanism_drivers is defined }}"
9+ - name : Check if ngs enabled
10+ ansible.builtin.set_fact :
11+ ngs_enabled : >-
12+ {{ 'genericswitch' in kolla_neutron_ml2_mechanism_drivers }}
13+ when : kolla_neutron_ml2_mechanism_drivers_defined
214- name : Can the control host reach the internet?
315 hosts : localhost
416 gather_facts : true
7991 wazuh_enabled : " {{ groups['wazuh-agent'] | length > 0 | bool }}"
8092 # ngs_enabled_: "{{ 'genericswitch' in (kolla_neutron_ml2_mechanism_drivers | default([])) | bool }}"
8193 # # ABOVE LEADS TO ERROR: argument of type ''NoneType'' is not iterable. argument of type ''NoneType'' is not iterable'
94+ ngs_enabled : " {{ ngs_enabled | default(false) }}"
8295 kayobe_managed_switches : " {{ groups['switches'] | length > 0 | bool }}"
8396 proxy_configured : " {{ http_proxy | bool or https_proxy | bool }}"
8497 bifrost_version : " {{ kolla_bifrost_source_version }}"
You can’t perform that action at this time.
0 commit comments