From f5f13c4f6b6fe3b4d98e349dfd7db59339803436 Mon Sep 17 00:00:00 2001 From: Michael Lando Date: Sun, 19 Feb 2017 12:35:04 +0200 Subject: push addional code Change-Id: Ia427bb3460cda3a896f8faced2de69eaf3807b74 Signed-off-by: Michael Lando --- .../resourceGroupMDNS/inputs/dns_nested_01.yaml | 127 +++++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100644 openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml (limited to 'openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml') diff --git a/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml new file mode 100644 index 0000000000..5be9d49bb0 --- /dev/null +++ b/openecomp-be/lib/openecomp-sdc-translator-lib/openecomp-sdc-translator-core/src/test/resources/mock/heat/nested/resourceGroupMDNS/inputs/dns_nested_01.yaml @@ -0,0 +1,127 @@ +heat_template_version: 2014-10-16 + +description: | + nested DNS template for a single VM + all parameters are passed from calling heat template of resourcegroup + +parameters: + dns_image_name: + type: string + description: server image + dns_flavor_name: + type: string + description: server flavor + dns_key: + type: string + description: server key + oam_protected_net_name: + type: string + description: OAM network where instaces will connect + int_bearer_net_name: + type: string + description: Bearer network where instaces will connect + dns_oam_protected_ips: + type: comma_delimited_list + description: DNS OAM IP list + dns_int_bearer_ips: + type: comma_delimited_list + description: DNS Bearer IP list + dns_int_bearer_ipv6_ips: + type: comma_delimited_list + description: fixed IPv6 assignment for VM's on the Bearer network + dns_names: + type: comma_delimited_list + description: server name + route_eth0: + type: string + description: OAM network routes + index: + type: number + description: index parameter + name_with_index: + type: string + description: name parameter which will include the index value + security_group: + type: string + description: security group + availability_zone_0: + type: string + description: availability zone ID or Name +# this parameter does not follow the D2 Guidelines. This value will be az0 or az1. + vnf_name: + type: string + description: Unique name for this VF instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + vnf_id: + type: string + description: Unique ID for this VF instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + vf_module_id: + type: string + description: Unique ID for this VF module instance +# For manual spinups, value must be in the ENV file. Must be removed from ENV before uploading to ASDC + + +resources: + + dns_oam_protected_0_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: VNF_NAME_dns_oam_port + params: + VNF_NAME: {get_param: vnf_name} + network: { get_param: oam_protected_net_name } + fixed_ips: [{ "ip_address": { get_param: [ dns_oam_protected_ips, get_param: index ]}}] + security_groups: [{ get_param: security_group }] + + dns_int_bearer_0_port: + type: OS::Neutron::Port + properties: + name: + str_replace: + template: VNF_NAME_dns_bearer_port + params: + VNF_NAME: {get_param: vnf_name} + network: { get_param: int_bearer_net_name } + fixed_ips: [{ "ip_address": { get_param: [ dns_int_bearer_ips, get_param: index ]}}, { "ip_address": { get_param: [ dns_int_bearer_ipv6_ips, get_param: index ]}}] + security_groups: [{ get_param: security_group }] + + dns_servers: + type: OS::Nova::Server + properties: + name: { get_param: [ dns_names, get_param: index ] } + image: { get_param: dns_image_name } + flavor: { get_param: dns_flavor_name } + key_name: { get_param: dns_key } + availability_zone: { get_param: availability_zone_0 } + networks: + - port: { get_resource: dns_oam_protected_0_port } + - port: { get_resource: dns_int_bearer_0_port } + metadata: + vnf_id: { get_param: vnf_id } + vf_module_id: { get_param: vf_module_id } + vnf_name {get_param: vnf_name } + user_data_format: RAW + user_data: { get_resource: server_interface_config } + + server_interface_config: + type: OS::Heat::CloudConfig + properties: + cloud_config: + write_files: + - path: /etc/sysconfig/network-scripts/route-eth0 + permissions: "0644" +# content: { get_file: route-eth0 } + content: { get_param: route_eth0 } + +#outputs: +# vm_name: +# description: VM name +# value: { get_attr: [ dns_servers, name] } +# networks: +# description: networks +# value: { get_attr: [ dns_servers, networks ] } + + -- cgit 1.2.3-korg