X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=BUILD.sh;h=a34202b82e7934290d689430ad9d053c04160b43;hb=ed3a5315de9460a81dc2adff6840b5206717017f;hp=222ccad45c1aa23e2faf60e41e385dc49640df91;hpb=49868d2c71eb364cee9707515be6841a568dad40;p=osm%2FSO.git diff --git a/BUILD.sh b/BUILD.sh index 222ccad4..a34202b8 100755 --- a/BUILD.sh +++ b/BUILD.sh @@ -95,9 +95,14 @@ set -x # Print commands before executing them ############################################################################### # Find the platform -if python -mplatform | grep -qi fedora; then +PYTHON=python +if [[ ! -f /usr/bin/python ]]; then + PYTHON=python3 +fi + +if $PYTHON -mplatform | grep -qi fedora; then PLATFORM=fc20 -elif python -mplatform | grep -qi ubuntu; then +elif $PYTHON -mplatform | grep -qi ubuntu; then PLATFORM=ub16 else echo "Unknown platform" @@ -109,10 +114,10 @@ fi if [[ $PLATFORM == ub16 ]]; then PLATFORM_REPOSITORY=${1:-OSM} - PLATFORM_VERSION=${2:-4.3.1.0.49556} + PLATFORM_VERSION=${2:-4.3.1.0.50309} elif [[ $PLATFORM == fc20 ]]; then PLATFORM_REPOSITORY=${1:-OSM} # change to OSM when published - PLATFORM_VERSION=${2:-4.3.1.0.49553-1} + PLATFORM_VERSION=${2:-4.3.1.0.50310} else echo "Internal error: unknown platform $PLATFORM" exit 1 @@ -153,13 +158,14 @@ fi # and install of the packages required to build and run # this module if $runMkcontainer; then + sudo apt-get install -y libxml2-dev libxslt-dev sudo /usr/rift/container_tools/mkcontainer --modes build --modes ext --repo ${PLATFORM_REPOSITORY} fi if [[ $PLATFORM == ub16 ]]; then # install the RIFT platform code: - sudo apt-get install -y rw.toolchain-rwbase=${PLATFORM_VERSION} \ + sudo apt-get install -y --allow-downgrades rw.toolchain-rwbase=${PLATFORM_VERSION} \ rw.toolchain-rwtoolchain=${PLATFORM_VERSION} \ rw.core.mgmt-mgmt=${PLATFORM_VERSION} \ rw.core.util-util=${PLATFORM_VERSION} \ @@ -167,6 +173,8 @@ if [[ $PLATFORM == ub16 ]]; then rw.core.rwvx-rwdts=${PLATFORM_VERSION} \ rw.automation.core-RWAUTO=${PLATFORM_VERSION} \ rw.core.rwvx-rwha-1.0=${PLATFORM_VERSION} + + sudo apt-get install python-cinderclient sudo chmod 777 /usr/rift /usr/rift/usr/share @@ -264,8 +272,6 @@ if [[ $UIPathToBuild ]]; then sudo make -C $UIPathToBuild install fi -echo "To run SO with UI please run:" -echo 'sudo -H /usr/rift/rift-shell -r -i /usr/rift -a /usr/rift/.artifacts -- ./demos/launchpad.py --use-xml-mode' -echo -echo "To run SO without UI please run:" -echo 'sudo -H /usr/rift/rift-shell -r -i /usr/rift -a /usr/rift/.artifacts -- ./demos/launchpad.py --use-xml-mode --no-ui' +echo "Creating Service ...." +sudo $(dirname $0)/create_launchpad_service +