From f6dbe2829b8ca19bfc0def871036c50642de7770 Mon Sep 17 00:00:00 2001 From: Victor Morales Date: Mon, 5 Mar 2018 10:58:15 -0800 Subject: Move src_folder The SDC simultator mentions[1] the usage of ChefDK as part of tools for installation/development. The installation process uses the /opt/ folder as destionation and it's affected by the sharing process. This patchset changes the destionation folder for all the ONAP projects. [1] https://git.onap.org/sdc/tree/utils/webseal-simulator/sdc-simulator/chef-solo/README.md#n4 Change-Id: Ib800c48864ce2cbe49e699a6d6e913be137af949 Signed-off-by: Victor Morales Issue-ID: INT-214 --- bootstrap/vagrant-onap/lib/functions | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'bootstrap/vagrant-onap/lib/functions') diff --git a/bootstrap/vagrant-onap/lib/functions b/bootstrap/vagrant-onap/lib/functions index 79a80c6b0..f40761f59 100755 --- a/bootstrap/vagrant-onap/lib/functions +++ b/bootstrap/vagrant-onap/lib/functions @@ -293,6 +293,33 @@ function install_docker_compose { fi } +# install_chefdk() - Install ChefDK package +function install_chefdk { + local chefdk_version="2.4.17" + + if is_package_installed chefdk; then + return + fi + pushd $(mktemp -d) + source /etc/os-release || source /usr/lib/os-release + case ${ID,,} in + *suse) + ;; + ubuntu|debian) + chefdk_pkg="chefdk_$chefdk_version-1_amd64.deb" + chefdk_url="https://packages.chef.io/files/stable/chefdk/$chefdk_version/ubuntu/$VERSION_ID/$chefdk_pkg" + + wget $chefdk_url + dpkg -i $chefdk_pkg + apt-get install -f -y + ;; + rhel|centos|fedora) + rpm -Uvh "https://packages.chef.io/files/stable/chefdk/$chefdk_version/el/7/chefdk-$chefdk_version-1.el7.x86_64.rpm" + ;; + esac + popd +} + # _install_ODL() - Download and Install OpenDayLight SDN controller function _install_ODL { if [ ! -d /opt/opendaylight/current ]; then -- cgit 1.2.3-korg