From 6082b7d161e7ccfbb38c1b7938c88c2619b8f690 Mon Sep 17 00:00:00 2001 From: tierno Date: Fri, 31 Aug 2018 11:24:08 +0000 Subject: [PATCH] Fix bug 535 propagate instantiaon paramget mac_address Set pip2 at installation scripts Change-Id: Ifafada5520bf7b892e47c6f7e3145bb7541920e3 Signed-off-by: tierno --- openmanod | 2 +- osm_ro/nfvo.py | 2 ++ scripts/install-openmano.sh | 18 +++++++++--------- scripts/python-osm-ro.postinst | 16 ++++++++-------- 4 files changed, 20 insertions(+), 18 deletions(-) diff --git a/openmanod b/openmanod index 6f4c1a8d..5a1701d5 100755 --- a/openmanod +++ b/openmanod @@ -48,7 +48,7 @@ import osm_ro __author__ = "Alfonso Tierno, Gerardo Garcia, Pablo Montes" __date__ = "$26-aug-2014 11:09:29$" -__version__ = "0.5.75-r585" +__version__ = "0.5.76-r586" version_date = "Ago 2018" database_version = 32 # expected database schema version diff --git a/osm_ro/nfvo.py b/osm_ro/nfvo.py index c748b83b..c231d536 100644 --- a/osm_ro/nfvo.py +++ b/osm_ro/nfvo.py @@ -3702,6 +3702,8 @@ def instantiate_vnf(mydb, sce_vnf, params, params_out, rollbackList): netDict['vpci'] = iface['vpci'] if iface.get("mac"): netDict['mac_address'] = iface['mac'] + if iface.get("mac_address"): + netDict['mac_address'] = iface['mac_address'] if iface.get("ip_address"): netDict['ip_address'] = iface['ip_address'] if iface.get("port-security") is not None: diff --git a/scripts/install-openmano.sh b/scripts/install-openmano.sh index 54896c86..7d1df99a 100755 --- a/scripts/install-openmano.sh +++ b/scripts/install-openmano.sh @@ -253,15 +253,15 @@ then [ "$_DISTRO" == "CentOS" -o "$_DISTRO" == "Red" ] && easy_install -U bottle # required for vmware connector TODO move that to separete opt in install script - pip install pip==9.0.3 || exit 1 # --upgrade pip install pip 10 that does not work - pip install pyvcloud==19.1.1 || exit 1 - pip install progressbar || exit 1 - pip install prettytable || exit 1 - pip install pyvmomi || exit 1 + pip2 install pip==9.0.3 || exit 1 # --upgrade pip install pip 10 that does not work + pip2 install pyvcloud==19.1.1 || exit 1 + pip2 install progressbar || exit 1 + pip2 install prettytable || exit 1 + pip2 install pyvmomi || exit 1 # required for OpenNebula connector - pip install untangle || exit 1 - pip install -e git+https://github.com/python-oca/python-oca#egg=oca || exit 1 + pip2 install untangle || exit 1 + pip2 install -e git+https://github.com/python-oca/python-oca#egg=oca || exit 1 # required for AWS connector [ "$_DISTRO" == "Ubuntu" ] && install_packages "python-boto" @@ -332,7 +332,7 @@ then [ "$_DISTRO" == "Ubuntu" ] && install_packages "tox debhelper python-bitarray python-lxml python-six" # TODO check packages for CentOS and RedHat [ "$_DISTRO" == "CentOS" -o "$_DISTRO" == "Red" ] && install_packages "tox debhelper python-bitarray python-lxml python-six" - pip install --upgrade stdeb pyangbind || exit 1 + pip2 install --upgrade stdeb pyangbind || exit 1 fi su $SUDO_USER -c "make -C ${BASEFOLDER}/IM all" dpkg -i ${BASEFOLDER}/IM/deb_dist/python-osm-im*.deb ${BASEFOLDER}/IM/pyangbind/deb_dist/*.deb \ @@ -369,7 +369,7 @@ then # TODO check if that is the name in CentOS and RedHat [ "$_DISTRO" == "CentOS" -o "$_DISTRO" == "Red" ] && install_packages \ "libmysqlclient-dev python-cffi python-packaging python-pkgconfig python-pycparser libssl-dev libffi-dev" - pip install --upgrade stdeb setuptools-version-command || exit 1 + pip2 install --upgrade stdeb setuptools-version-command || exit 1 fi su $SUDO_USER -c "make -C ${BASEFOLDER}/openvim lite" dpkg -i ${BASEFOLDER}/openvim/.build/python-lib-osm-openvim*.deb diff --git a/scripts/python-osm-ro.postinst b/scripts/python-osm-ro.postinst index 20dbc5eb..3e4c1037 100755 --- a/scripts/python-osm-ro.postinst +++ b/scripts/python-osm-ro.postinst @@ -22,14 +22,14 @@ OSMRO_PATH=`python -c 'import osm_ro; print osm_ro.__path__[0]'` #OSMLIBOVIM_PATH=`python -c 'import lib_osm_openvim; print lib_osm_openvim.__path__[0]'` #Pip packages required for vmware connector -pip install pip==9.0.3 -pip install --upgrade pyvcloud==19.1.1 -pip install --upgrade progressbar -pip install --upgrade prettytable -pip install --upgrade pyvmomi -pip install --upgrade pyang pyangbind -pip install untangle -pip install -e git+https://github.com/python-oca/python-oca#egg=oca +pip2 install pip==9.0.3 +pip2 install --upgrade pyvcloud==19.1.1 +pip2 install --upgrade progressbar +pip2 install --upgrade prettytable +pip2 install --upgrade pyvmomi +pip2 install --upgrade pyang pyangbind +pip2 install untangle +pip2 install -e git+https://github.com/python-oca/python-oca#egg=oca systemctl enable osm-ro.service -- 2.17.1