summaryrefslogtreecommitdiffstats
path: root/heat/ONAP/onap_openstack_float.yaml
diff options
context:
space:
mode:
authorMarco Platania <platania@research.att.com>2017-08-29 10:38:08 -0400
committerMarco Platania <platania@research.att.com>2017-08-29 10:38:08 -0400
commit569b54f0659cc790c0c9c2eec3a72884b6162626 (patch)
tree4e6c0e3d935c6dd0bfa956c366a6834c4373175c /heat/ONAP/onap_openstack_float.yaml
parent0c1136ad3537b872565bb622df7e7167f6365f4a (diff)
Add CLAMP VM to ONAP
- Extend Heat templates with CLAMP resources definition - Create installation scripts for CLAMP - Update DNS configuration Change-Id: I1db7f884f8318eceb74dace972f8ad808ac8551d Issue-ID: INT-115 Signed-off-by: Marco Platania <platania@research.att.com>
Diffstat (limited to 'heat/ONAP/onap_openstack_float.yaml')
-rw-r--r--heat/ONAP/onap_openstack_float.yaml94
1 files changed, 93 insertions, 1 deletions
diff --git a/heat/ONAP/onap_openstack_float.yaml b/heat/ONAP/onap_openstack_float.yaml
index bc15fa7f..74e24e46 100644
--- a/heat/ONAP/onap_openstack_float.yaml
+++ b/heat/ONAP/onap_openstack_float.yaml
@@ -236,6 +236,10 @@ parameters:
type: string
description: VID Floating IP Address
+ clamp_float_ip:
+ type: string
+ description: CLAMP Floating IP Address
+
### Private IP addresses ###
oam_network_cidr:
type: string
@@ -313,6 +317,10 @@ parameters:
type: string
description: VID IP Address
+ clamp_ip_addr:
+ type: string
+ description: CLAMP IP Address
+
###########################
# #
@@ -402,6 +410,10 @@ parameters:
type: string
description: VID repository
+ clamp_repo:
+ type: string
+ description: CLAMP repository
+
#############
# #
@@ -516,6 +528,7 @@ resources:
__sdc_ip_addr__: { get_param: sdc_ip_addr }
__sdnc_ip_addr__: { get_param: sdnc_ip_addr }
__vid_ip_addr__: { get_param: vid_ip_addr }
+ __clamp_ip_addr__: { get_param: clamp_ip_addr }
__cloud_env__: { get_param: cloud_env }
__external_dns__: { get_param: external_dns }
template: |
@@ -541,6 +554,7 @@ resources:
echo "__sdc_ip_addr__" > /opt/config/sdc_ip_addr.txt
echo "__sdnc_ip_addr__" > /opt/config/sdnc_ip_addr.txt
echo "__vid_ip_addr__" > /opt/config/vid_ip_addr.txt
+ echo "__clamp_ip_addr__" > /opt/config/clamp_ip_addr.txt
echo "__external_dns__" > /opt/config/external_dns.txt
# Download and run install script
@@ -1488,4 +1502,82 @@ resources:
curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/appc_install.sh -o /opt/appc_install.sh
cd /opt
chmod +x appc_install.sh
- ./appc_install.sh \ No newline at end of file
+ ./appc_install.sh
+
+
+ # CLAMP instantiation
+ clamp_private_port:
+ type: OS::Neutron::Port
+ properties:
+ network: { get_resource: oam_onap }
+ fixed_ips: [{"subnet": { get_resource: oam_onap_subnet }, "ip_address": { get_param: clamp_ip_addr }}]
+
+ clamp_floating_ip:
+ type: OS::Neutron::FloatingIP
+ properties:
+ floating_network_id: { get_param: public_net_id }
+ port_id: { get_resource: clamp_private_port }
+ floating_ip_address: { get_param: clamp_float_ip }
+
+ clamp_vm:
+ type: OS::Nova::Server
+ properties:
+ image: { get_param: ubuntu_1604_image }
+ flavor: { get_param: flavor_medium }
+ name:
+ str_replace:
+ template: base-clamp
+ params:
+ base: { get_param: vm_base_name }
+ key_name: { get_resource: vm_key }
+ networks:
+ - port: { get_resource: clamp_private_port }
+ user_data_format: RAW
+ user_data:
+ str_replace:
+ params:
+ __nexus_repo__: { get_param: nexus_repo }
+ __nexus_docker_repo__: { get_param: nexus_docker_repo }
+ __nexus_username__: { get_param: nexus_username }
+ __nexus_password__: { get_param: nexus_password }
+ __openstack_username__: { get_param: openstack_username }
+ __openstack_tenant_id__: { get_param: openstack_tenant_id }
+ __openstack_api_key__: { get_param: openstack_api_key }
+ __openstack_region__: { get_param: openstack_region }
+ __keystone_url__: { get_param: keystone_url }
+ __dmaap_topic__: { get_param: dmaap_topic }
+ __artifacts_version__: { get_param: artifacts_version }
+ __dns_ip_addr__: { get_param: dns_ip_addr }
+ __docker_version__: { get_param: docker_version }
+ __gerrit_branch__: { get_param: gerrit_branch }
+ __cloud_env__: { get_param: cloud_env }
+ __external_dns__: { get_param: external_dns }
+ __clamp_repo__: { get_param: clamp_repo }
+ template: |
+ #!/bin/bash
+
+ # Create configuration files
+ mkdir -p /opt/config
+ echo "__nexus_repo__" > /opt/config/nexus_repo.txt
+ echo "__nexus_docker_repo__" > /opt/config/nexus_docker_repo.txt
+ echo "__nexus_username__" > /opt/config/nexus_username.txt
+ echo "__nexus_password__" > /opt/config/nexus_password.txt
+ echo "__artifacts_version__" > /opt/config/artifacts_version.txt
+ echo "__dns_ip_addr__" > /opt/config/dns_ip_addr.txt
+ echo "__dmaap_topic__" > /opt/config/dmaap_topic.txt
+ echo "__openstack_username__" > /opt/config/openstack_username.txt
+ echo "__openstack_tenant_id__" > /opt/config/tenant_id.txt
+ echo "__openstack_api_key__" > /opt/config/openstack_api_key.txt
+ echo "__openstack_region__" > /opt/config/openstack_region.txt
+ echo "__keystone_url__" > /opt/config/keystone.txt
+ echo "__docker_version__" > /opt/config/docker_version.txt
+ echo "__gerrit_branch__" > /opt/config/gerrit_branch.txt
+ echo "__cloud_env__" > /opt/config/cloud_env.txt
+ echo "__external_dns__" > /opt/config/external_dns.txt
+ echo "__clamp_repo__" > /opt/config/remote_repo.txt
+
+ # Download and run install script
+ curl -k __nexus_repo__/org.onap.demo/boot/__artifacts_version__/clamp_install.sh -o /opt/clamp_install.sh
+ cd /opt
+ chmod +x clamp_install.sh
+ ./clamp_install.sh \ No newline at end of file