3a1270fb920c103551436081a347534b171a5582
[yaml_builds.git] / site_type / sriov-a13 / templates / profiles / host / cp_r720.j2
1 ---
2 # The primary control plane host profile for Airship for DELL R720s, and
3 # should not need to be altered if you are using matching HW. The active
4 # participants in the Ceph cluster run on this profile. Other control plane
5 # services are not affected by primary vs secondary designation.
6 schema: drydock/HostProfile/v1
7 metadata:
8   schema: metadata/Document/v1
9   name: cp_r720-primary
10   storagePolicy: cleartext
11   layeringDefinition:
12     abstract: false
13     layer: site
14     parentSelector:
15       hosttype: cp-global
16     actions:
17       - method: replace
18         path: .interfaces
19       - method: replace
20         path: .storage
21       - method: merge
22         path: .
23 data:
24   hardware_profile: dell_r720
25
26   primary_network: oam
27   interfaces:
28     pxe:
29       device_link: pxe
30       slaves:
31         - pxe_nic01
32       networks:
33         - pxe
34     bond0:
35       device_link: data
36       slaves:
37         - data_nic01
38         - data_nic02
39       networks:
40         - oam
41         - storage
42         - overlay
43         - calico
44 {% if 'dpdk' in yaml %}
45     dpdk:
46       device_link: dpdk
47       slaves:
48         - dpdk_nic01
49       networks:
50         - dpdk
51 {% endif %}
52 {% if 'sriov' in yaml %}
53     p1p1:
54       slaves:
55         - 'sriov_nic01'
56       sriov:
57         vf_count: 32 # Currently ignored
58         trustedmode: false
59     p3p2:
60       slaves:
61         - 'sriov_nic02'
62       sriov:
63         vf_count: 32 # Currently ignored
64         trustedmode: false
65 {% endif %}
66   storage:
67     physical_devices:
68 {% for disk in yaml.disks %}
69       {{disk.name}}:
70       {% if 'labels' in disk %}
71         labels:
72         {% for key, value in disk.labels.items() %}
73           {{key}}: '{{value}}'
74         {% endfor %}
75       {% endif %}
76         partitions:
77        {% for p in disk.partitions %}
78           - name: '{{p.name}}'
79             size: '{{p.size}}'
80             {% if 'bootable' in p %}
81             bootable: {{p.bootable}}
82             {% endif %}
83             filesystem:
84               mountpoint: '{{p.mountpoint}}'
85               fstype: 'ext4'
86               mount_options: 'defaults'
87       {% endfor %}
88 {% endfor %}
89
90   platform:
91     kernel: 'hwe-16.04'
92     kernel_params:
93 {% if 'platform' in yaml and 'kernel_params' in yaml.platform %}
94 {% for key, value in yaml.platform.kernel_params.items() %}
95       {{key}}: '{{value}}'
96 {% endfor %}
97 {% else %}
98       console: 'ttyS1,115200n8'
99       intel_iommu: 'on'
100       iommu: 'pt'
101       amd_iommu: 'on'
102       transparent_hugepage: 'never'
103 {% endif %}
104 {% if 'platform' in yaml and 'vcpu_pin_set' in yaml.platform %}
105       isolcpus: '{{yaml.platform.vcpu_pin_set}}'
106 {% endif %}
107
108   metadata:
109     owner_data:
110       tenant-ceph-osd: enabled
111       ucp-maas: enabled
112       openstack-nova-compute: enabled
113       openstack-libvirt: kernel
114       sriov: enabled
115 ...
116 ---
117 schema: drydock/HostProfile/v1
118 metadata:
119   schema: metadata/Document/v1
120   name: cp_r720-secondary
121   storagePolicy: cleartext
122   layeringDefinition:
123     abstract: false
124     layer: site
125     parentSelector:
126       hosttype: cp-global
127     actions:
128       - method: replace
129         path: .interfaces
130       - method: replace
131         path: .storage
132       - method: replace
133         path: .metadata.owner_data
134       - method: merge
135         path: .
136 data:
137   hardware_profile: dell_r720
138
139   primary_network: oam
140   interfaces:
141     pxe:
142       device_link: pxe
143       slaves:
144         - pxe_nic01
145       networks:
146         - pxe
147     bond0:
148       device_link: data
149       slaves:
150         - data_nic01
151         - data_nic02
152       networks:
153         - oam
154         - storage
155         - overlay
156         - calico
157 {% if 'dpdk' in yaml %}
158     dpdk:
159       device_link: dpdk
160       slaves:
161         - dpdk_nic01
162       networks:
163         - dpdk
164 {% endif %}
165 {% if 'sriov' in yaml %}
166     p1p1:
167       slaves:
168         - 'sriov_nic01'
169       sriov:
170         vf_count: 32 # Currently ignored
171         trustedmode: false
172     p3p2:
173       slaves:
174         - 'sriov_nic02'
175       sriov:
176         vf_count: 32 # Currently ignored
177         trustedmode: false
178 {% endif %}
179   storage:
180     physical_devices:
181 {% for disk in yaml.disks %}
182       {{disk.name}}:
183       {% if 'labels' in disk %}
184         labels:
185         {% for key, value in disk.labels.items() %}
186           {{key}}: '{{value}}'
187         {% endfor %}
188       {% endif %}
189         partitions:
190        {% for p in disk.partitions %}
191           - name: '{{p.name}}'
192             size: '{{p.size}}'
193             {% if 'bootable' in p %}
194             bootable: {{p.bootable}}
195             {% endif %}
196             filesystem:
197               mountpoint: '{{p.mountpoint}}'
198               fstype: 'ext4'
199               mount_options: 'defaults'
200       {% endfor %}
201 {% endfor %}
202
203   platform:
204     kernel: 'hwe-16.04'
205     kernel_params:
206 {% if 'platform' in yaml and 'kernel_params' in yaml.platform %}
207 {% for key, value in yaml.platform.kernel_params.items() %}
208       {{key}}: '{{value}}'
209 {% endfor %}
210 {% else %}
211       console: 'ttyS1,115200n8'
212       intel_iommu: 'on'
213       iommu: 'pt'
214       amd_iommu: 'on'
215       transparent_hugepage: 'never'
216 {% endif %}
217 {% if 'platform' in yaml and 'vcpu_pin_set' in yaml.platform %}
218       isolcpus: '{{yaml.platform.vcpu_pin_set}}'
219 {% endif %}
220
221   metadata:
222     owner_data:
223       ceph-mon: disabled
224       tenant-ceph-mon: disabled
225       tenant-ceph-osd: enabled
226       ucp-maas: enabled
227       openstack-nova-compute: enabled
228       openstack-libvirt: kernel
229       sriov: enabled
230 ...