Gary Wu | 11c9874 | 2018-05-02 16:19:04 -0700 | [diff] [blame] | 1 | # |
| 2 | # Generated by scripts/gen-onap-oom-yaml.sh; MANUAL CHANGES WILL BE LOST |
| 3 | # |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 4 | heat_template_version: 2015-10-15 |
| 5 | description: ONAP on Kubernetes using OOM |
| 6 | |
| 7 | parameters: |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 8 | docker_proxy: |
| 9 | type: string |
| 10 | |
| 11 | apt_proxy: |
| 12 | type: string |
| 13 | |
Gary Wu | c98156d | 2018-01-18 12:03:26 -0800 | [diff] [blame] | 14 | public_net_id: |
| 15 | type: string |
| 16 | description: The ID of the Public network for floating IP address allocation |
| 17 | |
Gary Wu | c98156d | 2018-01-18 12:03:26 -0800 | [diff] [blame] | 18 | oam_network_cidr: |
| 19 | type: string |
| 20 | description: CIDR of the OAM ONAP network |
| 21 | |
Gary Wu | 60dd0d8 | 2018-01-18 14:54:47 -0800 | [diff] [blame] | 22 | ubuntu_1604_image: |
| 23 | type: string |
| 24 | description: Name of the Ubuntu 16.04 image |
| 25 | |
Gary Wu | 60dd0d8 | 2018-01-18 14:54:47 -0800 | [diff] [blame] | 26 | rancher_vm_flavor: |
| 27 | type: string |
Gary Wu | 11c9874 | 2018-05-02 16:19:04 -0700 | [diff] [blame] | 28 | description: VM flavor for Rancher |
Gary Wu | 60dd0d8 | 2018-01-18 14:54:47 -0800 | [diff] [blame] | 29 | |
| 30 | k8s_vm_flavor: |
| 31 | type: string |
Gary Wu | 11c9874 | 2018-05-02 16:19:04 -0700 | [diff] [blame] | 32 | description: VM flavor for k8s hosts |
| 33 | |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 34 | etcd_vm_flavor: |
| 35 | type: string |
| 36 | description: VM flavor for etcd hosts |
| 37 | |
| 38 | orch_vm_flavor: |
| 39 | type: string |
| 40 | description: VM flavor for orch hosts |
| 41 | |
Gary Wu | 11c9874 | 2018-05-02 16:19:04 -0700 | [diff] [blame] | 42 | integration_override_yaml: |
| 43 | type: string |
| 44 | description: Content for integration_override.yaml |
Gary Wu | 60dd0d8 | 2018-01-18 14:54:47 -0800 | [diff] [blame] | 45 | |
Gary Wu | 87aa8b5 | 2018-08-09 08:10:24 -0700 | [diff] [blame] | 46 | integration_gerrit_branch: |
Gary Wu | 81836d2 | 2018-06-22 13:48:50 -0700 | [diff] [blame] | 47 | type: string |
| 48 | default: "master" |
| 49 | |
Gary Wu | 87aa8b5 | 2018-08-09 08:10:24 -0700 | [diff] [blame] | 50 | integration_gerrit_refspec: |
| 51 | type: string |
Gary Wu | 6842fa3 | 2018-11-20 10:29:22 -0800 | [diff] [blame] | 52 | default: "" |
Gary Wu | 87aa8b5 | 2018-08-09 08:10:24 -0700 | [diff] [blame] | 53 | |
| 54 | oom_gerrit_branch: |
| 55 | type: string |
| 56 | default: "master" |
| 57 | |
| 58 | oom_gerrit_refspec: |
Gary Wu | 81836d2 | 2018-06-22 13:48:50 -0700 | [diff] [blame] | 59 | type: string |
Gary Wu | 6842fa3 | 2018-11-20 10:29:22 -0800 | [diff] [blame] | 60 | default: "" |
Gary Wu | 81836d2 | 2018-06-22 13:48:50 -0700 | [diff] [blame] | 61 | |
| 62 | docker_manifest: |
| 63 | type: string |
Gary Wu | 87aa8b5 | 2018-08-09 08:10:24 -0700 | [diff] [blame] | 64 | default: "" |
Gary Wu | 81836d2 | 2018-06-22 13:48:50 -0700 | [diff] [blame] | 65 | |
gwu | 10db462 | 2018-07-17 22:11:39 -0700 | [diff] [blame] | 66 | key_name: |
| 67 | type: string |
| 68 | default: "onap_key" |
| 69 | |
Gary Wu | 7a04b3d | 2018-08-15 12:31:46 -0700 | [diff] [blame] | 70 | docker_version: |
| 71 | type: string |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 72 | default: "17.03.2" |
Gary Wu | 7a04b3d | 2018-08-15 12:31:46 -0700 | [diff] [blame] | 73 | |
| 74 | rancher_version: |
| 75 | type: string |
Gary Wu | 37699b5 | 2019-03-22 10:59:03 -0700 | [diff] [blame] | 76 | default: "1.6.26" |
Gary Wu | 7a04b3d | 2018-08-15 12:31:46 -0700 | [diff] [blame] | 77 | |
| 78 | rancher_agent_version: |
| 79 | type: string |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 80 | default: "1.2.11" |
Gary Wu | 7a04b3d | 2018-08-15 12:31:46 -0700 | [diff] [blame] | 81 | |
| 82 | kubectl_version: |
| 83 | type: string |
Gary Wu | d1edb20 | 2019-03-22 13:09:59 -0700 | [diff] [blame] | 84 | default: "1.11.8" |
Gary Wu | 7a04b3d | 2018-08-15 12:31:46 -0700 | [diff] [blame] | 85 | |
| 86 | helm_version: |
| 87 | type: string |
| 88 | default: "2.9.1" |
| 89 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 90 | helm_deploy_delay: |
| 91 | type: string |
| 92 | default: "2m" |
| 93 | |
| 94 | use_ramdisk: |
| 95 | type: string |
| 96 | description: Set to "true" if you want to use a RAM disk for /dockerdata-nfs/. |
| 97 | default: "false" |
| 98 | |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 99 | mtu: |
| 100 | type: number |
| 101 | default: 1500 |
| 102 | |
Gary Wu | 4a69d51 | 2018-12-10 11:31:24 -0800 | [diff] [blame] | 103 | portal_hostname: |
| 104 | type: string |
| 105 | description: The FQDN of the k8s host that will be used for the Portal UI component URLs; this needs to be resolveable at the client |
| 106 | default: "portal.api.simpledemo.onap.org" |
| 107 | |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 108 | resources: |
Gary Wu | c98156d | 2018-01-18 12:03:26 -0800 | [diff] [blame] | 109 | random-str: |
| 110 | type: OS::Heat::RandomString |
| 111 | properties: |
| 112 | length: 4 |
| 113 | |
Gary Wu | bc11e5d | 2018-02-07 10:23:27 -0800 | [diff] [blame] | 114 | # ONAP security group |
| 115 | onap_sg: |
| 116 | type: OS::Neutron::SecurityGroup |
| 117 | properties: |
| 118 | name: |
| 119 | str_replace: |
| 120 | template: base_rand |
| 121 | params: |
| 122 | base: onap_sg |
| 123 | rand: { get_resource: random-str } |
| 124 | description: security group used by ONAP |
| 125 | rules: |
| 126 | # All egress traffic |
| 127 | - direction: egress |
| 128 | ethertype: IPv4 |
| 129 | - direction: egress |
| 130 | ethertype: IPv6 |
| 131 | # ingress traffic |
| 132 | # ICMP |
| 133 | - protocol: icmp |
| 134 | - protocol: udp |
| 135 | port_range_min: 1 |
| 136 | port_range_max: 65535 |
| 137 | - protocol: tcp |
| 138 | port_range_min: 1 |
| 139 | port_range_max: 65535 |
Marco Platania | 2a6faaa | 2018-11-12 15:00:08 -0500 | [diff] [blame] | 140 | # Protocols used for vLB/vDNS use case |
| 141 | - protocol: 47 |
| 142 | - protocol: 53 |
| 143 | - protocol: 132 |
Gary Wu | bc11e5d | 2018-02-07 10:23:27 -0800 | [diff] [blame] | 144 | |
| 145 | |
Gary Wu | 52dfdcb | 2018-01-25 11:02:48 -0800 | [diff] [blame] | 146 | # ONAP management private network |
| 147 | oam_network: |
| 148 | type: OS::Neutron::Net |
| 149 | properties: |
| 150 | name: |
| 151 | str_replace: |
| 152 | template: oam_network_rand |
| 153 | params: |
| 154 | rand: { get_resource: random-str } |
| 155 | |
| 156 | oam_subnet: |
| 157 | type: OS::Neutron::Subnet |
| 158 | properties: |
| 159 | name: |
| 160 | str_replace: |
| 161 | template: oam_network_rand |
| 162 | params: |
| 163 | rand: { get_resource: random-str } |
| 164 | network_id: { get_resource: oam_network } |
| 165 | cidr: { get_param: oam_network_cidr } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 166 | dns_nameservers: [ "8.8.8.8" ] |
Gary Wu | 52dfdcb | 2018-01-25 11:02:48 -0800 | [diff] [blame] | 167 | |
| 168 | router: |
| 169 | type: OS::Neutron::Router |
| 170 | properties: |
eHanan | 97b7a9c | 2018-09-05 14:09:19 +0100 | [diff] [blame] | 171 | name: |
| 172 | list_join: ['-', [{ get_param: 'OS::stack_name' }, 'router']] |
Gary Wu | 52dfdcb | 2018-01-25 11:02:48 -0800 | [diff] [blame] | 173 | external_gateway_info: |
| 174 | network: { get_param: public_net_id } |
| 175 | |
| 176 | router_interface: |
| 177 | type: OS::Neutron::RouterInterface |
| 178 | properties: |
| 179 | router_id: { get_resource: router } |
| 180 | subnet_id: { get_resource: oam_subnet } |
| 181 | |
Gary Wu | 374498a | 2018-02-06 17:31:04 -0800 | [diff] [blame] | 182 | rancher_private_port: |
| 183 | type: OS::Neutron::Port |
| 184 | properties: |
| 185 | network: { get_resource: oam_network } |
| 186 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
Gary Wu | bc11e5d | 2018-02-07 10:23:27 -0800 | [diff] [blame] | 187 | security_groups: |
| 188 | - { get_resource: onap_sg } |
Gary Wu | 374498a | 2018-02-06 17:31:04 -0800 | [diff] [blame] | 189 | |
| 190 | rancher_floating_ip: |
| 191 | type: OS::Neutron::FloatingIP |
| 192 | properties: |
| 193 | floating_network_id: { get_param: public_net_id } |
| 194 | port_id: { get_resource: rancher_private_port } |
| 195 | |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 196 | rancher_vm: |
| 197 | type: OS::Nova::Server |
| 198 | properties: |
eHanan | 97b7a9c | 2018-09-05 14:09:19 +0100 | [diff] [blame] | 199 | name: |
| 200 | list_join: ['-', [{ get_param: 'OS::stack_name' }, 'rancher']] |
Gary Wu | 558ac6e | 2018-01-19 14:53:12 -0800 | [diff] [blame] | 201 | image: { get_param: ubuntu_1604_image } |
Gary Wu | 60dd0d8 | 2018-01-18 14:54:47 -0800 | [diff] [blame] | 202 | flavor: { get_param: rancher_vm_flavor } |
gwu | 10db462 | 2018-07-17 22:11:39 -0700 | [diff] [blame] | 203 | key_name: { get_param: key_name } |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 204 | networks: |
Gary Wu | 374498a | 2018-02-06 17:31:04 -0800 | [diff] [blame] | 205 | - port: { get_resource: rancher_private_port } |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 206 | user_data_format: RAW |
| 207 | user_data: |
| 208 | str_replace: |
Gary Wu | 1ff5667 | 2018-01-17 20:51:45 -0800 | [diff] [blame] | 209 | template: |
| 210 | get_file: rancher_vm_entrypoint.sh |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 211 | params: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 212 | __docker_proxy__: { get_param: docker_proxy } |
| 213 | __apt_proxy__: { get_param: apt_proxy } |
| 214 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
Gary Wu | ad51372 | 2018-07-26 13:08:47 -0700 | [diff] [blame] | 215 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
Gary Wu | 11c9874 | 2018-05-02 16:19:04 -0700 | [diff] [blame] | 216 | __integration_override_yaml__: { get_param: integration_override_yaml } |
Gary Wu | 87aa8b5 | 2018-08-09 08:10:24 -0700 | [diff] [blame] | 217 | __integration_gerrit_branch__: { get_param: integration_gerrit_branch } |
| 218 | __integration_gerrit_refspec__: { get_param: integration_gerrit_refspec } |
| 219 | __oom_gerrit_branch__: { get_param: oom_gerrit_branch } |
| 220 | __oom_gerrit_refspec__: { get_param: oom_gerrit_refspec } |
Gary Wu | 81836d2 | 2018-06-22 13:48:50 -0700 | [diff] [blame] | 221 | __docker_manifest__: { get_param: docker_manifest } |
Gary Wu | 7a04b3d | 2018-08-15 12:31:46 -0700 | [diff] [blame] | 222 | __docker_version__: { get_param: docker_version } |
| 223 | __rancher_version__: { get_param: rancher_version } |
| 224 | __rancher_agent_version__: { get_param: rancher_agent_version } |
| 225 | __kubectl_version__: { get_param: kubectl_version } |
| 226 | __helm_version__: { get_param: helm_version } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 227 | __helm_deploy_delay__: { get_param: helm_deploy_delay } |
| 228 | __use_ramdisk__: { get_param: use_ramdisk } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 229 | __mtu__: { get_param: mtu } |
Gary Wu | 4a69d51 | 2018-12-10 11:31:24 -0800 | [diff] [blame] | 230 | __portal_hostname__: { get_param: portal_hostname } |
Gary Wu | 978171e | 2018-07-24 11:56:01 -0700 | [diff] [blame] | 231 | __public_net_id__: { get_param: public_net_id } |
| 232 | __oam_network_cidr__: { get_param: oam_network_cidr } |
Gary Wu | 11c9874 | 2018-05-02 16:19:04 -0700 | [diff] [blame] | 233 | __oam_network_id__: { get_resource: oam_network } |
| 234 | __oam_subnet_id__: { get_resource: oam_subnet } |
Gary Wu | 17440fe | 2018-10-22 15:12:07 -0700 | [diff] [blame] | 235 | __sec_group__: { get_resource: onap_sg } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 236 | __k8s_01_vm_ip__: { get_attr: [k8s_01_floating_ip, floating_ip_address] } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 237 | __k8s_vm_ips__: [ |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 238 | get_attr: [k8s_01_floating_ip, floating_ip_address], |
| 239 | get_attr: [k8s_02_floating_ip, floating_ip_address], |
| 240 | get_attr: [k8s_03_floating_ip, floating_ip_address], |
| 241 | get_attr: [k8s_04_floating_ip, floating_ip_address], |
| 242 | get_attr: [k8s_05_floating_ip, floating_ip_address], |
| 243 | get_attr: [k8s_06_floating_ip, floating_ip_address], |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 244 | ] |
Gary Wu | ad51372 | 2018-07-26 13:08:47 -0700 | [diff] [blame] | 245 | __k8s_private_ips__: [ |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 246 | get_attr: [k8s_01_floating_ip, fixed_ip_address], |
| 247 | get_attr: [k8s_02_floating_ip, fixed_ip_address], |
| 248 | get_attr: [k8s_03_floating_ip, fixed_ip_address], |
| 249 | get_attr: [k8s_04_floating_ip, fixed_ip_address], |
| 250 | get_attr: [k8s_05_floating_ip, fixed_ip_address], |
| 251 | get_attr: [k8s_06_floating_ip, fixed_ip_address], |
Gary Wu | ad51372 | 2018-07-26 13:08:47 -0700 | [diff] [blame] | 252 | ] |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 253 | k8s_01_private_port: |
Gary Wu | 52dfdcb | 2018-01-25 11:02:48 -0800 | [diff] [blame] | 254 | type: OS::Neutron::Port |
| 255 | properties: |
| 256 | network: { get_resource: oam_network } |
| 257 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
Gary Wu | bc11e5d | 2018-02-07 10:23:27 -0800 | [diff] [blame] | 258 | security_groups: |
| 259 | - { get_resource: onap_sg } |
Gary Wu | 52dfdcb | 2018-01-25 11:02:48 -0800 | [diff] [blame] | 260 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 261 | k8s_01_floating_ip: |
Gary Wu | 52dfdcb | 2018-01-25 11:02:48 -0800 | [diff] [blame] | 262 | type: OS::Neutron::FloatingIP |
| 263 | properties: |
| 264 | floating_network_id: { get_param: public_net_id } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 265 | port_id: { get_resource: k8s_01_private_port } |
Gary Wu | 52dfdcb | 2018-01-25 11:02:48 -0800 | [diff] [blame] | 266 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 267 | k8s_01_vm_scripts: |
| 268 | type: OS::Heat::CloudConfig |
| 269 | properties: |
| 270 | cloud_config: |
| 271 | power_state: |
| 272 | mode: reboot |
| 273 | runcmd: |
| 274 | - [ /opt/k8s_vm_install.sh ] |
| 275 | write_files: |
| 276 | - path: /opt/k8s_vm_install.sh |
| 277 | permissions: '0755' |
| 278 | content: |
| 279 | str_replace: |
| 280 | params: |
| 281 | __docker_proxy__: { get_param: docker_proxy } |
| 282 | __apt_proxy__: { get_param: apt_proxy } |
| 283 | __docker_version__: { get_param: docker_version } |
| 284 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 285 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 286 | __host_private_ip_addr__: { get_attr: [k8s_01_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 287 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 288 | template: |
| 289 | get_file: k8s_vm_install.sh |
| 290 | - path: /opt/k8s_vm_init.sh |
| 291 | permissions: '0755' |
| 292 | content: |
| 293 | str_replace: |
| 294 | params: |
| 295 | __host_private_ip_addr__: { get_attr: [k8s_01_floating_ip, fixed_ip_address] } |
| 296 | __host_label__: 'compute' |
| 297 | template: |
| 298 | get_file: k8s_vm_init.sh |
| 299 | - path: /etc/init.d/k8s_vm_init_serv |
| 300 | permissions: '0755' |
| 301 | content: |
| 302 | get_file: k8s_vm_init_serv.sh |
| 303 | |
| 304 | k8s_01_vm_config: |
| 305 | type: OS::Heat::MultipartMime |
| 306 | properties: |
| 307 | parts: |
| 308 | - config: { get_resource: k8s_01_vm_scripts } |
| 309 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 310 | k8s_01_vm: |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 311 | type: OS::Nova::Server |
| 312 | properties: |
eHanan | 97b7a9c | 2018-09-05 14:09:19 +0100 | [diff] [blame] | 313 | name: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 314 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s', '01' ] ] |
Gary Wu | 558ac6e | 2018-01-19 14:53:12 -0800 | [diff] [blame] | 315 | image: { get_param: ubuntu_1604_image } |
Gary Wu | 60dd0d8 | 2018-01-18 14:54:47 -0800 | [diff] [blame] | 316 | flavor: { get_param: k8s_vm_flavor } |
gwu | 10db462 | 2018-07-17 22:11:39 -0700 | [diff] [blame] | 317 | key_name: { get_param: key_name } |
Gary Wu | ccd529b | 2018-01-16 18:31:01 -0800 | [diff] [blame] | 318 | networks: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 319 | - port: { get_resource: k8s_01_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 320 | user_data_format: SOFTWARE_CONFIG |
| 321 | user_data: { get_resource: k8s_01_vm_config } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 322 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 323 | k8s_02_private_port: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 324 | type: OS::Neutron::Port |
| 325 | properties: |
| 326 | network: { get_resource: oam_network } |
| 327 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 328 | security_groups: |
| 329 | - { get_resource: onap_sg } |
| 330 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 331 | k8s_02_floating_ip: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 332 | type: OS::Neutron::FloatingIP |
| 333 | properties: |
| 334 | floating_network_id: { get_param: public_net_id } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 335 | port_id: { get_resource: k8s_02_private_port } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 336 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 337 | k8s_02_vm_scripts: |
| 338 | type: OS::Heat::CloudConfig |
| 339 | properties: |
| 340 | cloud_config: |
| 341 | power_state: |
| 342 | mode: reboot |
| 343 | runcmd: |
| 344 | - [ /opt/k8s_vm_install.sh ] |
| 345 | write_files: |
| 346 | - path: /opt/k8s_vm_install.sh |
| 347 | permissions: '0755' |
| 348 | content: |
| 349 | str_replace: |
| 350 | params: |
| 351 | __docker_proxy__: { get_param: docker_proxy } |
| 352 | __apt_proxy__: { get_param: apt_proxy } |
| 353 | __docker_version__: { get_param: docker_version } |
| 354 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 355 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 356 | __host_private_ip_addr__: { get_attr: [k8s_02_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 357 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 358 | template: |
| 359 | get_file: k8s_vm_install.sh |
| 360 | - path: /opt/k8s_vm_init.sh |
| 361 | permissions: '0755' |
| 362 | content: |
| 363 | str_replace: |
| 364 | params: |
| 365 | __host_private_ip_addr__: { get_attr: [k8s_02_floating_ip, fixed_ip_address] } |
| 366 | __host_label__: 'compute' |
| 367 | template: |
| 368 | get_file: k8s_vm_init.sh |
| 369 | - path: /etc/init.d/k8s_vm_init_serv |
| 370 | permissions: '0755' |
| 371 | content: |
| 372 | get_file: k8s_vm_init_serv.sh |
| 373 | |
| 374 | k8s_02_vm_config: |
| 375 | type: OS::Heat::MultipartMime |
| 376 | properties: |
| 377 | parts: |
| 378 | - config: { get_resource: k8s_02_vm_scripts } |
| 379 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 380 | k8s_02_vm: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 381 | type: OS::Nova::Server |
| 382 | properties: |
eHanan | 97b7a9c | 2018-09-05 14:09:19 +0100 | [diff] [blame] | 383 | name: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 384 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s', '02' ] ] |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 385 | image: { get_param: ubuntu_1604_image } |
| 386 | flavor: { get_param: k8s_vm_flavor } |
gwu | 10db462 | 2018-07-17 22:11:39 -0700 | [diff] [blame] | 387 | key_name: { get_param: key_name } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 388 | networks: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 389 | - port: { get_resource: k8s_02_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 390 | user_data_format: SOFTWARE_CONFIG |
| 391 | user_data: { get_resource: k8s_02_vm_config } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 392 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 393 | k8s_03_private_port: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 394 | type: OS::Neutron::Port |
| 395 | properties: |
| 396 | network: { get_resource: oam_network } |
| 397 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 398 | security_groups: |
| 399 | - { get_resource: onap_sg } |
| 400 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 401 | k8s_03_floating_ip: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 402 | type: OS::Neutron::FloatingIP |
| 403 | properties: |
| 404 | floating_network_id: { get_param: public_net_id } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 405 | port_id: { get_resource: k8s_03_private_port } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 406 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 407 | k8s_03_vm_scripts: |
| 408 | type: OS::Heat::CloudConfig |
| 409 | properties: |
| 410 | cloud_config: |
| 411 | power_state: |
| 412 | mode: reboot |
| 413 | runcmd: |
| 414 | - [ /opt/k8s_vm_install.sh ] |
| 415 | write_files: |
| 416 | - path: /opt/k8s_vm_install.sh |
| 417 | permissions: '0755' |
| 418 | content: |
| 419 | str_replace: |
| 420 | params: |
| 421 | __docker_proxy__: { get_param: docker_proxy } |
| 422 | __apt_proxy__: { get_param: apt_proxy } |
| 423 | __docker_version__: { get_param: docker_version } |
| 424 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 425 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 426 | __host_private_ip_addr__: { get_attr: [k8s_03_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 427 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 428 | template: |
| 429 | get_file: k8s_vm_install.sh |
| 430 | - path: /opt/k8s_vm_init.sh |
| 431 | permissions: '0755' |
| 432 | content: |
| 433 | str_replace: |
| 434 | params: |
| 435 | __host_private_ip_addr__: { get_attr: [k8s_03_floating_ip, fixed_ip_address] } |
| 436 | __host_label__: 'compute' |
| 437 | template: |
| 438 | get_file: k8s_vm_init.sh |
| 439 | - path: /etc/init.d/k8s_vm_init_serv |
| 440 | permissions: '0755' |
| 441 | content: |
| 442 | get_file: k8s_vm_init_serv.sh |
| 443 | |
| 444 | k8s_03_vm_config: |
| 445 | type: OS::Heat::MultipartMime |
| 446 | properties: |
| 447 | parts: |
| 448 | - config: { get_resource: k8s_03_vm_scripts } |
| 449 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 450 | k8s_03_vm: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 451 | type: OS::Nova::Server |
| 452 | properties: |
eHanan | 97b7a9c | 2018-09-05 14:09:19 +0100 | [diff] [blame] | 453 | name: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 454 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s', '03' ] ] |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 455 | image: { get_param: ubuntu_1604_image } |
| 456 | flavor: { get_param: k8s_vm_flavor } |
gwu | 10db462 | 2018-07-17 22:11:39 -0700 | [diff] [blame] | 457 | key_name: { get_param: key_name } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 458 | networks: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 459 | - port: { get_resource: k8s_03_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 460 | user_data_format: SOFTWARE_CONFIG |
| 461 | user_data: { get_resource: k8s_03_vm_config } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 462 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 463 | k8s_04_private_port: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 464 | type: OS::Neutron::Port |
| 465 | properties: |
| 466 | network: { get_resource: oam_network } |
| 467 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 468 | security_groups: |
| 469 | - { get_resource: onap_sg } |
| 470 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 471 | k8s_04_floating_ip: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 472 | type: OS::Neutron::FloatingIP |
| 473 | properties: |
| 474 | floating_network_id: { get_param: public_net_id } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 475 | port_id: { get_resource: k8s_04_private_port } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 476 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 477 | k8s_04_vm_scripts: |
| 478 | type: OS::Heat::CloudConfig |
| 479 | properties: |
| 480 | cloud_config: |
| 481 | power_state: |
| 482 | mode: reboot |
| 483 | runcmd: |
| 484 | - [ /opt/k8s_vm_install.sh ] |
| 485 | write_files: |
| 486 | - path: /opt/k8s_vm_install.sh |
| 487 | permissions: '0755' |
| 488 | content: |
| 489 | str_replace: |
| 490 | params: |
| 491 | __docker_proxy__: { get_param: docker_proxy } |
| 492 | __apt_proxy__: { get_param: apt_proxy } |
| 493 | __docker_version__: { get_param: docker_version } |
| 494 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 495 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 496 | __host_private_ip_addr__: { get_attr: [k8s_04_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 497 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 498 | template: |
| 499 | get_file: k8s_vm_install.sh |
| 500 | - path: /opt/k8s_vm_init.sh |
| 501 | permissions: '0755' |
| 502 | content: |
| 503 | str_replace: |
| 504 | params: |
| 505 | __host_private_ip_addr__: { get_attr: [k8s_04_floating_ip, fixed_ip_address] } |
| 506 | __host_label__: 'compute' |
| 507 | template: |
| 508 | get_file: k8s_vm_init.sh |
| 509 | - path: /etc/init.d/k8s_vm_init_serv |
| 510 | permissions: '0755' |
| 511 | content: |
| 512 | get_file: k8s_vm_init_serv.sh |
| 513 | |
| 514 | k8s_04_vm_config: |
| 515 | type: OS::Heat::MultipartMime |
| 516 | properties: |
| 517 | parts: |
| 518 | - config: { get_resource: k8s_04_vm_scripts } |
| 519 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 520 | k8s_04_vm: |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 521 | type: OS::Nova::Server |
| 522 | properties: |
eHanan | 97b7a9c | 2018-09-05 14:09:19 +0100 | [diff] [blame] | 523 | name: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 524 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s', '04' ] ] |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 525 | image: { get_param: ubuntu_1604_image } |
| 526 | flavor: { get_param: k8s_vm_flavor } |
gwu | 10db462 | 2018-07-17 22:11:39 -0700 | [diff] [blame] | 527 | key_name: { get_param: key_name } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 528 | networks: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 529 | - port: { get_resource: k8s_04_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 530 | user_data_format: SOFTWARE_CONFIG |
| 531 | user_data: { get_resource: k8s_04_vm_config } |
Gary Wu | 14a6b30 | 2018-05-01 15:59:28 -0700 | [diff] [blame] | 532 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 533 | k8s_05_private_port: |
Gary Wu | 4d2cfb6 | 2018-09-07 09:05:33 -0700 | [diff] [blame] | 534 | type: OS::Neutron::Port |
| 535 | properties: |
| 536 | network: { get_resource: oam_network } |
| 537 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 538 | security_groups: |
| 539 | - { get_resource: onap_sg } |
| 540 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 541 | k8s_05_floating_ip: |
Gary Wu | 4d2cfb6 | 2018-09-07 09:05:33 -0700 | [diff] [blame] | 542 | type: OS::Neutron::FloatingIP |
| 543 | properties: |
| 544 | floating_network_id: { get_param: public_net_id } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 545 | port_id: { get_resource: k8s_05_private_port } |
Gary Wu | 4d2cfb6 | 2018-09-07 09:05:33 -0700 | [diff] [blame] | 546 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 547 | k8s_05_vm_scripts: |
| 548 | type: OS::Heat::CloudConfig |
| 549 | properties: |
| 550 | cloud_config: |
| 551 | power_state: |
| 552 | mode: reboot |
| 553 | runcmd: |
| 554 | - [ /opt/k8s_vm_install.sh ] |
| 555 | write_files: |
| 556 | - path: /opt/k8s_vm_install.sh |
| 557 | permissions: '0755' |
| 558 | content: |
| 559 | str_replace: |
| 560 | params: |
| 561 | __docker_proxy__: { get_param: docker_proxy } |
| 562 | __apt_proxy__: { get_param: apt_proxy } |
| 563 | __docker_version__: { get_param: docker_version } |
| 564 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 565 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 566 | __host_private_ip_addr__: { get_attr: [k8s_05_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 567 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 568 | template: |
| 569 | get_file: k8s_vm_install.sh |
| 570 | - path: /opt/k8s_vm_init.sh |
| 571 | permissions: '0755' |
| 572 | content: |
| 573 | str_replace: |
| 574 | params: |
| 575 | __host_private_ip_addr__: { get_attr: [k8s_05_floating_ip, fixed_ip_address] } |
| 576 | __host_label__: 'compute' |
| 577 | template: |
| 578 | get_file: k8s_vm_init.sh |
| 579 | - path: /etc/init.d/k8s_vm_init_serv |
| 580 | permissions: '0755' |
| 581 | content: |
| 582 | get_file: k8s_vm_init_serv.sh |
| 583 | |
| 584 | k8s_05_vm_config: |
| 585 | type: OS::Heat::MultipartMime |
| 586 | properties: |
| 587 | parts: |
| 588 | - config: { get_resource: k8s_05_vm_scripts } |
| 589 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 590 | k8s_05_vm: |
Gary Wu | 4d2cfb6 | 2018-09-07 09:05:33 -0700 | [diff] [blame] | 591 | type: OS::Nova::Server |
| 592 | properties: |
eHanan | 97b7a9c | 2018-09-05 14:09:19 +0100 | [diff] [blame] | 593 | name: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 594 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s', '05' ] ] |
Gary Wu | 4d2cfb6 | 2018-09-07 09:05:33 -0700 | [diff] [blame] | 595 | image: { get_param: ubuntu_1604_image } |
| 596 | flavor: { get_param: k8s_vm_flavor } |
| 597 | key_name: { get_param: key_name } |
| 598 | networks: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 599 | - port: { get_resource: k8s_05_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 600 | user_data_format: SOFTWARE_CONFIG |
| 601 | user_data: { get_resource: k8s_05_vm_config } |
Gary Wu | 4d2cfb6 | 2018-09-07 09:05:33 -0700 | [diff] [blame] | 602 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 603 | k8s_06_private_port: |
Gary Wu | 0bf673e | 2018-09-18 08:24:33 -0700 | [diff] [blame] | 604 | type: OS::Neutron::Port |
| 605 | properties: |
| 606 | network: { get_resource: oam_network } |
| 607 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 608 | security_groups: |
| 609 | - { get_resource: onap_sg } |
| 610 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 611 | k8s_06_floating_ip: |
Gary Wu | 0bf673e | 2018-09-18 08:24:33 -0700 | [diff] [blame] | 612 | type: OS::Neutron::FloatingIP |
| 613 | properties: |
| 614 | floating_network_id: { get_param: public_net_id } |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 615 | port_id: { get_resource: k8s_06_private_port } |
Gary Wu | 0bf673e | 2018-09-18 08:24:33 -0700 | [diff] [blame] | 616 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 617 | k8s_06_vm_scripts: |
| 618 | type: OS::Heat::CloudConfig |
| 619 | properties: |
| 620 | cloud_config: |
| 621 | power_state: |
| 622 | mode: reboot |
| 623 | runcmd: |
| 624 | - [ /opt/k8s_vm_install.sh ] |
| 625 | write_files: |
| 626 | - path: /opt/k8s_vm_install.sh |
| 627 | permissions: '0755' |
| 628 | content: |
| 629 | str_replace: |
| 630 | params: |
| 631 | __docker_proxy__: { get_param: docker_proxy } |
| 632 | __apt_proxy__: { get_param: apt_proxy } |
| 633 | __docker_version__: { get_param: docker_version } |
| 634 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 635 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 636 | __host_private_ip_addr__: { get_attr: [k8s_06_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 637 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 638 | template: |
| 639 | get_file: k8s_vm_install.sh |
| 640 | - path: /opt/k8s_vm_init.sh |
| 641 | permissions: '0755' |
| 642 | content: |
| 643 | str_replace: |
| 644 | params: |
| 645 | __host_private_ip_addr__: { get_attr: [k8s_06_floating_ip, fixed_ip_address] } |
| 646 | __host_label__: 'compute' |
| 647 | template: |
| 648 | get_file: k8s_vm_init.sh |
| 649 | - path: /etc/init.d/k8s_vm_init_serv |
| 650 | permissions: '0755' |
| 651 | content: |
| 652 | get_file: k8s_vm_init_serv.sh |
| 653 | |
| 654 | k8s_06_vm_config: |
| 655 | type: OS::Heat::MultipartMime |
| 656 | properties: |
| 657 | parts: |
| 658 | - config: { get_resource: k8s_06_vm_scripts } |
| 659 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 660 | k8s_06_vm: |
Gary Wu | 0bf673e | 2018-09-18 08:24:33 -0700 | [diff] [blame] | 661 | type: OS::Nova::Server |
| 662 | properties: |
| 663 | name: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 664 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'k8s', '06' ] ] |
Gary Wu | 0bf673e | 2018-09-18 08:24:33 -0700 | [diff] [blame] | 665 | image: { get_param: ubuntu_1604_image } |
| 666 | flavor: { get_param: k8s_vm_flavor } |
| 667 | key_name: { get_param: key_name } |
| 668 | networks: |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 669 | - port: { get_resource: k8s_06_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 670 | user_data_format: SOFTWARE_CONFIG |
| 671 | user_data: { get_resource: k8s_06_vm_config } |
Gary Wu | 0bf673e | 2018-09-18 08:24:33 -0700 | [diff] [blame] | 672 | |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 673 | etcd_1_private_port: |
Gary Wu | 61db1be | 2018-09-25 08:12:33 -0700 | [diff] [blame] | 674 | type: OS::Neutron::Port |
| 675 | properties: |
| 676 | network: { get_resource: oam_network } |
| 677 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 678 | security_groups: |
| 679 | - { get_resource: onap_sg } |
| 680 | |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 681 | etcd_1_floating_ip: |
Gary Wu | 61db1be | 2018-09-25 08:12:33 -0700 | [diff] [blame] | 682 | type: OS::Neutron::FloatingIP |
| 683 | properties: |
| 684 | floating_network_id: { get_param: public_net_id } |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 685 | port_id: { get_resource: etcd_1_private_port } |
Gary Wu | 61db1be | 2018-09-25 08:12:33 -0700 | [diff] [blame] | 686 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 687 | etcd_1_vm_scripts: |
| 688 | type: OS::Heat::CloudConfig |
| 689 | properties: |
| 690 | cloud_config: |
| 691 | power_state: |
| 692 | mode: reboot |
| 693 | runcmd: |
| 694 | - [ /opt/k8s_vm_install.sh ] |
| 695 | write_files: |
| 696 | - path: /opt/k8s_vm_install.sh |
| 697 | permissions: '0755' |
| 698 | content: |
| 699 | str_replace: |
| 700 | params: |
| 701 | __docker_proxy__: { get_param: docker_proxy } |
| 702 | __apt_proxy__: { get_param: apt_proxy } |
| 703 | __docker_version__: { get_param: docker_version } |
| 704 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 705 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 706 | __host_private_ip_addr__: { get_attr: [etcd_1_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 707 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 708 | template: |
| 709 | get_file: k8s_vm_install.sh |
| 710 | - path: /opt/k8s_vm_init.sh |
| 711 | permissions: '0755' |
| 712 | content: |
| 713 | str_replace: |
| 714 | params: |
| 715 | __host_private_ip_addr__: { get_attr: [etcd_1_floating_ip, fixed_ip_address] } |
| 716 | __host_label__: 'etcd' |
| 717 | template: |
| 718 | get_file: k8s_vm_init.sh |
| 719 | - path: /etc/init.d/k8s_vm_init_serv |
| 720 | permissions: '0755' |
| 721 | content: |
| 722 | get_file: k8s_vm_init_serv.sh |
| 723 | |
| 724 | etcd_1_vm_config: |
| 725 | type: OS::Heat::MultipartMime |
| 726 | properties: |
| 727 | parts: |
| 728 | - config: { get_resource: etcd_1_vm_scripts } |
| 729 | |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 730 | etcd_1_vm: |
Gary Wu | 61db1be | 2018-09-25 08:12:33 -0700 | [diff] [blame] | 731 | type: OS::Nova::Server |
| 732 | properties: |
| 733 | name: |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 734 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'etcd', '1' ] ] |
Gary Wu | 61db1be | 2018-09-25 08:12:33 -0700 | [diff] [blame] | 735 | image: { get_param: ubuntu_1604_image } |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 736 | flavor: { get_param: etcd_vm_flavor } |
Gary Wu | 61db1be | 2018-09-25 08:12:33 -0700 | [diff] [blame] | 737 | key_name: { get_param: key_name } |
| 738 | networks: |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 739 | - port: { get_resource: etcd_1_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 740 | user_data_format: SOFTWARE_CONFIG |
| 741 | user_data: { get_resource: etcd_1_vm_config } |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 742 | |
| 743 | etcd_2_private_port: |
| 744 | type: OS::Neutron::Port |
| 745 | properties: |
| 746 | network: { get_resource: oam_network } |
| 747 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 748 | security_groups: |
| 749 | - { get_resource: onap_sg } |
| 750 | |
| 751 | etcd_2_floating_ip: |
| 752 | type: OS::Neutron::FloatingIP |
| 753 | properties: |
| 754 | floating_network_id: { get_param: public_net_id } |
| 755 | port_id: { get_resource: etcd_2_private_port } |
| 756 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 757 | etcd_2_vm_scripts: |
| 758 | type: OS::Heat::CloudConfig |
| 759 | properties: |
| 760 | cloud_config: |
| 761 | power_state: |
| 762 | mode: reboot |
| 763 | runcmd: |
| 764 | - [ /opt/k8s_vm_install.sh ] |
| 765 | write_files: |
| 766 | - path: /opt/k8s_vm_install.sh |
| 767 | permissions: '0755' |
| 768 | content: |
| 769 | str_replace: |
| 770 | params: |
| 771 | __docker_proxy__: { get_param: docker_proxy } |
| 772 | __apt_proxy__: { get_param: apt_proxy } |
| 773 | __docker_version__: { get_param: docker_version } |
| 774 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 775 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 776 | __host_private_ip_addr__: { get_attr: [etcd_2_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 777 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 778 | template: |
| 779 | get_file: k8s_vm_install.sh |
| 780 | - path: /opt/k8s_vm_init.sh |
| 781 | permissions: '0755' |
| 782 | content: |
| 783 | str_replace: |
| 784 | params: |
| 785 | __host_private_ip_addr__: { get_attr: [etcd_2_floating_ip, fixed_ip_address] } |
| 786 | __host_label__: 'etcd' |
| 787 | template: |
| 788 | get_file: k8s_vm_init.sh |
| 789 | - path: /etc/init.d/k8s_vm_init_serv |
| 790 | permissions: '0755' |
| 791 | content: |
| 792 | get_file: k8s_vm_init_serv.sh |
| 793 | |
| 794 | etcd_2_vm_config: |
| 795 | type: OS::Heat::MultipartMime |
| 796 | properties: |
| 797 | parts: |
| 798 | - config: { get_resource: etcd_2_vm_scripts } |
| 799 | |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 800 | etcd_2_vm: |
| 801 | type: OS::Nova::Server |
| 802 | properties: |
| 803 | name: |
| 804 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'etcd', '2' ] ] |
| 805 | image: { get_param: ubuntu_1604_image } |
| 806 | flavor: { get_param: etcd_vm_flavor } |
| 807 | key_name: { get_param: key_name } |
| 808 | networks: |
| 809 | - port: { get_resource: etcd_2_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 810 | user_data_format: SOFTWARE_CONFIG |
| 811 | user_data: { get_resource: etcd_2_vm_config } |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 812 | |
| 813 | etcd_3_private_port: |
| 814 | type: OS::Neutron::Port |
| 815 | properties: |
| 816 | network: { get_resource: oam_network } |
| 817 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 818 | security_groups: |
| 819 | - { get_resource: onap_sg } |
| 820 | |
| 821 | etcd_3_floating_ip: |
| 822 | type: OS::Neutron::FloatingIP |
| 823 | properties: |
| 824 | floating_network_id: { get_param: public_net_id } |
| 825 | port_id: { get_resource: etcd_3_private_port } |
| 826 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 827 | etcd_3_vm_scripts: |
| 828 | type: OS::Heat::CloudConfig |
| 829 | properties: |
| 830 | cloud_config: |
| 831 | power_state: |
| 832 | mode: reboot |
| 833 | runcmd: |
| 834 | - [ /opt/k8s_vm_install.sh ] |
| 835 | write_files: |
| 836 | - path: /opt/k8s_vm_install.sh |
| 837 | permissions: '0755' |
| 838 | content: |
| 839 | str_replace: |
| 840 | params: |
| 841 | __docker_proxy__: { get_param: docker_proxy } |
| 842 | __apt_proxy__: { get_param: apt_proxy } |
| 843 | __docker_version__: { get_param: docker_version } |
| 844 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 845 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 846 | __host_private_ip_addr__: { get_attr: [etcd_3_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 847 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 848 | template: |
| 849 | get_file: k8s_vm_install.sh |
| 850 | - path: /opt/k8s_vm_init.sh |
| 851 | permissions: '0755' |
| 852 | content: |
| 853 | str_replace: |
| 854 | params: |
| 855 | __host_private_ip_addr__: { get_attr: [etcd_3_floating_ip, fixed_ip_address] } |
| 856 | __host_label__: 'etcd' |
| 857 | template: |
| 858 | get_file: k8s_vm_init.sh |
| 859 | - path: /etc/init.d/k8s_vm_init_serv |
| 860 | permissions: '0755' |
| 861 | content: |
| 862 | get_file: k8s_vm_init_serv.sh |
| 863 | |
| 864 | etcd_3_vm_config: |
| 865 | type: OS::Heat::MultipartMime |
| 866 | properties: |
| 867 | parts: |
| 868 | - config: { get_resource: etcd_3_vm_scripts } |
| 869 | |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 870 | etcd_3_vm: |
| 871 | type: OS::Nova::Server |
| 872 | properties: |
| 873 | name: |
| 874 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'etcd', '3' ] ] |
| 875 | image: { get_param: ubuntu_1604_image } |
| 876 | flavor: { get_param: etcd_vm_flavor } |
| 877 | key_name: { get_param: key_name } |
| 878 | networks: |
| 879 | - port: { get_resource: etcd_3_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 880 | user_data_format: SOFTWARE_CONFIG |
| 881 | user_data: { get_resource: etcd_3_vm_config } |
Gary Wu | 3fd6c2a | 2018-10-28 21:44:00 -0700 | [diff] [blame] | 882 | |
Gary Wu | 89f6723 | 2018-11-01 13:45:31 -0700 | [diff] [blame] | 883 | orch_1_private_port: |
| 884 | type: OS::Neutron::Port |
| 885 | properties: |
| 886 | network: { get_resource: oam_network } |
| 887 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 888 | security_groups: |
| 889 | - { get_resource: onap_sg } |
| 890 | |
| 891 | orch_1_floating_ip: |
| 892 | type: OS::Neutron::FloatingIP |
| 893 | properties: |
| 894 | floating_network_id: { get_param: public_net_id } |
| 895 | port_id: { get_resource: orch_1_private_port } |
| 896 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 897 | orch_1_vm_scripts: |
| 898 | type: OS::Heat::CloudConfig |
| 899 | properties: |
| 900 | cloud_config: |
| 901 | power_state: |
| 902 | mode: reboot |
| 903 | runcmd: |
| 904 | - [ /opt/k8s_vm_install.sh ] |
| 905 | write_files: |
| 906 | - path: /opt/k8s_vm_install.sh |
| 907 | permissions: '0755' |
| 908 | content: |
| 909 | str_replace: |
| 910 | params: |
| 911 | __docker_proxy__: { get_param: docker_proxy } |
| 912 | __apt_proxy__: { get_param: apt_proxy } |
| 913 | __docker_version__: { get_param: docker_version } |
| 914 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 915 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 916 | __host_private_ip_addr__: { get_attr: [orch_1_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 917 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 918 | template: |
| 919 | get_file: k8s_vm_install.sh |
| 920 | - path: /opt/k8s_vm_init.sh |
| 921 | permissions: '0755' |
| 922 | content: |
| 923 | str_replace: |
| 924 | params: |
| 925 | __host_private_ip_addr__: { get_attr: [orch_1_floating_ip, fixed_ip_address] } |
| 926 | __host_label__: 'orchestration' |
| 927 | template: |
| 928 | get_file: k8s_vm_init.sh |
| 929 | - path: /etc/init.d/k8s_vm_init_serv |
| 930 | permissions: '0755' |
| 931 | content: |
| 932 | get_file: k8s_vm_init_serv.sh |
| 933 | |
| 934 | orch_1_vm_config: |
| 935 | type: OS::Heat::MultipartMime |
| 936 | properties: |
| 937 | parts: |
| 938 | - config: { get_resource: orch_1_vm_scripts } |
| 939 | |
Gary Wu | 89f6723 | 2018-11-01 13:45:31 -0700 | [diff] [blame] | 940 | orch_1_vm: |
| 941 | type: OS::Nova::Server |
| 942 | properties: |
| 943 | name: |
| 944 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'orch', '1' ] ] |
| 945 | image: { get_param: ubuntu_1604_image } |
| 946 | flavor: { get_param: orch_vm_flavor } |
| 947 | key_name: { get_param: key_name } |
| 948 | networks: |
| 949 | - port: { get_resource: orch_1_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 950 | user_data_format: SOFTWARE_CONFIG |
| 951 | user_data: { get_resource: orch_1_vm_config } |
Gary Wu | 89f6723 | 2018-11-01 13:45:31 -0700 | [diff] [blame] | 952 | |
Gary Wu | 6e66201 | 2018-11-13 18:41:45 -0800 | [diff] [blame] | 953 | orch_2_private_port: |
| 954 | type: OS::Neutron::Port |
| 955 | properties: |
| 956 | network: { get_resource: oam_network } |
| 957 | fixed_ips: [{"subnet": { get_resource: oam_subnet }}] |
| 958 | security_groups: |
| 959 | - { get_resource: onap_sg } |
| 960 | |
| 961 | orch_2_floating_ip: |
| 962 | type: OS::Neutron::FloatingIP |
| 963 | properties: |
| 964 | floating_network_id: { get_param: public_net_id } |
| 965 | port_id: { get_resource: orch_2_private_port } |
| 966 | |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 967 | orch_2_vm_scripts: |
| 968 | type: OS::Heat::CloudConfig |
| 969 | properties: |
| 970 | cloud_config: |
| 971 | power_state: |
| 972 | mode: reboot |
| 973 | runcmd: |
| 974 | - [ /opt/k8s_vm_install.sh ] |
| 975 | write_files: |
| 976 | - path: /opt/k8s_vm_install.sh |
| 977 | permissions: '0755' |
| 978 | content: |
| 979 | str_replace: |
| 980 | params: |
| 981 | __docker_proxy__: { get_param: docker_proxy } |
| 982 | __apt_proxy__: { get_param: apt_proxy } |
| 983 | __docker_version__: { get_param: docker_version } |
| 984 | __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] } |
| 985 | __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] } |
| 986 | __host_private_ip_addr__: { get_attr: [orch_2_floating_ip, fixed_ip_address] } |
Gary Wu | b8be70a | 2018-11-17 17:14:38 -0800 | [diff] [blame] | 987 | __mtu__: { get_param: mtu } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 988 | template: |
| 989 | get_file: k8s_vm_install.sh |
| 990 | - path: /opt/k8s_vm_init.sh |
| 991 | permissions: '0755' |
| 992 | content: |
| 993 | str_replace: |
| 994 | params: |
| 995 | __host_private_ip_addr__: { get_attr: [orch_2_floating_ip, fixed_ip_address] } |
| 996 | __host_label__: 'orchestration' |
| 997 | template: |
| 998 | get_file: k8s_vm_init.sh |
| 999 | - path: /etc/init.d/k8s_vm_init_serv |
| 1000 | permissions: '0755' |
| 1001 | content: |
| 1002 | get_file: k8s_vm_init_serv.sh |
| 1003 | |
| 1004 | orch_2_vm_config: |
| 1005 | type: OS::Heat::MultipartMime |
| 1006 | properties: |
| 1007 | parts: |
| 1008 | - config: { get_resource: orch_2_vm_scripts } |
| 1009 | |
Gary Wu | 6e66201 | 2018-11-13 18:41:45 -0800 | [diff] [blame] | 1010 | orch_2_vm: |
| 1011 | type: OS::Nova::Server |
| 1012 | properties: |
| 1013 | name: |
| 1014 | list_join: ['-', [ { get_param: 'OS::stack_name' }, 'orch', '2' ] ] |
| 1015 | image: { get_param: ubuntu_1604_image } |
| 1016 | flavor: { get_param: orch_vm_flavor } |
| 1017 | key_name: { get_param: key_name } |
| 1018 | networks: |
| 1019 | - port: { get_resource: orch_2_private_port } |
Gary Wu | b718998 | 2018-11-14 10:01:37 -0800 | [diff] [blame] | 1020 | user_data_format: SOFTWARE_CONFIG |
| 1021 | user_data: { get_resource: orch_2_vm_config } |
Gary Wu | 6e66201 | 2018-11-13 18:41:45 -0800 | [diff] [blame] | 1022 | |
Gary Wu | 14ee41d | 2018-01-19 15:03:59 -0800 | [diff] [blame] | 1023 | outputs: |
Gary Wu | 6103408 | 2018-01-22 12:48:50 -0800 | [diff] [blame] | 1024 | rancher_vm_ip: |
| 1025 | description: The IP address of the rancher instance |
Gary Wu | 5d325d0 | 2018-02-06 21:21:31 -0800 | [diff] [blame] | 1026 | value: { get_attr: [rancher_floating_ip, floating_ip_address] } |
Gary Wu | 6103408 | 2018-01-22 12:48:50 -0800 | [diff] [blame] | 1027 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 1028 | k8s_01_vm_ip: |
| 1029 | description: The IP address of the k8s_01 instance |
| 1030 | value: { get_attr: [k8s_01_floating_ip, floating_ip_address] } |
Gary Wu | 36e42dd | 2018-05-03 07:29:53 -0700 | [diff] [blame] | 1031 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 1032 | k8s_02_vm_ip: |
| 1033 | description: The IP address of the k8s_02 instance |
| 1034 | value: { get_attr: [k8s_02_floating_ip, floating_ip_address] } |
Gary Wu | 36e42dd | 2018-05-03 07:29:53 -0700 | [diff] [blame] | 1035 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 1036 | k8s_03_vm_ip: |
| 1037 | description: The IP address of the k8s_03 instance |
| 1038 | value: { get_attr: [k8s_03_floating_ip, floating_ip_address] } |
Gary Wu | 36e42dd | 2018-05-03 07:29:53 -0700 | [diff] [blame] | 1039 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 1040 | k8s_04_vm_ip: |
| 1041 | description: The IP address of the k8s_04 instance |
| 1042 | value: { get_attr: [k8s_04_floating_ip, floating_ip_address] } |
Gary Wu | 36e42dd | 2018-05-03 07:29:53 -0700 | [diff] [blame] | 1043 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 1044 | k8s_05_vm_ip: |
| 1045 | description: The IP address of the k8s_05 instance |
| 1046 | value: { get_attr: [k8s_05_floating_ip, floating_ip_address] } |
Gary Wu | 4d2cfb6 | 2018-09-07 09:05:33 -0700 | [diff] [blame] | 1047 | |
Gary Wu | 48a3294 | 2018-11-08 07:34:49 -0800 | [diff] [blame] | 1048 | k8s_06_vm_ip: |
| 1049 | description: The IP address of the k8s_06 instance |
| 1050 | value: { get_attr: [k8s_06_floating_ip, floating_ip_address] } |
Gary Wu | 0bf673e | 2018-09-18 08:24:33 -0700 | [diff] [blame] | 1051 | |