blob: 24264ccc9050e4e0ae3a524c1f20ca684888c388 [file] [log] [blame]
Victor Moralesd3cbcf22017-10-25 16:01:58 -07001#!/bin/bash
2
Victor Moralesd3cbcf22017-10-25 16:01:58 -07003source /var/onap/functions
4
5vvp_src_folder=$git_src_folder/vvp
6vvp_repos=("vvp/ansible-ice-bootstrap" "vvp/cms" "vvp/devkit" "vvp/documentation" "vvp/engagementmgr" "vvp/gitlab" "vvp/image-scanner" "vvp/jenkins" "vvp/portal" "vvp/postgresql" "vvp/test-engine" "vvp/validation-scripts")
7
8# clone_all_vvp_repos() - Function that clones vvp source repo.
9function clone_all_vvp_repos {
10 for repo in ${vvp_repos[@]}; do
11 clone_repo $repo $vvp_src_folder${repo#*vvp}
12 done
13}
14
15# compile_all_vvp_repos - Function that builds vvp source repo
16function compile_all_vvp_repos {
17 for repo in ${vvp_repos[@]}; do
18 compile_src $vvp_src_folder${repo#*vvp}
19 done
20}
21
22# _build_vvp_images() - Builds VNFSDK images from source code
23function _build_vvp_images {
24 echo "pass"
25}
26
27# get_vvp_images - Function that clones vvp Docker images
28function get_vvp_images {
29 if [[ "$build_image" == "True" ]]; then
30 _build_vvp_images
31 else
32 pull_docker_image refrepo:1.0-STAGING-latest
33 pull_docker_image refrepo:latest
34 fi
35}
36
37# install_vvp - Function that installs vvp Docker images
38function install_vvp {
39 echo "pass"
40}
41
42# init_vvp() - Init VNFSDK services
43function init_vvp {
44 if [[ "$clone_repo" == "True" ]]; then
45 clone_all_vvp_repos
46 if [[ "$compile_repo" == "True" ]]; then
47 compile_all_vvp_repos
48 fi
49 fi
50
51 if [[ "$skip_get_images" == "False" ]]; then
52 get_vvp_images
53 if [[ "$skip_install" == "False" ]]; then
54 install_vvp
55 fi
56 fi
57}