| 1 |
.. _ome_template_network_vlan_info_module: |
| 2 |
|
| 3 |
|
| 4 |
ome_template_network_vlan_info -- Retrieves network configuration of template. |
| 5 |
============================================================================== |
| 6 |
|
| 7 |
.. contents:: |
| 8 |
:local: |
| 9 |
:depth: 1 |
| 10 |
|
| 11 |
|
| 12 |
Synopsis |
| 13 |
-------- |
| 14 |
|
| 15 |
This module retrieves the network configuration of a template on OpenManage Enterprise or OpenManage Enterprise Modular. |
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
Requirements |
| 20 |
------------ |
| 21 |
The below requirements are needed on the host that executes this module. |
| 22 |
|
| 23 |
- python \>= 3.9.6 |
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
Parameters |
| 28 |
---------- |
| 29 |
|
| 30 |
template_id (optional, int, None) |
| 31 |
Id of the template. |
| 32 |
|
| 33 |
This is mutually exclusive with \ :emphasis:`template\_name`\ . |
| 34 |
|
| 35 |
|
| 36 |
template_name (optional, str, None) |
| 37 |
Name of the template. |
| 38 |
|
| 39 |
This is mutually exclusive with \ :emphasis:`template\_id`\ . |
| 40 |
|
| 41 |
\ :literal:`Note`\ If \ :emphasis:`template\_id`\ or \ :emphasis:`template\_name`\ option is not provided, the module retrieves network VLAN info of all templates. |
| 42 |
|
| 43 |
|
| 44 |
hostname (True, str, None) |
| 45 |
OpenManage Enterprise or OpenManage Enterprise Modular IP address or hostname. |
| 46 |
|
| 47 |
|
| 48 |
username (False, str, None) |
| 49 |
OpenManage Enterprise or OpenManage Enterprise Modular username. |
| 50 |
|
| 51 |
If the username is not provided, then the environment variable \ :envvar:`OME\_USERNAME`\ is used. |
| 52 |
|
| 53 |
Example: export OME\_USERNAME=username |
| 54 |
|
| 55 |
|
| 56 |
password (False, str, None) |
| 57 |
OpenManage Enterprise or OpenManage Enterprise Modular password. |
| 58 |
|
| 59 |
If the password is not provided, then the environment variable \ :envvar:`OME\_PASSWORD`\ is used. |
| 60 |
|
| 61 |
Example: export OME\_PASSWORD=password |
| 62 |
|
| 63 |
|
| 64 |
x_auth_token (False, str, None) |
| 65 |
Authentication token. |
| 66 |
|
| 67 |
If the x\_auth\_token is not provided, then the environment variable \ :envvar:`OME\_X\_AUTH\_TOKEN`\ is used. |
| 68 |
|
| 69 |
Example: export OME\_X\_AUTH\_TOKEN=x\_auth\_token |
| 70 |
|
| 71 |
|
| 72 |
port (optional, int, 443) |
| 73 |
OpenManage Enterprise or OpenManage Enterprise Modular HTTPS port. |
| 74 |
|
| 75 |
|
| 76 |
validate_certs (optional, bool, True) |
| 77 |
If \ :literal:`false`\ , the SSL certificates will not be validated. |
| 78 |
|
| 79 |
Configure \ :literal:`false`\ only on personally controlled sites where self-signed certificates are used. |
| 80 |
|
| 81 |
Prior to collection version \ :literal:`5.0.0`\ , the \ :emphasis:`validate\_certs`\ is \ :literal:`false`\ by default. |
| 82 |
|
| 83 |
|
| 84 |
ca_path (optional, path, None) |
| 85 |
The Privacy Enhanced Mail (PEM) file that contains a CA certificate to be used for the validation. |
| 86 |
|
| 87 |
|
| 88 |
timeout (optional, int, 30) |
| 89 |
The socket level timeout in seconds. |
| 90 |
|
| 91 |
|
| 92 |
|
| 93 |
|
| 94 |
|
| 95 |
Notes |
| 96 |
----- |
| 97 |
|
| 98 |
.. note:: |
| 99 |
- Run this module on a system that has direct access to Dell OpenManage Enterprise. |
| 100 |
- This module supports \ :literal:`check\_mode`\ . |
| 101 |
|
| 102 |
|
| 103 |
|
| 104 |
|
| 105 |
Examples |
| 106 |
-------- |
| 107 |
|
| 108 |
.. code-block:: yaml+jinja |
| 109 |
|
| 110 |
|
| 111 |
--- |
| 112 |
- name: Retrieve network details of all templates. |
| 113 |
dellemc.openmanage.ome_template_network_vlan_info: |
| 114 |
hostname: "192.168.0.1" |
| 115 |
username: "username" |
| 116 |
password: "password" |
| 117 |
ca_path: "/path/to/ca_cert.pem" |
| 118 |
|
| 119 |
- name: Retrieve network details using template ID |
| 120 |
dellemc.openmanage.ome_template_network_vlan_info: |
| 121 |
hostname: "192.168.0.1" |
| 122 |
username: "username" |
| 123 |
password: "password" |
| 124 |
ca_path: "/path/to/ca_cert.pem" |
| 125 |
template_id: 1234 |
| 126 |
|
| 127 |
- name: Retrieve network details using template name |
| 128 |
dellemc.openmanage.ome_template_network_vlan_info: |
| 129 |
hostname: "192.168.0.1" |
| 130 |
username: "username" |
| 131 |
password: "password" |
| 132 |
ca_path: "/path/to/ca_cert.pem" |
| 133 |
template_name: template1 |
| 134 |
|
| 135 |
|
| 136 |
|
| 137 |
Return Values |
| 138 |
------------- |
| 139 |
|
| 140 |
msg (always, str, Successfully retrieved the template network VLAN information.) |
| 141 |
Status of template VLAN information retrieval. |
| 142 |
|
| 143 |
|
| 144 |
vlan_info (success, list, [{'TemplateId': 58, 'TemplateName': 't2', 'NicBondingTechnology': 'LACP', 'NicModel': {'NIC in Mezzanine 1B': {'1': {'Port': 1, 'Vlan Tagged': ['25367', '32656', '32658', '26898'], 'Vlan UnTagged': '21474', 'NICBondingEnabled': 'false'}, '2': {'Port': 2, 'Vlan Tagged': [], 'Vlan UnTagged': '32658', 'NIC Bonding Enabled': 'true'}}, 'NIC in Mezzanine 1A': {'1': {'Port': 1, 'Vlan Tagged': ['32656', '32658'], 'Vlan UnTagged': '25367', 'NIC Bonding Enabled': 'true'}, '2': {'Port': 2, 'Vlan Tagged': ['21474'], 'Vlan UnTagged': '32656', 'NIC Bonding Enabled': 'false'}}}}]) |
| 145 |
Information about the template network VLAN. |
| 146 |
|
| 147 |
|
| 148 |
error_info (on HTTP error, dict, {'error': {'code': 'Base.1.0.GeneralError', 'message': 'A general error has occurred. See ExtendedInfo for more information.', '@Message.ExtendedInfo': [{'MessageId': 'GEN1234', 'RelatedProperties': [], 'Message': 'Unable to process the request because an error occurred.', 'MessageArgs': [], 'Severity': 'Critical', 'Resolution': 'Retry the operation. If the issue persists, contact your system administrator.'}]}}) |
| 149 |
Details of the HTTP Error. |
| 150 |
|
| 151 |
|
| 152 |
|
| 153 |
|
| 154 |
|
| 155 |
Status |
| 156 |
------ |
| 157 |
|
| 158 |
|
| 159 |
|
| 160 |
|
| 161 |
|
| 162 |
Authors |
| 163 |
~~~~~~~ |
| 164 |
|
| 165 |
- Jagadeesh N V(@jagadeeshnv) |
| 166 |
- Bhavneet Sharma (@Bhavneet-Sharma) |
| 167 |
|