blob: ff2272d920db98556bbd1fef7a7ec5f922493037 [file] [log] [blame]
Gary Wu3fd6c2a2018-10-28 21:44:00 -07001 ${VM_TYPE}_${VM_NUM}_private_port:
Gary Wu14a6b302018-05-01 15:59:28 -07002 type: OS::Neutron::Port
3 properties:
4 network: { get_resource: oam_network }
5 fixed_ips: [{"subnet": { get_resource: oam_subnet }}]
6 security_groups:
7 - { get_resource: onap_sg }
8
Gary Wu3fd6c2a2018-10-28 21:44:00 -07009 ${VM_TYPE}_${VM_NUM}_floating_ip:
Gary Wu14a6b302018-05-01 15:59:28 -070010 type: OS::Neutron::FloatingIP
11 properties:
12 floating_network_id: { get_param: public_net_id }
Gary Wu3fd6c2a2018-10-28 21:44:00 -070013 port_id: { get_resource: ${VM_TYPE}_${VM_NUM}_private_port }
Gary Wu14a6b302018-05-01 15:59:28 -070014
Gary Wu3fd6c2a2018-10-28 21:44:00 -070015 ${VM_TYPE}_${VM_NUM}_vm:
Gary Wu14a6b302018-05-01 15:59:28 -070016 type: OS::Nova::Server
17 properties:
eHanan97b7a9c2018-09-05 14:09:19 +010018 name:
Gary Wu3fd6c2a2018-10-28 21:44:00 -070019 list_join: ['-', [ { get_param: 'OS::stack_name' }, '${VM_TYPE}', '${VM_NUM}' ] ]
Gary Wu14a6b302018-05-01 15:59:28 -070020 image: { get_param: ubuntu_1604_image }
Gary Wu3fd6c2a2018-10-28 21:44:00 -070021 flavor: { get_param: ${VM_TYPE}_vm_flavor }
gwu10db4622018-07-17 22:11:39 -070022 key_name: { get_param: key_name }
Gary Wu14a6b302018-05-01 15:59:28 -070023 networks:
Gary Wu3fd6c2a2018-10-28 21:44:00 -070024 - port: { get_resource: ${VM_TYPE}_${VM_NUM}_private_port }
Gary Wu14a6b302018-05-01 15:59:28 -070025 user_data_format: RAW
26 user_data:
27 str_replace:
28 params:
Gary Wu14a6b302018-05-01 15:59:28 -070029 __docker_proxy__: { get_param: docker_proxy }
30 __apt_proxy__: { get_param: apt_proxy }
Gary Wu7a04b3d2018-08-15 12:31:46 -070031 __docker_version__: { get_param: docker_version }
Gary Wu14a6b302018-05-01 15:59:28 -070032 __rancher_ip_addr__: { get_attr: [rancher_floating_ip, floating_ip_address] }
Gary Wuad513722018-07-26 13:08:47 -070033 __rancher_private_ip_addr__: { get_attr: [rancher_floating_ip, fixed_ip_address] }
Gary Wu3fd6c2a2018-10-28 21:44:00 -070034 __host_label__: '$HOST_LABEL'
Gary Wu14a6b302018-05-01 15:59:28 -070035 template:
36 get_file: k8s_vm_entrypoint.sh
37