Debian Codegraph @

ansible_collections/dellemc/openmanage/roles/idrac_import_server_config_profile/README.md

raw symbols SCIP
1 # idrac_import_server_config_profile
2
3 Role to import the Server Configuration Profile (SCP) from the iDRAC to a network share (CIFS, NFS, HTTP, HTTPS) or a local path.
4
5 ## Requirements
6
7 ### Development
8 Requirements to develop and contribute to the role.
9 ```
10 ansible
11 docker
12 molecule
13 python
14 ```
15 ### Production
16 Requirements to use the role.
17 ```
18 ansible
19 python
20 ```
21
22 ### Ansible collections
23 Collections required to use the role
24 ```
25 dellemc.openmanage
26 ```
27
28 ## Role Variables
29
30 <table>
31 <thead>
32 <tr>
33 <th>Name</th>
34 <th>Required</th>
35 <th>Default Value</th>
36 <th>Choices</th>
37 <th>Type</th>
38 <th>Description</th>
39 </tr>
40 </thead>
41 <tbody>
42 <tr>
43 <td>hostname</td>
44 <td>true</td>
45 <td></td>
46 <td></td>
47 <td>str</td>
48 <td>iDRAC IP Address</td>
49 </tr>
50 <tr>
51 <td>username</td>
52 <td>true</td>
53 <td></td>
54 <td></td>
55 <td>str</td>
56 <td>iDRAC username</td>
57 </tr>
58 <tr>
59 <td>password</td>
60 <td>true</td>
61 <td></td>
62 <td></td>
63 <td>str</td>
64 <td>iDRAC user password.</td>
65 </tr>
66 <tr>
67 <td>https_port</td>
68 <td>false</td>
69 <td>443</td>
70 <td></td>
71 <td>int</td>
72 <td>iDRAC port.</td>
73 </tr>
74 <tr>
75 <td>validate_certs</td>
76 <td>false</td>
77 <td>true</td>
78 <td></td>
79 <td>bool</td>
80 <td>- If C(false), the SSL certificates will not be validated.<br>- Configure C(false) only on personally controlled sites where self-signed certificates are used.</td>
81 </tr>
82 <tr>
83 <td>ca_path</td>
84 <td>false</td>
85 <td></td>
86 <td></td>
87 <td>path</td>
88 <td>The Privacy Enhanced Mail (PEM) file that contains a CA certificate to be used for the validation.</td>
89 </tr>
90 <tr>
91 <td>https_timeout</td>
92 <td>false</td>
93 <td>30</td>
94 <td></td>
95 <td>int</td>
96 <td> The HTTPS socket level timeout in seconds.</td>
97 </tr>
98 <tr>
99 <td>share_parameters</td>
100 <td>false</td>
101 <td></td>
102 <td></td>
103 <td>dict</td>
104 <td>Network share parameters.</td>
105 </tr>
106 <tr>
107 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;share_name</td>
108 <td>false</td>
109 <td></td>
110 <td></td>
111 <td>str</td>
112 <td>- Network share or local path.<br>- CIFS, NFS, HTTP, and HTTPS network share types are supported.</td>
113 </tr>
114 <tr>
115 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;scp_file</td>
116 <td>false</td>
117 <td></td>
118 <td></td>
119 <td>str</td>
120 <td>- Name of the server configuration profile (SCP) file.</br>- The default format `idrac_ip_YYMMDD_HHMMSS_scp` is used if this option is not specified.</br>- I(export_format) is used if the valid extension file is not provided.</td>
121 </tr>
122 <tr>
123 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;share_user</td>
124 <td>false</td>
125 <td></td>
126 <td></td>
127 <td>str</td>
128 <td>Network share user in the format 'user@domain' or 'domain\\user' if user is part of a domain else 'user'. This option is mandatory for CIFS Network Share..</td>
129 </tr>
130 <tr>
131 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;share_password</td>
132 <td>false</td>
133 <td></td>
134 <td></td>
135 <td>str</td>
136 <td>Network share user password. This option is mandatory for CIFS Network Share.</td>
137 </tr>
138 <tr>
139 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_support</td>
140 <td>false</td>
141 <td>false</td>
142 <td></td>
143 <td>bool</td>
144 <td>- Proxy to be enabled or disabled.</br>- I(proxy_support) is considered only when I(share_name) is of type HTTP or HTTPS and is supported only on iDRAC9.</td>
145 </tr>
146 <tr>
147 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_type</td>
148 <td>false</td>
149 <td>http</td>
150 <td>http, socks4</td>
151 <td>str</td>
152 <td>- C(http) to select HTTP type proxy.</br>- C(socks4) to select SOCKS4 type proxy.</br>- I(proxy_type) is considered only when I(share_name) is of type HTTP or HTTPS and is supported only on iDRAC9.</td>
153 </tr>
154 <tr>
155 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_server</td>
156 <td>false</td>
157 <td></td>
158 <td></td>
159 <td>str</td>
160 <td> - I(proxy_server) is required when I(share_name) is of type HTTPS or HTTP and I(proxy_support) is C(true).</br>- I(proxy_server) is considered only when I(share_name) is of type HTTP or HTTPS and is supported only on iDRAC9.</td>
161 </tr>
162 <tr>
163 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_port</td>
164 <td>false</td>
165 <td>80</td>
166 <td></td>
167 <td>str</td>
168 <td>- Proxy port to authenticate.</br> - I(proxy_port) is required when I(share_name) is of type HTTPS or HTTP and I(proxy_support) is C(true).</br>- I(proxy_port) is considered only when I(share_name) is of type HTTP or HTTPS and is supported only on iDRAC9.</td>
169 </tr>
170 <tr>
171 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_username</td>
172 <td>false</td>
173 <td></td>
174 <td></td>
175 <td>str</td>
176 <td>- Proxy username to authenticate.</br>- I(proxy_username) is considered only when I(share_name) is of type HTTP or HTTPS and is supported only on iDRAC9.</td>
177 </tr>
178 <tr>
179 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;proxy_password</td>
180 <td>false</td>
181 <td></td>
182 <td></td>
183 <td>str</td>
184 <td>- Proxy password to authenticate.</br>- I(proxy_password) is considered only when I(share_name) is of type HTTP or HTTPS and is supported only on iDRAC9.</td>
185 </tr>
186 <tr>
187 <td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;ignore_certificate_warning</td>
188 <td>false</td>
189 <td>ignore</td>
190 <td>ignore, showerror</td>
191 <td>str</td>
192 <td>- If C(ignore), it ignores the certificate warnings.</br>- If C(showerror), it shows the certificate warnings.</br>
193 - I(ignore_certificate_warning) is considered only when I(share_name) is of type HTTPS and is supported only on iDRAC9.</td>
194 </tr>
195 <tr>
196 <td>target</td>
197 <td>false</td>
198 <td>['ALL']</td>
199 <td>'ALL', 'IDRAC', 'BIOS', 'NIC', 'RAID'</td>
200 <td>str</td>
201 <td>- If C(ALL), this module exports or imports all components configurations from SCP file.<br>- If C(IDRAC), this module exports or imports iDRAC configuration from SCP file.<br>- If C(BIOS), this module exports or imports BIOS configuration from SCP file.<br>- If C(NIC), this module exports or imports NIC configuration from SCP file.<br>- If C(RAID), this module exports or imports RAID configuration from SCP file.</br>- When I(command) is C(export) or C(import) I(target) with multiple components is supported only on iDRAC9 with firmware 6.10.00.00 and above.</td>
202 </tr>
203 <tr>
204 <td>import_buffer</td>
205 <td>false</td>
206 <td></td>
207 <td>'Enabled', 'Disabled'</td>
208 <td>str</td>
209 <td> - SCP content buffer.<br>
210 - This is mutually exclusive with share_parameters.scp_file.
211 </td>
212 </tr>
213 <tr>
214 <td>end_host_power_state</td>
215 <td>false</td>
216 <td>'On'</td>
217 <td>'On', 'Off'</td>
218 <td>str</td>
219 <td> Host power state after import of server configuration profile.</td>
220 </tr>
221 <tr>
222 <td>shutdown_type</td>
223 <td>false</td>
224 <td>'Graceful'</td>
225 <td>'Graceful', 'Forced', 'NoReboot'</td>
226 <td>str</td>
227 <td> Server shutdown type.</td>
228 </tr>
229 </tbody>
230 </table>
231
232 ## Fact variables
233
234 <table>
235 <thead>
236 <tr>
237 <th>Name</th>
238 <th>Sample</th>
239 <th>Description</th>
240 </tr>
241 </thead>
242 <tbody>
243 <tr>
244 <td>idrac_import_server_config_profile_out</td>
245 <td>{
246 "changed": false,
247 "msg": "Successfully imported the Server Configuration Profile.",
248 "scp_status": {
249 "CompletionTime": "2023-02-21T04:12:37",
250 "Description": "Job Instance",
251 "EndTime": null,
252 "Id": "JID_774927528227",
253 "JobState": "Completed",
254 "JobType": "ImportConfiguration",
255 "Message": "No changes were applied since the current component configuration matched the requested configuration.",
256 "MessageArgs": [],
257 "MessageId": "IDRAC.2.8.SYS069",
258 "Name": "Configure: Import Server Configuration Profile",
259 "PercentComplete": 100,
260 "StartTime": "TIME_NOW",
261 "TargetSettingsURI": null,
262 "TaskStatus": "OK",
263 "file": ".\\192.1.2.1_2023221_5549_scp.xml",
264 "retval": true
265 }
266 }</td>
267 <td>Module output of the Server Configuration Job</td>
268 </tr>
269 </tbody>
270 </table>
271
272 ## Examples
273 -----
274
275 ```
276 - name: Importing SCP from local path with all components
277 ansible.builtin.import_role:
278 name: idrac_import_server_config_profile
279 vars:
280 hostname: "192.1.2.1"
281 username: "username"
282 password: "password"
283 ca_path: "/path/to/ca_cert.pem"
284 share_parameters:
285 share_name: "/root/tmp"
286 scp_file: "file.xml"
287 ```
288 ```
289 - name: Importing SCP from NFS with iDRAC components
290 ansible.builtin.import_role:
291 name: idrac_import_server_config_profile
292 vars:
293 hostname: "192.1.2.1"
294 username: "username"
295 password: "password"
296 ca_path: "/path/to/ca_cert.pem"
297 target: ['IDRAC']
298 share_parameters:
299 share_name: "191.2.1.1:/nfs"
300 scp_file: "file.json"
301 ```
302 ```
303 - name: Importing SCP from CIFS with BIOS components
304 ansible.builtin.import_role:
305 name: "idrac_import_server_config_profile"
306 vars:
307 hostname: "192.1.2.1"
308 username: "username"
309 password: "password"
310 ca_path: "/path/to/ca_cert.pem"
311 target: ['BIOS']
312 share_parameters:
313 share_name: "\\\\191.1.1.1\\cifs"
314 share_user: "username"
315 share_password: "password"
316 scp_file: "file.xml"
317 ```
318 ```
319 - name: Importing SCP from HTTPS with RAID components
320 ansible.builtin.import_role:
321 name: "idrac_import_server_config_profile"
322 vars:
323 hostname: "192.1.2.1"
324 username: "username"
325 password: "password"
326 ca_path: "/path/to/ca_cert.pem"
327 target: ['RAID']
328 share_parameters:
329 share_name: "https://192.1.1.1/share"
330 share_user: "username"
331 share_password: "password"
332 scp_file: "filename.json"
333 ```
334 ```
335 - name: "Importing SCP from HTTP with NIC components"
336 ansible.builtin.import_role:
337 name: "idrac_import_server_config_profile"
338 vars:
339 hostname: "192.1.2.1"
340 username: "username"
341 password: "password"
342 ca_path: "/path/to/ca_cert.pem"
343 target: ['NIC']
344 share_parameters:
345 share_name: "http://192.1.1.1/share"
346 share_user: "username"
347 share_password: "password"
348 scp_file: "filename.xml"
349 ```
350 ```
351 - name: "Importing SCP using import buffer with NIC components"
352 ansible.builtin.import_role:
353 name: "idrac_import_server_config_profile"
354 vars:
355 hostname: "192.1.2.1"
356 username: "username"
357 password: "password"
358 ca_path: "/path/to/ca_cert.pem"
359 target: ['NIC']
360 import_buffer: "<SystemConfiguration><Component FQDD='iDRAC.Embedded.1'><Attribute Name='IPMILan.1#Enable'> Disabled</Attribute></Component></SystemConfiguration>"
361 ```
362 ```
363 - name: "Importing SCP from HTTP with NIC components using proxy"
364 ansible.builtin.import_role:
365 name: "idrac_import_server_config_profile"
366 vars:
367 hostname: "192.1.2.1"
368 username: "username"
369 password: "password"
370 ca_path: "/path/to/ca_cert.pem"
371 target: ['NIC']
372 share_parameters:
373 share_name: "http://192.1.1.1/share"
374 share_user: "username"
375 share_password: "password"
376 scp_file: "filename.xml"
377 proxy_support: true
378 proxy_server: 192.168.0.6
379 proxy_port: 8080
380 proxy_type: socks4
381 ```
382 ```
383 - name: Import SCP
384 hosts: idrac
385 roles:
386 - role: idrac_import_server_config_profile
387 ```
388
389 ## Author Information
390 ------------------
391
392 Dell Technologies <br>
393 Abhishek Sinha ([email protected]) 2023