Pass sec_group parameter to robot helm charts

Change-Id: I0e683928f6cae55c34b96ed851433e04dc0f57b6
Issue-ID: INT-586
Signed-off-by: Gary Wu <gary.i.wu@huawei.com>
diff --git a/deployment/heat/onap-oom/env/windriver/onap-oom.env b/deployment/heat/onap-oom/env/windriver/onap-oom.env
index 8f7322f..284bcc2 100644
--- a/deployment/heat/onap-oom/env/windriver/onap-oom.env
+++ b/deployment/heat/onap-oom/env/windriver/onap-oom.env
@@ -26,6 +26,7 @@
       openStackPrivateNetId: "__oam_network_id__"
       openStackPrivateSubnetId: "__oam_subnet_id__"
       openStackPrivateNetCidr: "__oam_network_cidr__"
+      openStackSecurityGroup: "__sec_group__"
       openStackOamNetworkCidrPrefix: "10.0"
       dcaeCollectorIp: "__k8s_1_vm_ip__"
       vnfPubKey: "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDKXDgoo3+WOqcUG8/5uUbk81+yczgwC4Y8ywTmuQqbNxlY1oQ0YxdMUqUnhitSXs5S/yRuAVOYHwGg2mCs20oAINrP+mxBI544AMIb9itPjCtgqtE2EWo6MmnFGbHB4Sx3XioE7F4VPsh7japsIwzOjbrQe+Mua1TGQ5d4nfEOQaaglXLLPFfuc7WbhbJbK6Q7rHqZfRcOwAMXgDoBqlyqKeiKwnumddo2RyNT8ljYmvB6buz7KnMinzo7qB0uktVT05FH9Rg0CTWH5norlG5qXgP2aukL0gk1ph8iAt7uYLf1ktp+LJI2gaF6L0/qli9EmVCSLr1uJ38Q8CBflhkh"
diff --git a/deployment/heat/onap-oom/onap-oom.yaml b/deployment/heat/onap-oom/onap-oom.yaml
index 236437f..f6449b9 100644
--- a/deployment/heat/onap-oom/onap-oom.yaml
+++ b/deployment/heat/onap-oom/onap-oom.yaml
@@ -198,6 +198,7 @@
             __oam_network_cidr__: { get_param: oam_network_cidr }
             __oam_network_id__: { get_resource: oam_network }
             __oam_subnet_id__: { get_resource: oam_subnet }
+            __sec_group__: { get_resource: onap_sg }
             __k8s_1_vm_ip__: { get_attr: [k8s_1_floating_ip, floating_ip_address] }
             __k8s_vm_ips__: [
               get_attr: [k8s_1_floating_ip, floating_ip_address],
diff --git a/deployment/heat/onap-oom/rancher_vm_entrypoint.sh b/deployment/heat/onap-oom/rancher_vm_entrypoint.sh
index 2eabf4e..f90957a 100644
--- a/deployment/heat/onap-oom/rancher_vm_entrypoint.sh
+++ b/deployment/heat/onap-oom/rancher_vm_entrypoint.sh
@@ -19,6 +19,7 @@
 echo "__oam_network_cidr__" > /opt/config/oam_network_cidr.txt
 echo "__oam_network_id__" > /opt/config/oam_network_id.txt
 echo "__oam_subnet_id__" > /opt/config/oam_subnet_id.txt
+echo "__sec_group__" > /opt/config/sec_group.txt
 echo "__integration_gerrit_branch__" > /opt/config/integration_gerrit_branch.txt
 echo "__integration_gerrit_refspec__" > /opt/config/integration_gerrit_refspec.txt
 echo "__oom_gerrit_branch__" > /opt/config/oom_gerrit_branch.txt
@@ -38,6 +39,7 @@
 sed -i 's|\_\_oam_network_cidr__|__oam_network_cidr__|g' /opt/config/integration-override.yaml
 sed -i 's/\_\_oam_network_id__/__oam_network_id__/g' /opt/config/integration-override.yaml
 sed -i 's/\_\_oam_subnet_id__/__oam_subnet_id__/g' /opt/config/integration-override.yaml
+sed -i 's/\_\_sec_group__/__sec_group__/g' /opt/config/integration-override.yaml
 sed -i 's/\_\_rancher_ip_addr__/__rancher_ip_addr__/g' /opt/config/integration-override.yaml
 sed -i 's/\_\_k8s_1_vm_ip__/__k8s_1_vm_ip__/g' /opt/config/integration-override.yaml
 sed -i 's/\_\_docker_proxy__/__docker_proxy__/g' /opt/config/integration-override.yaml
diff --git a/deployment/heat/onap-oom/scripts/gen-onap-oom-yaml.sh b/deployment/heat/onap-oom/scripts/gen-onap-oom-yaml.sh
index 41c5de1..81cfbe3 100755
--- a/deployment/heat/onap-oom/scripts/gen-onap-oom-yaml.sh
+++ b/deployment/heat/onap-oom/scripts/gen-onap-oom-yaml.sh
@@ -65,6 +65,7 @@
             __oam_network_cidr__: { get_param: oam_network_cidr }
             __oam_network_id__: { get_resource: oam_network }
             __oam_subnet_id__: { get_resource: oam_subnet }
+            __sec_group__: { get_resource: onap_sg }
             __k8s_1_vm_ip__: { get_attr: [k8s_1_floating_ip, floating_ip_address] }
             __k8s_vm_ips__: [
 EOF