remove blank lines from end of templates
[yaml_builds.git] / site_type / ovsdpdk / templates / baremetal / rack.j2
1 {% for server in yaml.masters %}
2 ---
3 ##############################################################################
4 # Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.        #
5 #                                                                            #
6 # Licensed under the Apache License, Version 2.0 (the "License"); you may    #
7 # not use this file except in compliance with the License.                   #
8 #                                                                            #
9 # You may obtain a copy of the License at                                    #
10 #       http://www.apache.org/licenses/LICENSE-2.0                           #
11 #                                                                            #
12 # Unless required by applicable law or agreed to in writing, software        #
13 # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT  #
14 # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.           #
15 # See the License for the specific language governing permissions and        #
16 # limitations under the License.                                             #
17 ##############################################################################
18 schema: 'drydock/BaremetalNode/v1'
19 metadata:
20   schema: 'metadata/Document/v1'
21   name: {{server.name}}
22   layeringDefinition:
23     abstract: false
24     layer: site
25   storagePolicy: cleartext
26 data:
27   host_profile: ControlPlane
28   # the hostname for a server, could be used in multiple DNS domains to
29   # represent different interfaces
30   addressing:
31       # Which network the address applies to. If a network appears in addressing
32       # that isn't assigned to an interface, design validation will fail
33     - network: oob
34       address: {{server.oob}}
35     - network: pxe
36       # The address assigned. Either a explicit IPv4 or IPv6 address
37       # or dhcp or slaac
38       address: {{server.pxe}}
39     - network: oam
40       address: {{server.host}}
41     - network: storage
42       address: {{server.storage}}
43     - network: overlay
44       address: {{server.neutron}}
45     - network: calico
46       address: {{server.ksn}}
47   metadata:
48     rack: RACK01
49     tags:
50       - 'masters'
51 {% if 'platform' in yaml %}
52   platform:
53     kernel_params:
54 {% for key, value in yaml.platform.kernel_params.items() %}
55       {{key}}: {{value}}
56 {% endfor %}{% endif %}
57 {% endfor %}
58 {% if 'workers' in yaml %}{% for server in yaml.workers %}
59 ---
60 schema: 'drydock/BaremetalNode/v1'
61 metadata:
62   schema: 'metadata/Document/v1'
63   name: {{server.name}}
64   layeringDefinition:
65     abstract: false
66     layer: site
67   storagePolicy: cleartext
68 data:
69   host_profile: ComputePlane
70   # the hostname for a server, could be used in multiple DNS domains to
71   # represent different interfaces
72   addressing:
73       # Which network the address applies to. If a network appears in addressing
74       # that isn't assigned to an interface, design validation will fail
75     - network: oob
76       address: {{server.oob}}
77     - network: pxe
78       # The address assigned. Either a explicit IPv4 or IPv6 address
79       # or dhcp or slaac
80       address: {{server.pxe}}
81     - network: oam
82       address: {{server.host}}
83     - network: storage
84       address: {{server.storage}}
85     - network: overlay
86       address: {{server.neutron}}
87     - network: calico
88       address: {{server.ksn}}
89   metadata:
90     rack: RACK01
91     tags:
92       - 'workers'
93 {% if 'platform' in yaml %}
94   platform:
95     kernel_params:
96 {% for key, value in yaml.platform.kernel_params.items() %}
97       {{key}}: {{value}}
98 {% endfor %}{% endif %}
99 {% endfor %}{% endif %}
100 ...