X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=csit%2Flibraries%2FVtnCoKeywords.robot;h=95b2a9d0d4a232c0a18790b2df0502f8e8e2cbac;hb=7c1e3422ab18d0bd17e18b3144a6b7e1795abbbc;hp=aa986fc706df9ab1848a93aab93c6ea9844a90a7;hpb=af10a8780c93a7ac8b8fde288b776cf98e04582a;p=integration%2Ftest.git diff --git a/csit/libraries/VtnCoKeywords.robot b/csit/libraries/VtnCoKeywords.robot index aa986fc706..95b2a9d0d4 100644 --- a/csit/libraries/VtnCoKeywords.robot +++ b/csit/libraries/VtnCoKeywords.robot @@ -9,21 +9,26 @@ Library Collections Library XML Variables ../variables/Variables.py Resource ./Utils.robot +Resource ./MininetKeywords.robot *** variable *** ${vlan_topo} sudo mn --controller=remote,ip=${ODL_SYSTEM_IP} --custom vlan_vtn_test.py --topo vlantopo +${nexus_path} https://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/org/opendaylight/vtn/distribution.vtn-coordinator +${boron} 6.3.1-SNAPSHOT +${carbon} 6.4.0-SNAPSHOT +${vtn_dist} distribution.vtn-coordinator *** Keywords *** Get VtnCo [Documentation] Download the VTN Coordinator from Controller VM Log Download the VTN Coordinator bz2 file SSHLibrary.Open_Connection ${ODL_SYSTEM_IP} - SSHLibrary.Login_With_Public_Key ${CONTROLLER_USER} ${USER_HOME}/.ssh/${SSH_KEY} any + SSHLibrary.Login_With_Public_Key ${ODL_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any ${VTNC_FILENAME}= Catenate SEPARATOR=/ ${WORKSPACE} vtn_coordinator.tar.bz2 SSHLibrary.Get_File ${WORKSPACE}/${BUNDLEFOLDER}/externalapps/*vtn-coordinator*-bin.tar.bz2 ${VTNC_FILENAME} SSHLibrary.Close_Connection - SSHLibrary.Open_Connection ${MININET} - SSHLibrary.Login_With_Public_Key ${MININET_USER} ${USER_HOME}/.ssh/${SSH_KEY} any + SSHLibrary.Open_Connection ${TOOLS_SYSTEM_IP} + SSHLibrary.Login_With_Public_Key ${TOOLS_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any SSHLibrary.Put_File ${VTNC_FILENAME} /tmp SSHLibrary.Close_Connection @@ -33,12 +38,13 @@ Start SuiteVtnCo #Get VtnCo ${vtnc_conn_id}= SSHLibrary.Open Connection ${ODL_SYSTEM_IP} prompt=${DEFAULT_LINUX_PROMPT} timeout=30s Set Suite Variable ${vtnc_conn_id} - SSHLibrary.Login_With_Public_Key ${CONTROLLER_USER} ${USER_HOME}/.ssh/${SSH_KEY} any + SSHLibrary.Login_With_Public_Key ${ODL_SYSTEM_USER} ${USER_HOME}/.ssh/${SSH_KEY} any SSHLibrary.Execute Command sudo mkdir -p /usr/local/vtn SSHLibrary.Execute Command sudo chown jenkins /usr/local/vtn - SSHLibrary.Execute Command sudo yum install -q -y http://yum.postgresql.org/9.3/redhat/rhel-7-x86_64/pgdg-centos93-9.3-1.noarch.rpm - SSHLibrary.Execute Command sudo yum install -q -y postgresql93-libs postgresql93 postgresql93-server postgresql93-contrib postgresql93-odbc - SSHLibrary.Execute Command tar -C/ -jxvf ${WORKSPACE}/${BUNDLEFOLDER}/externalapps/*vtn-coordinator*-bin.tar.bz2 + SSHLibrary.Execute Command sudo yum install -q -y http://yum.postgresql.org/9.3/redhat/rhel-7-x86_64/pgdg-centos93-9.3-2.noarch.rpm + SSHLibrary.Execute Command sudo yum install -q -y postgresql93-libs postgresql93 postgresql93-server postgresql93-contrib postgresql93-odbc-09.03.0400 + Run Keyword If '${ODL_STREAM}' == 'boron' or '${ODL_STREAM}' == 'carbon' Download VtnCo Distribution + ... ELSE SSHLibrary.Execute Command tar -C/ -jxvf ${WORKSPACE}/${BUNDLEFOLDER}/externalapps/${vtn_dist}*-bin.tar.bz2 SSHLibrary.Execute Command /usr/local/vtn/sbin/db_setup SSHLibrary.Execute Command /usr/local/vtn/bin/vtn_start SSHLibrary.Execute Command /usr/local/vtn/bin/unc_dmctl status @@ -51,6 +57,16 @@ Start SuiteVtnCo SSHLibrary.Execute Command /usr/local/vtn/bin/lgcnw_control loglevel trace SSHLibrary.Execute Command exit +Download VtnCo Distribution + Run Keyword If '${ODL_STREAM}' == 'boron' SSHLibrary.Execute Command wget "${nexus_path}/${boron}/maven-metadata.xml" + ... ELSE IF '${ODL_STREAM}' == 'carbon' SSHLibrary.Execute Command wget "${nexus_path}/${carbon}/maven-metadata.xml" + Run Keyword If '${ODL_STREAM}' == 'boron' or '${ODL_STREAM}' == 'carbon' SSHLibrary.Get_file maven-metadata.xml + ${time_stamp}= XML.Get Element Text maven-metadata.xml xpath=.//snapshot/timestamp + ${build_number}= XML.Get Element Text maven-metadata.xml xpath=.//snapshot/buildNumber + Run Keyword If '${ODL_STREAM}' == 'boron' SSHLibrary.Execute Command wget '${nexus_path}/${boron}/${vtn_dist}-6.3.1-${time_stamp}-${build_number}-bin.tar.bz2' + ... ELSE IF '${ODL_STREAM}' == 'carbon' SSHLibrary.Execute Command wget '${nexus_path}/${carbon}/${vtn_dist}-6.4.0-${time_stamp}-${build_number}-bin.tar.bz2' + SSHLibrary.Execute Command tar -C/ -jxvf ${vtn_dist}*-bin.tar.bz2 + Stop SuiteVtnCo [Documentation] Exit the Launch Test Log Stop the Launch Test @@ -256,7 +272,8 @@ Create VLANMAP in VBRIDGE Start vlan_topo [Documentation] This will start mininet with custom topology on both the Virtual Machines - Start Mininet ${MININET} ${vlan_topo} ${CURDIR}/${CREATE_VLAN_TOPOLOGY_FILE_PATH} + Install Package On Ubuntu System vlan + MininetKeywords.Start Mininet Single Controller ${TOOLS_SYSTEM_IP} ${ODL_SYSTEM_IP} ${vlan_topo} ${CURDIR}/${CREATE_VLAN_TOPOLOGY_FILE_PATH} Delete a FLOWLIST [Arguments] ${flowlistname}