summaryrefslogtreecommitdiffstats
path: root/vagrant/installer.sh
diff options
context:
space:
mode:
authorVictor Morales <victor.morales@intel.com>2018-11-16 08:29:07 -0800
committerVictor Morales <victor.morales@intel.com>2018-11-20 07:57:26 -0800
commit04f9ce6f4f7d399105172ba841fefa6e376f2572 (patch)
treec86c0455679c15082dfb9b66937c1f709021f802 /vagrant/installer.sh
parent1b76b8fada122365b9adf99cc305721cc114d30a (diff)
Document All-in-One Bare-Metal provisioning
This document describe the proces to do an All-in-One deployment in a Bare-Metal deployment, listing the Hardware and Software minimal requirements, it also uses the aio.sh bash script for reducing the number of manual steps. Vagrantfile and installer.sh has been modified to disable functional tests by default and includes the passwordless sudo verification. Change-Id: Iec7b0bb37d2a46342e6b7e60bed37dbdf2019a10 Signed-off-by: Victor Morales <victor.morales@intel.com> Issue-ID: MULTICLOUD-408
Diffstat (limited to 'vagrant/installer.sh')
-rwxr-xr-xvagrant/installer.sh16
1 files changed, 13 insertions, 3 deletions
diff --git a/vagrant/installer.sh b/vagrant/installer.sh
index b621afaa..860f63d6 100755
--- a/vagrant/installer.sh
+++ b/vagrant/installer.sh
@@ -158,7 +158,7 @@ function install_plugin {
pushd $GOPATH/src/k8-plugin-multicloud/deployments
./build.sh
- if [[ "${testing_enabled}" = "true" ]]; then
+ if [[ "${testing_enabled}" == "true" ]]; then
docker-compose up -d
pushd $krd_tests
for functional_test in plugin plugin_edgex; do
@@ -187,6 +187,16 @@ function _print_kubernetes_info {
echo "Admin password: secret" >> $k8s_info_file
}
+if ! sudo -n "true"; then
+ echo ""
+ echo "passwordless sudo is needed for '$(id -nu)' user."
+ echo "Please fix your /etc/sudoers file. You likely want an"
+ echo "entry like the following one..."
+ echo ""
+ echo "$(id -nu) ALL=(ALL) NOPASSWD: ALL"
+ exit 1
+fi
+
if [[ -n "${KRD_DEBUG}" ]]; then
set -o xtrace
verbose="-vvv"
@@ -200,7 +210,7 @@ krd_inventory=$krd_inventory_folder/hosts.ini
krd_playbooks=$krd_folder/playbooks
krd_tests=$krd_folder/tests
k8s_info_file=$krd_folder/k8s_info.log
-testing_enabled=${KRD_ENABLE_TESTS:-true}
+testing_enabled=${KRD_ENABLE_TESTS:-false}
mkdir -p $log_folder
mkdir -p /opt/csar
@@ -216,7 +226,7 @@ fi
apt-get update
install_k8s
install_addons
-if [[ "${KRD_PLUGIN_ENABLED:-true}" ]]; then
+if [[ "${KRD_PLUGIN_ENABLED:-false}" ]]; then
install_plugin
fi
_print_kubernetes_info