From e88242da2117cc06bba3b3410f1a6faa9acb5035 Mon Sep 17 00:00:00 2001 From: Lasse Kaihlavirta Date: Wed, 31 Mar 2021 15:02:48 +0300 Subject: Remove redundant optf CSIT tests - optf-has and optf-osdf CSITs have been moved to their respective project repositories: https://gerrit.onap.org/r/c/ci-management/+/120040 https://gerrit.onap.org/r/c/optf/osdf/+/119471 https://gerrit.onap.org/r/c/optf/has/+/119424 Issue-ID: OPTFRA-930 Signed-off-by: Lasse Kaihlavirta Change-Id: I3ca21d3a96e9dd7a6a86202b04b6c506c367ff01 --- .../optf-osdf/osdf/osdf-properties/aaf_root_ca.cer | 31 ------ scripts/optf-osdf/osdf/osdf-properties/osdf.json | 105 --------------------- .../osdf/osdf-properties/osdf_config.yaml | 52 ---------- scripts/optf-osdf/osdf/osdf_proxy_settings.sh | 35 ------- scripts/optf-osdf/osdf/osdf_script.sh | 68 ------------- scripts/optf-osdf/osdf/setup-sms.sh | 71 -------------- scripts/optf-osdf/osdf/simulator_script.sh | 74 --------------- scripts/optf-osdf/osdf/wait_for_port.sh | 36 ------- 8 files changed, 472 deletions(-) delete mode 100644 scripts/optf-osdf/osdf/osdf-properties/aaf_root_ca.cer delete mode 100644 scripts/optf-osdf/osdf/osdf-properties/osdf.json delete mode 100755 scripts/optf-osdf/osdf/osdf-properties/osdf_config.yaml delete mode 100755 scripts/optf-osdf/osdf/osdf_proxy_settings.sh delete mode 100755 scripts/optf-osdf/osdf/osdf_script.sh delete mode 100755 scripts/optf-osdf/osdf/setup-sms.sh delete mode 100755 scripts/optf-osdf/osdf/simulator_script.sh delete mode 100755 scripts/optf-osdf/osdf/wait_for_port.sh (limited to 'scripts/optf-osdf') diff --git a/scripts/optf-osdf/osdf/osdf-properties/aaf_root_ca.cer b/scripts/optf-osdf/osdf/osdf-properties/aaf_root_ca.cer deleted file mode 100644 index e9a50d7e..00000000 --- a/scripts/optf-osdf/osdf/osdf-properties/aaf_root_ca.cer +++ /dev/null @@ -1,31 +0,0 @@ ------BEG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+rtSTAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBhjAN -BgkqhkiG9w0BAQsFAAOCAgEAPx/IaK94n02wPxpnYTy+LVLIxwdq/kawNd6IbiMz -L87zmNMDmHcGbfoRCj8OkhuggX9Lx1/CkhpXimuYsZOFQi5blr/u+v4mIbsgbmi9 -7j+cUHDP0zLycvSvxKHty51LwmaX9a4wkJl5zBU4O1sd/H9tWcEmwJ39ltKoBKBx -c94Zc3iMm5ytRWGj+0rKzLDAXEWpoZ5bE5PLJauA6UDCxDLfs3FwhbS7uDggxYvf -jySF5FCNET94oJ+m8s7VeHvoa8iPGKvXrIqdd7XDHnqJJlVKr7m9S0fMbyEB8ci2 -RtOXDt93ifY1uhoEtEykn4dqBSp8ezvNMnwoXdYPDvTd9uCAFeWFLVreBAWxd25h -PsBTkZA5hpa/rA+mKv6Af4VBViYr8cz4dZCsFChuioVebe9ighrfjB//qKepFjPF -CyjzKN1u0JKm/2x/ORqxkTONG8p3uDwoIOyimUcTtTMv42bfYD88RKakqSFXE9G+ -Z0LlaKABqfjK49o/tsAp+c5LoNlYllKhnetO3QAdraHwdmC36BhoghzR1jpX751A -cZn2VH3Q4XKyp01cJNCJIrua+A+bx6zh3RyW6zIIkbRCbET+UD+4mr8WIcSE3mtR -ZVlnhUDO4z9//WKMVzwS9Rh8/kuszrGFI1KQozXCHLrce3YP6RYZfOed79LXaRwX -dYY= ------END CERTIFICATE----- diff --git a/scripts/optf-osdf/osdf/osdf-properties/osdf.json b/scripts/optf-osdf/osdf/osdf-properties/osdf.json deleted file mode 100644 index ae059f3e..00000000 --- a/scripts/optf-osdf/osdf/osdf-properties/osdf.json +++ /dev/null @@ -1,105 +0,0 @@ -{ - "domain": { - "name": "osdf", - "secrets": [ - { - "name": "so", - "values": { - "UserName": "", - "Password": "" - } - }, - { - "name": "conductor", - "values": { - "UserName": "admin1", - "Password": "plan.15" - } - }, - { - "name": "policyPlatform", - "values": { - "UserName": "testpdp", - "Password": "alpha123" - } - }, - { - "name": "policyClient", - "values": { - "UserName": "python", - "Password": "test" - } - }, - { - "name": "dmaap", - "values": { - "UserName": "NA", - "Password": "NA" - } - }, - { - "name": "sdc", - "values": { - "UserName": "NA", - "Password": "NA" - } - }, - { - "name": "osdfPlacement", - "values": { - "UserName": "test", - "Password": "testpwd" - } - }, - { - "name": "osdfPlacementSO", - "values": { - "UserName": "so_test", - "Password": "so_testpwd" - } - }, - { - "name": "osdfPlacementVFC", - "values": { - "UserName": "vfc_test", - "Password": "vfc_testpwd" - } - }, - { - "name": "osdfCMScheduler", - "values": { - "UserName": "test1", - "Password": "testpwd1" - } - }, - { - "name": "configDb", - "values": { - "UserName": "osdf", - "Password": "passwd" - } - }, - { - "name": "pciHMS", - "values": { - "UserName": "", - "Password": "" - } - }, - { - "name": "osdfPCIOpt", - "values": { - "UserName": "pci_test", - "Password": "pci_testpwd" - } - }, - { - "name": "osdfOptEngine", - "values": { - "UserName": "opt_test", - "Password": "opt_testpwd" - } - } - ] - } -} \ No newline at end of file diff --git a/scripts/optf-osdf/osdf/osdf-properties/osdf_config.yaml b/scripts/optf-osdf/osdf/osdf-properties/osdf_config.yaml deleted file mode 100755 index 95856df8..00000000 --- a/scripts/optf-osdf/osdf/osdf-properties/osdf_config.yaml +++ /dev/null @@ -1,52 +0,0 @@ -placementVersioningEnabled: False - -# Placement API latest version numbers to be set in HTTP header -placementMajorVersion: "1" -placementMinorVersion: "0" -placementPatchVersion: "0" - -# Placement API default version numbers to be set in HTTP header -placementDefaultMajorVersion: "1" -placementDefaultMinorVersion: "0" -placementDefaultPatchVersion: "0" - -# Config for Conductor -conductorUrl: "http://127.0.0.1:5000/simulated/oof/has-api/flow1-success-simple/main.json" -conductorPingWaitTime: 2 # seconds to wait before calling the conductor retry URL -conductorMaxRetries: 5 # if we don't get something in 30 minutes, give up -# versions to be set in HTTP header -conductorMinorVersion: 0 - -# Policy Platform -- requires ClientAuth, Authorization, and Environment -policyPlatformUrl: http://127.0.0.1:5000/simulated/policy/pdpx/decision/v1 # Policy Dev platform URL -policyPlatformEnv: TEST # Environment for policy platform - -# Config for DMaaP -messageReaderHosts: https://DMAAP-HOST1:3905,https://DMAAP-HOST2:3905,https://DMAAP-HOST3:3905 -messageReaderTopic: org.onap.oof.osdf.multicloud - -# Config for SDC -sdcUrl: https://SDC-HOST:8443/sdc/v1/catalog -sdcONAPInstanceID: ONAP-OSDF - -osdfPlacementUrl: "http://127.0.0.1:24699/osdf/api/v2/placement" - -is_aaf_enabled: False -aaf_cache_expiry_hrs: 3 -aaf_url: https://aaftest.simpledemo.onap.org:8095 -aaf_user_roles: - - /api/oof/v1/placement:org.onap.osdf.access|*|read ALL - -# Secret Management Service from AAF -aaf_sms_url: http://aaf-sms.onap:10443 -aaf_sms_timeout: 30 -secret_domain: osdf -aaf_ca_certs: ssl_certs/aaf_root_ca.cer - -# config db api -configDbUrl: http://127.0.0.1:5000/simulated/configdb -configDbGetCellListUrl: 'getCellList' -configDbGetNbrListUrl: 'getNbrList' - -#key -appkey: diff --git a/scripts/optf-osdf/osdf/osdf_proxy_settings.sh b/scripts/optf-osdf/osdf/osdf_proxy_settings.sh deleted file mode 100755 index b68fca97..00000000 --- a/scripts/optf-osdf/osdf/osdf_proxy_settings.sh +++ /dev/null @@ -1,35 +0,0 @@ -#!/bin/bash -# -# ------------------------------------------------------------------------- -# Copyright (c) 2018 AT&T Intellectual Property -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# ------------------------------------------------------------------------- -# - -# put into this file local proxy settings in case they are needed on your local environment -echo "### This is ${WORKSPACE}/scripts/optf-osdf/osdf/osdf_proxy_settings.sh" - -echo "optf/osdf proxy settings" -if [ "$#" -eq "1" ]; then - echo "$1" - cd $1 - pwd -else - exit 1 -fi - -# don't remove following lines: commands can be attached here - - diff --git a/scripts/optf-osdf/osdf/osdf_script.sh b/scripts/optf-osdf/osdf/osdf_script.sh deleted file mode 100755 index 2f2d0c90..00000000 --- a/scripts/optf-osdf/osdf/osdf_script.sh +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/bash -# -# ------------------------------------------------------------------------- -# Copyright (c) 2018 AT&T Intellectual Property -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# ------------------------------------------------------------------------- -# - -echo "### This is ${WORKSPACE}/scripts/optf-osdf/osdf/osdf_script.sh" -# -# add here whatever commands is needed to prepare the optf/osdf CSIT testing -# - -# assume the base is /tmp dir -DIR=/tmp - -# the directory of the script -echo ${DIR} -cd ${DIR} - -# create directory for volume and copy configuration file -# run docker containers -OSDF_CONF=/tmp/osdf/properties/osdf_config.yaml -IMAGE_NAME=nexus3.onap.org:10001/onap/optf-osdf -IMAGE_VER=2.0.3-SNAPSHOT-latest - -mkdir -p /tmp/osdf/properties -mkdir -p /tmp/sms/properties - -cp ${WORKSPACE}/scripts/optf-osdf/osdf/osdf-properties/*.yaml /tmp/osdf/properties/. -cp ${WORKSPACE}/scripts/optf-osdf/osdf/osdf-properties/osdf.json /tmp/sms/properties/. - -#change conductor/configdb simulator urls -OSDF_SIM_IP=`get-instance-ip.sh osdf_sim` -echo "OSDF_SIM_IP=${OSDF_SIM_IP}" -SMS_IP=`get-instance-ip.sh sms` -echo "SMS_IP=${SMS_IP}" - -sed -i -e "s%127.0.0.1:5000%${OSDF_SIM_IP}:5000%g" $OSDF_CONF -sed -i -e "s%aaf-sms.onap:10443%${SMS_IP}:10443%g" $OSDF_CONF - -#Preload secrets -docker exec --user root -i sms /bin/sh -c "mkdir -p /preload/config" -docker cp /tmp/sms/properties/osdf.json sms:/preload/config/osdf.json -docker exec --user root -i sms /bin/sh -c "/sms/bin/preload -cacert /sms/certs/aaf_root_ca.cer -jsondir /preload/config -serviceport 10443 -serviceurl http://localhost" - -docker logs vault -docker run -d --name optf-osdf -v ${OSDF_CONF}:/opt/osdf/config/osdf_config.yaml -p "8698:8699" ${IMAGE_NAME}:${IMAGE_VER} - -sleep 20 - -OSDF_IP=`get-instance-ip.sh optf-osdf` -${WORKSPACE}/scripts/optf-osdf/osdf/wait_for_port.sh ${OSDF_IP} 8699 - -echo "inspect docker things for tracing purpose" -docker inspect optf-osdf diff --git a/scripts/optf-osdf/osdf/setup-sms.sh b/scripts/optf-osdf/osdf/setup-sms.sh deleted file mode 100755 index e6a4b227..00000000 --- a/scripts/optf-osdf/osdf/setup-sms.sh +++ /dev/null @@ -1,71 +0,0 @@ -#!/bin/bash -# -# Copyright 2018 Intel Corporation -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# Not sure why this is needed. -source ${SCRIPTS}/common_functions.sh - -CONFIG_FILE=$(pwd)/config/smsconfig.json - -mkdir -p $(pwd)/config - -docker login -u docker -p docker nexus3.onap.org:10001 -docker pull nexus3.onap.org:10001/onap/aaf/sms -docker pull docker.io/vault:1.3.3 - -# -# Running vault in dev server mode here for CSIT -# In HELM it runs in production mode -# -docker run -e "VAULT_DEV_ROOT_TOKEN_ID=aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee" \ - -e SKIP_SETCAP=true \ - --name vault -d -p 8200:8200 vault:1.3.3 - -SMSDB_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' vault) -cat << EOF > $CONFIG_FILE -{ - "cafile": "auth/selfsignedca.pem", - "servercert": "auth/server.cert", - "serverkey": "auth/server.key", - - "smsdbaddress": "http://$SMSDB_IP:8200", - "vaulttoken": "aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee", - "disable_tls": true -} -EOF - -cat $CONFIG_FILE - -docker run --workdir /sms -v $CONFIG_FILE:/sms/smsconfig.json \ - --name sms -d -p 10443:10443 --user root nexus3.onap.org:10001/onap/aaf/sms - -SMS_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' sms) - -echo "###### WAITING FOR ALL CONTAINERS TO COME UP" -sleep 20 -for i in {1..20}; do - curl -sS -m 1 http://${SMSDB_IP}:8200/v1/sys/seal-status && break - echo sleep $i - sleep $i -done - -# -# add here all ROBOT_VARIABLES settings -# -echo "# sms robot variables settings"; -ROBOT_VARIABLES="-v SMS_HOSTNAME:http://${SMS_IP} -v SMS_PORT:10443" - -echo ${ROBOT_VARIABLES} diff --git a/scripts/optf-osdf/osdf/simulator_script.sh b/scripts/optf-osdf/osdf/simulator_script.sh deleted file mode 100755 index 8f3f7d36..00000000 --- a/scripts/optf-osdf/osdf/simulator_script.sh +++ /dev/null @@ -1,74 +0,0 @@ -#!/bin/bash -# -# ------------------------------------------------------------------------- -# Copyright (c) 2018 AT&T Intellectual Property -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# ------------------------------------------------------------------------- -# - -echo "### This is ${WORKSPACE}/scripts/optf-osdf/osdf/simulator_script.sh" -# -# add here whatever commands is needed to prepare the optf/osdf CSIT testing -# -# assume the base is /tmp dir - -DIR=/tmp - -# the directory of the script -echo ${DIR} -cd ${DIR} - -# the temp directory used, within $DIR -# omit the -p parameter to create a temporal directory in the default location -WORK_DIR=`mktemp -d -p "$DIR"` -echo ${WORK_DIR} -cd ${WORK_DIR} - -# clone optf-osdf project -git clone https://gerrit.onap.org/r/optf/osdf - -#echo "i am ${USER} : only non jenkins users may need proxy settings" -if [ ${USER} != 'jenkins' ]; then - - # add proxy settings into this script when you work behind a proxy - ${WORKSPACE}/scripts/optf-osdf/osdf/osdf_proxy_settings.sh ${WORK_DIR} - -fi - -# prepare osdf_sim -cd ${WORK_DIR}/osdf/test/functest/simulators - -# check Dockerfile content -cat ./Dockerfile - -# build osdf_sim -chmod +x ./build_sim_image.sh -./build_sim_image.sh - -# run osdf_sim -docker run -d --name osdf_sim -p "5000:5000" osdf_sim:latest; - -OSDF_SIM_IP=`get-instance-ip.sh osdf_sim` -echo "OSDF_SIM_IP=${OSDF_SIM_IP}" - -${WORKSPACE}/scripts/optf-osdf/osdf/wait_for_port.sh ${OSDF_SIM_IP} 5000 - - -# wait a while before continuing -sleep 2 - -echo "inspect docker things for tracing purpose" -docker inspect osdf_sim - diff --git a/scripts/optf-osdf/osdf/wait_for_port.sh b/scripts/optf-osdf/osdf/wait_for_port.sh deleted file mode 100755 index 360fc210..00000000 --- a/scripts/optf-osdf/osdf/wait_for_port.sh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/bash -# -# ------------------------------------------------------------------------- -# Copyright (c) 2018 AT&T Intellectual Property -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# ------------------------------------------------------------------------- -# - -if [[ $# -ne 2 ]]; then - echo "Usage: wait-for-port hostname port" >&2 - exit 1 -fi - -host=$1 -port=$2 - -echo "Waiting for $host port $port open" -until telnet $host $port /dev/null | grep -q '^Connected'; do - sleep 1 -done - -echo "$host port $port is open" - -exit 0 -- cgit 1.2.3-korg