aboutsummaryrefslogtreecommitdiffstats
path: root/bootstrap/vagrant-onap/lib/multicloud
diff options
context:
space:
mode:
Diffstat (limited to 'bootstrap/vagrant-onap/lib/multicloud')
-rwxr-xr-xbootstrap/vagrant-onap/lib/multicloud47
1 files changed, 25 insertions, 22 deletions
diff --git a/bootstrap/vagrant-onap/lib/multicloud b/bootstrap/vagrant-onap/lib/multicloud
index b4a185aaf..d2b09f2aa 100755
--- a/bootstrap/vagrant-onap/lib/multicloud
+++ b/bootstrap/vagrant-onap/lib/multicloud
@@ -1,44 +1,47 @@
#!/bin/bash
-set -o xtrace
-
source /var/onap/functions
-multicloud_src_folder=$git_src_folder/multicloud
-multicloud_repos=("multicloud" "multicloud/framework" "multicloud/openstack" \
-"multicloud/openstack/vmware" "multicloud/openstack/windriver" \
-"multicloud/azure")
-
-# clone_multicloud_repos() - Function that clones the Multi Cloud repositories
-function clone_multicloud_repos {
- for repo in ${multicloud_repos[@]}; do
- clone_repo $repo $multicloud_src_folder${repo#*multicloud}
- done
-}
+openstack_release="newton"
-# compile_multicloud_repos() -
-function compile_multicloud_repos {
- for repo in ${multicloud_repos[@]}; do
- compile_src $multicloud_src_folder${repo#*multicloud}
- done
+# _build_multicloud_images() - Function that builds docker images from source code
+function _build_multicloud_images {
+ install_docker
+ pushd ${src_folders[multicloud]}/openstack/$openstack_release
+ install_python_requirements .
+ python setup.py develop
+ #bash build_image.sh
+ popd
}
# get_multicloud_images() -
function get_multicloud_images {
- echo "pass"
+ if [[ "$build_image" == "True" ]]; then
+ _build_multicloud_images
+ else
+ pull_onap_image multicloud/openstack-$openstack_release
+ fi
}
# install_multicloud() -
function install_multicloud {
- echo "pass"
+ #pushd ${src_folders[multicloud]}/openstack/$openstack_release
+ #/opt/docker/docker-compose up -d
+ #popd
+ if [[ "$build_image" == "True" ]]; then
+ multicloud-api --port 9003 --host 0.0.0.0 &
+ else
+ docker_id=`docker images | grep onap/multicloud/openstack-$openstack_release | grep latest | awk '{print $3; exit}'`
+ docker run -d -p 0.0.0.0:9003:9003 $docker_id
+ fi
}
# init_multicloud() - Function that initialize Multi Cloud services
function init_multicloud {
if [[ "$clone_repo" == "True" ]]; then
- clone_multicloud_repos
+ clone_repos "multicloud"
if [[ "$compile_repo" == "True" ]]; then
- compile_multicloud_repos
+ compile_repos "multicloud"
fi
fi
if [[ "$skip_get_images" == "False" ]]; then