community.network.ce_facts – Gets facts about HUAWEI CloudEngine switches.¶
Note
This plugin is part of the community.network collection (version 1.3.2).
To install it use: ansible-galaxy collection install community.network
.
To use it in a playbook, specify: community.network.ce_facts
.
Synopsis¶
Collects facts from CloudEngine devices running the CloudEngine operating system. Fact collection is supported over Cli transport. This module prepends all of the base network fact keys with
ansible_net_<fact>
. The facts module will always collect a base set of facts from the device and can enable or disable collection of additional facts.
Parameters¶
Notes¶
Note
Recommended connection is
network_cli
.This module also works with
local
connections for legacy playbooks.
Examples¶
# Note: examples below use the following provider dict to handle
# transport and authentication to the node.
- name: CloudEngine facts test
hosts: cloudengine
connection: local
gather_facts: no
vars:
cli:
host: "{{ inventory_hostname }}"
port: "{{ ansible_ssh_port }}"
username: "{{ username }}"
password: "{{ password }}"
transport: cli
tasks:
- name: "Gather_subset is all"
community.network.ce_facts:
gather_subset: all
provider: "{{ cli }}"
- name: "Collect only the config facts"
community.network.ce_facts:
gather_subset: config
provider: "{{ cli }}"
- name: "Do not collect hardware facts"
community.network.ce_facts:
gather_subset: "!hardware"
provider: "{{ cli }}"
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Authors¶
wangdezhuang (@QijunPan)