diff options
author | Timoney, Dan (dt5972) <dt5972@att.com> | 2018-03-20 10:23:53 -0400 |
---|---|---|
committer | Timoney, Dan (dt5972) <dt5972@att.com> | 2018-03-20 16:55:03 -0400 |
commit | 09cb034920097e2b65f500029df76c8ff7f398dc (patch) | |
tree | d70390b81d4610168b0381e301570fa4db7707f6 /test | |
parent | 4445f34706a02bc549c9e8f6f390e008bbecc7b4 (diff) |
Fix SDNC and CCSDK CSIT issues
Fixed CCSDK and SDNC setup.sh scripts to use karaf client without
-u arg (change for karaf 4), and to fix versions of containers
used by SDNC CSIT script.
Change-Id: I292e25d04b54d3e12696dab09ca007c97e632555
Issue-ID: SDNC-277
Signed-off-by: Timoney, Dan (dt5972) <dt5972@att.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/csit/plans/ccsdk/healthcheck/health_check.sh | 2 | ||||
-rw-r--r-- | test/csit/plans/ccsdk/healthcheck/setup.sh | 18 | ||||
-rw-r--r-- | test/csit/plans/ccsdk/healthcheck/teardown.sh | 1 | ||||
-rw-r--r-- | test/csit/plans/sdnc/healthcheck/setup.sh | 20 |
4 files changed, 22 insertions, 19 deletions
diff --git a/test/csit/plans/ccsdk/healthcheck/health_check.sh b/test/csit/plans/ccsdk/healthcheck/health_check.sh index ffc766fe9..99f717a20 100644 --- a/test/csit/plans/ccsdk/healthcheck/health_check.sh +++ b/test/csit/plans/ccsdk/healthcheck/health_check.sh @@ -19,7 +19,7 @@ echo $SCRIPTS unset http_proxy https_proxy -response=$(curl --write-out '%{http_code}' --silent --output /dev/null -H "Authorization: Basic YWRtaW46S3A4Yko0U1hzek0wV1hsaGFrM2VIbGNzZTJnQXc4NHZhb0dHbUp2VXkyVQ==" -X POST -H "X-FromAppId: csit-sdnc" -H "X-TransactionId: csit-ccsdk" -H "Accept: application/json" -H "Content-Type: application/json" http://localhost:8383/restconf/operations/SLI-API:healthcheck ) +response=$(curl --write-out '%{http_code}' --silent --output /dev/null -H "Authorization: Basic YWRtaW46YWRtaW4=" -X POST -H "X-FromAppId: csit-sdnc" -H "X-TransactionId: csit-ccsdk" -H "Accept: application/json" -H "Content-Type: application/json" http://localhost:8383/restconf/operations/SLI-API:healthcheck ) if [ "$response" == "200" ]; then echo "CCSDK health check passed." diff --git a/test/csit/plans/ccsdk/healthcheck/setup.sh b/test/csit/plans/ccsdk/healthcheck/setup.sh index 0be8bef6c..2b7424c3b 100644 --- a/test/csit/plans/ccsdk/healthcheck/setup.sh +++ b/test/csit/plans/ccsdk/healthcheck/setup.sh @@ -63,7 +63,7 @@ TIME_OUT=500 INTERVAL=30 TIME=0 while [ "$TIME" -lt "$TIME_OUT" ]; do - response=$(curl --write-out '%{http_code}' --silent --output /dev/null -H "Authorization: Basic YWRtaW46S3A4Yko0U1hzek0wV1hsaGFrM2VIbGNzZTJnQXc4NHZhb0dHbUp2VXkyVQ==" -X POST -H "X-FromAppId: csit-ccsdk" -H "X-TransactionId: csit-ccsdk" -H "Accept: application/json" -H "Content-Type: application/json" http://localhost:8383/restconf/operations/SLI-API:healthcheck ); echo $response + response=$(curl --write-out '%{http_code}' --silent --output /dev/null -H "Authorization: Basic YWRtaW46YWRtaW4=" -X POST -H "X-FromAppId: csit-ccsdk" -H "X-TransactionId: csit-ccsdk" -H "Accept: application/json" -H "Content-Type: application/json" http://localhost:8383/restconf/operations/SLI-API:healthcheck ); echo $response if [ "$response" == "200" ]; then echo CCSDK started in $TIME seconds @@ -86,8 +86,10 @@ INTERVAL=60 TIME=0 while [ "$TIME" -lt "$TIME_OUT" ]; do -response=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client -u karaf system:start-level) -num_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client -u karaf bundle:list | tail -1 | cut -d\| -f1) +docker exec ccsdk_odlsli_container rm -f /opt/opendaylight/current/etc/host.key +response=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client system:start-level) +docker exec ccsdk_odlsli_container rm -f /opt/opendaylight/current/etc/host.key +num_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client bundle:list | tail -1 | cut -d\| -f1) if [ "$response" == "Level 100" ] && [ "$num_bundles" -ge 333 ]; then echo CCSDK karaf started in $TIME seconds @@ -103,13 +105,13 @@ if [ "$TIME" -ge "$TIME_OUT" ]; then echo TIME OUT: karaf session not started in $TIME_OUT seconds... Could cause problems for testing activities... fi -response=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client -u karaf system:start-level) -num_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client -u karaf bundle:list | tail -1 | cut -d\| -f1) +response=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client system:start-level) +num_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client bundle:list | tail -1 | cut -d\| -f1) if [ "$response" == "Level 100" ] && [ "$num_bundles" -ge 333 ]; then - num_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client -u karaf bundle:list | tail -1 | cut -d\| -f1) - num_failed_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client -u karaf bundle:list | grep Failure | wc -l) - failed_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client -u karaf bundle:list | grep Failure) + num_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client bundle:list | tail -1 | cut -d\| -f1) + num_failed_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client bundle:list | grep Failure | wc -l) + failed_bundles=$(docker exec ccsdk_odlsli_container /opt/opendaylight/current/bin/client bundle:list | grep Failure) echo There is/are $num_failed_bundles failed bundles out of $num_bundles installed bundles. fi diff --git a/test/csit/plans/ccsdk/healthcheck/teardown.sh b/test/csit/plans/ccsdk/healthcheck/teardown.sh index fbc0dfa42..56820786a 100644 --- a/test/csit/plans/ccsdk/healthcheck/teardown.sh +++ b/test/csit/plans/ccsdk/healthcheck/teardown.sh @@ -19,7 +19,6 @@ kill-instance.sh ccsdk_db_container kill-instance.sh ccsdk_dgbuilder_container -kill-instance.sh ccsdk_bareodl_container kill-instance.sh ccsdk_odlsli_container # $WORKSPACE/archives/appc deleted with archives folder when tests starts so we keep it at the end for debugging diff --git a/test/csit/plans/sdnc/healthcheck/setup.sh b/test/csit/plans/sdnc/healthcheck/setup.sh index f2d7f6e45..0b906f4f2 100644 --- a/test/csit/plans/sdnc/healthcheck/setup.sh +++ b/test/csit/plans/sdnc/healthcheck/setup.sh @@ -24,8 +24,8 @@ export NEXUS_USERNAME=docker export NEXUS_PASSWD=docker export NEXUS_DOCKER_REPO=nexus3.onap.org:10001 export DMAAP_TOPIC=AUTO -export DOCKER_IMAGE_VERSION=1.2-STAGING-latest -export CCSDK_DOCKER_IMAGE_VERSION=0.1-STAGING-latest +export DOCKER_IMAGE_VERSION=1.3-STAGING-latest +export CCSDK_DOCKER_IMAGE_VERSION=0.2-STAGING-latest export MTU=$(/sbin/ifconfig | grep MTU | sed 's/.*MTU://' | sed 's/ .*//' | sort -n | head -1) @@ -94,8 +94,10 @@ INTERVAL=60 TIME=0 while [ "$TIME" -lt "$TIME_OUT" ]; do -response=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client -u karaf system:start-level) -num_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client -u karaf bundle:list | tail -1 | cut -d\| -f1) +docker exec sdnc_controller_container rm -f /opt/opendaylight/current/etc/host.key +response=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client system:start-level) +docker exec sdnc_controller_container rm -f /opt/opendaylight/current/etc/host.key +num_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client bundle:list | tail -1 | cut -d\| -f1) if [ "$response" == "Level 100" ] && [ "$num_bundles" -ge 333 ]; then echo SDNC karaf started in $TIME seconds @@ -111,13 +113,13 @@ if [ "$TIME" -ge "$TIME_OUT" ]; then echo TIME OUT: karaf session not started in $TIME_OUT seconds... Could cause problems for testing activities... fi -response=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client -u karaf system:start-level) -num_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client -u karaf bundle:list | tail -1 | cut -d\| -f1) +response=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client system:start-level) +num_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client bundle:list | tail -1 | cut -d\| -f1) if [ "$response" == "Level 100" ] && [ "$num_bundles" -ge 333 ]; then - num_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client -u karaf bundle:list | tail -1 | cut -d\| -f1) - num_failed_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client -u karaf bundle:list | grep Failure | wc -l) - failed_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client -u karaf bundle:list | grep Failure) + num_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client bundle:list | tail -1 | cut -d\| -f1) + num_failed_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client bundle:list | grep Failure | wc -l) + failed_bundles=$(docker exec sdnc_controller_container /opt/opendaylight/current/bin/client bundle:list | grep Failure) echo There is/are $num_failed_bundles failed bundles out of $num_bundles installed bundles. fi |