aboutsummaryrefslogtreecommitdiffstats
path: root/test/ete
diff options
context:
space:
mode:
Diffstat (limited to 'test/ete')
-rw-r--r--test/ete/labs/windriver/Integration-Jenkins-openrc.sh7
-rw-r--r--test/ete/labs/windriver/Integration-SB-04-openrc.sh49
-rw-r--r--test/ete/labs/windriver/onap-openstack-template.env60
-rwxr-xr-xtest/ete/scripts/deploy-onap.sh39
-rwxr-xr-xtest/ete/scripts/install_openstack_cli.sh2
-rwxr-xr-xtest/ete/scripts/remote/run-robot.sh16
-rwxr-xr-xtest/ete/scripts/run-healthcheck.sh12
7 files changed, 140 insertions, 45 deletions
diff --git a/test/ete/labs/windriver/Integration-Jenkins-openrc.sh b/test/ete/labs/windriver/Integration-Jenkins-openrc.sh
index ef2aa9a25..ca2e2c2cf 100644
--- a/test/ete/labs/windriver/Integration-Jenkins-openrc.sh
+++ b/test/ete/labs/windriver/Integration-Jenkins-openrc.sh
@@ -15,7 +15,7 @@ export OS_AUTH_URL=http://10.12.25.2:5000/v3
# With the addition of Keystone we have standardized on the term **project**
# as the entity that owns the resources.
-export OS_PROJECT_ID=09d8566ea45e43aa974cf447ed591d77
+export OS_PROJECT_ID="09d8566ea45e43aa974cf447ed591d77"
export OS_PROJECT_NAME="Integration-Jenkins"
export OS_USER_DOMAIN_NAME="Default"
if [ -z "$OS_USER_DOMAIN_NAME" ]; then unset OS_USER_DOMAIN_NAME; fi
@@ -26,7 +26,10 @@ unset OS_TENANT_NAME
# In addition to the owning entity (tenant), OpenStack stores the entity
# performing the action as the **user**.
-export OS_USERNAME="gary_wu"
+if [ -z ${OS_USERNAME_INPUT+x} ]; then
+ read -sp "Please enter your OpenStack Username for project $OS_PROJECT_NAME: " OS_USERNAME_INPUT
+fi
+export OS_USERNAME=$OS_USERNAME_INPUT
# With Keystone you pass the keystone password.
if [ -z ${OS_PASSWORD_INPUT+x} ]; then
diff --git a/test/ete/labs/windriver/Integration-SB-04-openrc.sh b/test/ete/labs/windriver/Integration-SB-04-openrc.sh
new file mode 100644
index 000000000..e7cee93b9
--- /dev/null
+++ b/test/ete/labs/windriver/Integration-SB-04-openrc.sh
@@ -0,0 +1,49 @@
+#!/usr/bin/env bash
+
+# To use an OpenStack cloud you need to authenticate against the Identity
+# service named keystone, which returns a **Token** and **Service Catalog**.
+# The catalog contains the endpoints for all services the user/tenant has
+# access to - such as Compute, Image Service, Identity, Object Storage, Block
+# Storage, and Networking (code-named nova, glance, keystone, swift,
+# cinder, and neutron).
+#
+# *NOTE*: Using the 3 *Identity API* does not necessarily mean any other
+# OpenStack API is version 3. For example, your cloud provider may implement
+# Image API v1.1, Block Storage API v2, and Compute API v2.0. OS_AUTH_URL is
+# only for the Identity API served through keystone.
+export OS_AUTH_URL=http://10.12.25.2:5000/v3
+
+# With the addition of Keystone we have standardized on the term **project**
+# as the entity that owns the resources.
+export OS_PROJECT_ID="d570c718cbc545029f40e50b75eb13df"
+export OS_PROJECT_NAME="Integration-SB-04"
+export OS_USER_DOMAIN_NAME="Default"
+if [ -z "$OS_USER_DOMAIN_NAME" ]; then unset OS_USER_DOMAIN_NAME; fi
+
+# unset v2.0 items in case set
+unset OS_TENANT_ID
+unset OS_TENANT_NAME
+
+# In addition to the owning entity (tenant), OpenStack stores the entity
+# performing the action as the **user**.
+# In addition to the owning entity (tenant), OpenStack stores the entity
+# performing the action as the **user**.
+if [ -z ${OS_USERNAME_INPUT+x} ]; then
+ read -sp "Please enter your OpenStack Username for project $OS_PROJECT_NAME: " OS_USERNAME_INPUT
+fi
+export OS_USERNAME=$OS_USERNAME_INPUT
+
+# With Keystone you pass the keystone password.
+if [ -z ${OS_PASSWORD_INPUT+x} ]; then
+ read -sp "Please enter your OpenStack Password for project $OS_PROJECT_NAME as user $OS_USERNAME: " OS_PASSWORD_INPUT
+fi
+export OS_PASSWORD=$OS_PASSWORD_INPUT
+
+# If your configuration has multiple regions, we set that information here.
+# OS_REGION_NAME is optional and only valid in certain environments.
+export OS_REGION_NAME="RegionOne"
+# Don't leave a blank variable, unset it if it was empty
+if [ -z "$OS_REGION_NAME" ]; then unset OS_REGION_NAME; fi
+
+export OS_INTERFACE=public
+export OS_IDENTITY_API_VERSION=3
diff --git a/test/ete/labs/windriver/onap-openstack-template.env b/test/ete/labs/windriver/onap-openstack-template.env
index b1b31ee88..72df4f654 100644
--- a/test/ete/labs/windriver/onap-openstack-template.env
+++ b/test/ete/labs/windriver/onap-openstack-template.env
@@ -70,6 +70,7 @@ parameters:
dns_list: ["10.12.25.5", "8.8.8.8"]
external_dns: 8.8.8.8
oam_network_cidr: 10.0.0.0/16
+ dns_forwarder: 10.12.25.5
### Private IP addresses ###
@@ -126,37 +127,36 @@ parameters:
dnsaas_tenant_name: ${OS_PROJECT_NAME}
dnsaas_username: ${OS_USERNAME}
dnsaas_password: ${OS_PASSWORD}
+ dcae_domain: dcaeg2.onap.org
dcae_keystone_url: "http://10.0.14.1/api/multicloud-titanium_cloud/v0/pod25_RegionOne/identity/v2.0"
dcae_centos_7_image: CentOS-7
- dcae_security_group: default
- dcae_key_name: 'id_lji_onap'
- dcae_public_key: 'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDloKgBHx/yKRV77lr828rqa+zK+iTZpqmH3WSUU3vdNhSbEMNKkGVXR4+Gq1hNd8UNF+jMg87kOFSlQbE5jvsQMWuu1unxLKbH3AeXJd21gR1Gx4KXjkWsfl4URWMZ9WNvH0hMvqEV5SdFIDQmx07C/NOfy3R5N1pCgNsh9RT+EpDFh7jmimxrAqdxP0HnGFC2oM3rYMnzfh2/+Obkag6O3RZOkYx/WLQKbOKTi8K1C4UM5pwFzLT/vC+d9DF8pE7P9dlrbHTF9c3IGsP5oCa8CQ/WE4lVj/L9/iFNs0WsxdYaOnf11GJmPs663hltvWbQiqsFpdjX6tk/zMb3Xipz ubuntu@lusheng-sm-b781d54e-48ac-42fa-a780-3289b56e6598'
- dcae_private_key: '-----BEGIN RSA PRIVATE KEY-----\n
-MIIEowIBAAKCAQEA5aCoAR8f8ikVe+5a/NvK6m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
+9pgDleQPkQsrHQ6/AyIwFBsLwf9THSS5V+uV9D57SfUs46Bf2U8J6N90YQSlt8iS\n
+aWuManFPVgT+yxDIzt6obf2mCEpOIBtQ6N4ZRh2HhQwdWTCrkzkDdGQaHG+jYL6C\n
+xGPwiG2ON7OAfGIAM7eN5lECgYEAhoRLWlaOgRGnHKAWsYQvZ67CjTdDcPPuVu6v\n
+fMQnNMA/7JeTwV+E205L0wfpgZ/cZKmBBlQMJlnUA3q2wfO+PTnse1mjDJU/cGtB\n
+22/lJLxChlQdxGeQhGtGzUhF+hEeOhrO6WSSx7CtMRZoy6Dr6lwfMFZCdVNcBd6v\n
+YOOZk3ECgYEAseUKGb6E80XTVVNziyuiVbQCsI0ZJuRfqMZ2IIDQJU9u6AnGAway\n
+itqHbkGsmDT+4HUz01+1JKnnw42RdSrHdU/LaOonD+RIGqe2x800QXzqASKLdCXr\n
+y7RoiFqJtkdFQykzJemA+xOXvHLgKi/MXFsU90PCD0VJKLj8vwpX78Y=\n
-----END RSA PRIVATE KEY-----'
################################
@@ -197,7 +197,7 @@ m3bZLBvlAVvCajosd/qeX0FkPGZlgk1dGZ8/7SyK7NITqAfgMMRS\n
uui_docker: latest
esr_docker: latest
dgbuilder_docker: 0.1-STAGING-latest
- cli_docker: 1.1-STAGING-latest
+ cli_docker: v1.1.0
#####################
# #
diff --git a/test/ete/scripts/deploy-onap.sh b/test/ete/scripts/deploy-onap.sh
index 69296ab17..4802e02ce 100755
--- a/test/ete/scripts/deploy-onap.sh
+++ b/test/ete/scripts/deploy-onap.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/bash -x
if [ -z "$WORKSPACE" ]; then
export WORKSPACE=`git rev-parse --show-toplevel`
@@ -8,19 +8,56 @@ source $WORKSPACE/test/ete/scripts/install_openstack_cli.sh
# Delete all existing stacks
STACKS=$(openstack stack list -c "Stack Name" -f value)
+
if [ ! -z "${STACKS}" ]; then
echo "Deleting Stacks ${STACKS}"
openstack stack delete -y $STACKS
+ for STACK in ${STACKS}; do
+ until [ "DELETE_IN_PROGRESS" != "$(openstack stack show -c stack_status -f value $STACK)" ]; do
+ sleep 30
+ done
+ done
else
echo "No existing stacks to delete."
fi
+
+
+
STACK="ete-$(uuidgen | cut -c-8)"
echo "New Stack Name: ${STACK}"
cp ${ONAP_WORKDIR}/demo/heat/ONAP/onap_openstack.env ${WORKSPACE}/test/ete/labs/windriver/onap-openstack-demo.env
envsubst < ${WORKSPACE}/test/ete/labs/windriver/onap-openstack-template.env > ${WORKSPACE}/test/ete/labs/windriver/onap-openstack.env
+#diff ${WORKSPACE}/test/ete/labs/windriver/onap-openstack-template.env ${WORKSPACE}/test/ete/labs/windriver/onap-openstack.env
openstack stack create -t ${ONAP_WORKDIR}/demo/heat/ONAP/onap_openstack.yaml -e ${WORKSPACE}/test/ete/labs/windriver/onap-openstack.env $STACK
+while [ "CREATE_IN_PROGRESS" == "$(openstack stack show -c stack_status -f value $STACK)" ]; do
+ sleep 15
+done
+
+STATUS=$(openstack stack show -c stack_status -f value $STACK)
+echo $STATUS
+if [ "CREATE_COMPLETE" != "$STATUS" ]; then
+ exit 1
+fi
+
+
+# wait until Robot VM initializes
+ROBOT_IP=$($WORKSPACE/test/ete/scripts/get-floating-ip.sh onap-robot)
+echo "ROBOT_IP=${ROBOT_IP}"
+
+if [ "" == "${ROBOT_IP}" ]; then
+ exit 1
+fi
+
+ssh-keygen -R ${ROBOT_IP}
+
+SSH_KEY=~/.ssh/onap_key
+
+until ssh -o StrictHostKeychecking=no -i ${SSH_KEY} root@${ROBOT_IP} "docker ps | grep -q openecompete_container"
+do
+ sleep 1m
+done
diff --git a/test/ete/scripts/install_openstack_cli.sh b/test/ete/scripts/install_openstack_cli.sh
index ec5ad1f76..a6a0438f9 100755
--- a/test/ete/scripts/install_openstack_cli.sh
+++ b/test/ete/scripts/install_openstack_cli.sh
@@ -38,7 +38,7 @@ if [ -z "$ONAP_WORKDIR" ]; then
fi
echo "ONAP_WORKDIR=${ONAP_WORKDIR}"
if [ ! -d ${ONAP_WORKDIR}/demo ]; then
- git clone http://gerrit.onap.org/r/demo ${ONAP_WORKDIR}/demo
+ git clone https://gerrit.onap.org/r/demo ${ONAP_WORKDIR}/demo
else
pushd ${ONAP_WORKDIR}/demo
git pull
diff --git a/test/ete/scripts/remote/run-robot.sh b/test/ete/scripts/remote/run-robot.sh
index ff7223a17..162acbe24 100755
--- a/test/ete/scripts/remote/run-robot.sh
+++ b/test/ete/scripts/remote/run-robot.sh
@@ -1,18 +1,20 @@
-#!/bin/bash
+#!/bin/bash -x
cd /opt
-if [ ! -x /opt/demo.sh ]; then
- echo "Robot VM not initialized"
+docker ps | grep -q openecompete_container
+if [ ! $? -eq 0 ]; then
+ echo "Robot not initialized"
exit 2
fi
if [ ! -d eteshare/logs/demo ]; then
- echo "09d8566ea45e43aa974cf447ed591d77" > /opt/config/openstack_tenant_id.txt
- echo "gary_wu" > /opt/config/openstack_username.txt
- echo $OS_PASSWORD_INPUT > /opt/config/openstack_password.txt
+ echo $OS_PROJECT_ID > /opt/config/openstack_tenant_id.txt
+ echo $OS_USERNAME > /opt/config/openstack_username.txt
+ echo $OS_PASSWORD > /opt/config/openstack_password.txt
/bin/bash /opt/eteshare/config/vm_config2robot.sh
- echo "test" | /opt/demo.sh init_robot
+ # set robot VM http server password
+ echo "admin" | /opt/demo.sh init_robot
fi
/opt/ete.sh health
diff --git a/test/ete/scripts/run-healthcheck.sh b/test/ete/scripts/run-healthcheck.sh
index 1555dad85..2f0f014d3 100755
--- a/test/ete/scripts/run-healthcheck.sh
+++ b/test/ete/scripts/run-healthcheck.sh
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/bin/bash -x
SSH_KEY=~/.ssh/onap_key
@@ -13,10 +13,14 @@ cd $WORKSPACE/test/ete/scripts
ROBOT_IP=$(./get-floating-ip.sh onap-robot)
echo "ROBOT_IP=${ROBOT_IP}"
-# allow direct login as root
-ssh -o StrictHostKeychecking=no -i ${SSH_KEY} ubuntu@${ROBOT_IP} 'sudo cp /home/ubuntu/.ssh/authorized_keys /root/.ssh/'
+if [ "" == "${ROBOT_IP}" ]; then
+ exit 1
+fi
+
+ssh-keygen -R ${ROBOT_IP}
+
+ssh -o StrictHostKeychecking=no -i ${SSH_KEY} root@${ROBOT_IP} "OS_PROJECT_ID=$OS_PROJECT_ID OS_USERNAME=$OS_USERNAME OS_PASSWORD=$OS_PASSWORD bash -s" < ./remote/run-robot.sh
-ssh -o StrictHostKeychecking=no -i ${SSH_KEY} root@${ROBOT_IP} "OS_PASSWORD_INPUT=$OS_PASSWORD_INPUT bash -s" < ./remote/run-robot.sh
LOG_DIR=$(ssh -o StrictHostKeychecking=no -i ${SSH_KEY} root@${ROBOT_IP} "ls -1t /opt/eteshare/logs | head -1")
echo "Browse Robot results at http://${ROBOT_IP}:88/logs/${LOG_DIR}/"
rsync -e "ssh -i ${SSH_KEY}" -avPz root@${ROBOT_IP}:/opt/eteshare/logs/${LOG_DIR}/ $WORKSPACE/archives/