| 1 |
--- |
| 2 |
- name: "Configure default IP Pool" |
| 3 |
vars: |
| 4 |
|
| 5 |
login_info: &login_info |
| 6 |
hostname: "{{ hostname }}" |
| 7 |
username: "{{ username | default(omit) }}" |
| 8 |
password: "{{ password | default('password') }}" |
| 9 |
state: "{{ state | default(omit) }}" |
| 10 |
cisco.ucs.ucs_ip_pool: |
| 11 |
<<: *login_info |
| 12 |
name: ext-mgmt |
| 13 |
ipv4_blocks: |
| 14 |
- first_addr: 198.18.0.20 |
| 15 |
last_addr: 198.18.0.40 |
| 16 |
subnet_mask: 255.255.255.0 |
| 17 |
default_gw: 198.18.0.1 |
| 18 |
tags: ip_pool |
| 19 |
- name: "Configure default MAC Pool" |
| 20 |
cisco.ucs.ucs_mac_pool: |
| 21 |
<<: *login_info |
| 22 |
name: default |
| 23 |
first_addr: 00:25:B5:DE:30:00 |
| 24 |
last_addr: 00:25:B5:DE:32:FF |
| 25 |
tags: mac_pool |
| 26 |
- name: "Configure default UUID Pool" |
| 27 |
cisco.ucs.ucs_uuid_pool: |
| 28 |
<<: *login_info |
| 29 |
name: default |
| 30 |
first_uuid: 0000-000000000001 |
| 31 |
last_uuid: 0000-000000000078 |
| 32 |
tags: uuid_pool |
| 33 |
- name: "Configure default Virtual Media Policy" |
| 34 |
cisco.ucs.ucs_managed_objects: |
| 35 |
<<: *login_info |
| 36 |
objects: |
| 37 |
- module: ucsmsdk.mometa.cimcvmedia.CimcvmediaMountConfigPolicy |
| 38 |
class: CimcvmediaMountConfigPolicy |
| 39 |
properties: |
| 40 |
parent_mo_or_dn: org-root |
| 41 |
name: "{{ vmedia_policy }}" |
| 42 |
children: |
| 43 |
- module: ucsmsdk.mometa.cimcvmedia.CimcvmediaConfigMountEntry |
| 44 |
class: CimcvmediaConfigMountEntry |
| 45 |
properties: |
| 46 |
device_type: cdd |
| 47 |
image_file_name: "{{ image_file_name | default('centos7.2-boot-ks.iso') }}" |
| 48 |
image_path: "{{ image_path | default('/home/public') }}" |
| 49 |
mapping_name: cdd-nfs |
| 50 |
mount_protocol: nfs |
| 51 |
remote_ip_address: "{{ remote_ip_address | default('198.18.134.242') }}" |
| 52 |
tags: virtual_media |
| 53 |
- name: "Configure default Boot Order Policy" |
| 54 |
cisco.ucs.ucs_managed_objects: |
| 55 |
<<: *login_info |
| 56 |
objects: |
| 57 |
- module: ucsmsdk.mometa.lsboot.LsbootPolicy |
| 58 |
class: LsbootPolicy |
| 59 |
properties: |
| 60 |
parent_mo_or_dn: org-root |
| 61 |
boot_mode: legacy |
| 62 |
enforce_vnic_name: 'yes' |
| 63 |
name: vmedia-local |
| 64 |
reboot_on_update: 'no' |
| 65 |
children: |
| 66 |
- module: ucsmsdk.mometa.lsboot.LsbootVirtualMedia |
| 67 |
class: LsbootVirtualMedia |
| 68 |
properties: |
| 69 |
access: read-only-remote-cimc |
| 70 |
lun_id: '0' |
| 71 |
order: '1' |
| 72 |
- module: ucsmsdk.mometa.lsboot.LsbootStorage |
| 73 |
class: LsbootStorage |
| 74 |
properties: |
| 75 |
order: '2' |
| 76 |
children: |
| 77 |
- module: ucsmsdk.mometa.lsboot.LsbootLocalStorage |
| 78 |
class: LsbootLocalStorage |
| 79 |
properties: {} |
| 80 |
children: |
| 81 |
- module: ucsmsdk.mometa.lsboot.LsbootDefaultLocalImage |
| 82 |
class: LsbootDefaultLocalImage |
| 83 |
properties: |
| 84 |
order: '2' |
| 85 |
tags: boot_order |
| 86 |
- name: "Configure default Server Pool" |
| 87 |
cisco.ucs.ucs_managed_objects: |
| 88 |
<<: *login_info |
| 89 |
objects: |
| 90 |
- module: ucsmsdk.mometa.compute.ComputePool |
| 91 |
class: ComputePool |
| 92 |
properties: |
| 93 |
parent_mo_or_dn: org-root |
| 94 |
name: default |
| 95 |
children: |
| 96 |
- module: ucsmsdk.mometa.compute.ComputePooledSlot |
| 97 |
class: ComputePooledSlot |
| 98 |
properties: |
| 99 |
chassis_id: '4' |
| 100 |
slot_id: '1' |
| 101 |
- module: ucsmsdk.mometa.compute.ComputePooledSlot |
| 102 |
class: ComputePooledSlot |
| 103 |
properties: |
| 104 |
chassis_id: '4' |
| 105 |
slot_id: '2' |
| 106 |
tags: server_pool |