Fix some errors in IEC installation scripts 66/766/2
authortrevor tao <trevor.tao@arm.com>
Tue, 21 May 2019 07:15:27 +0000 (15:15 +0800)
committerAlexandru Avadanii <Alexandru.Avadanii@enea.com>
Tue, 21 May 2019 13:28:19 +0000 (13:28 +0000)
1. Fix the error of source the wrong config file in startup.sh
2. Fix the error of adding the KUBECONFIG to the ~/.profile, which
would not be sourced when starting a BASH, it should be set in
~/.bashrc.

Change-Id: I98051d824788e9d950dc6b0b0634e08ea6bfe14d
Signed-off-by: trevor tao <trevor.tao@arm.com>
src/foundation/scripts/config [moved from src/foundation/scripts/config.sh with 100% similarity]
src/foundation/scripts/k8s_master.sh

index 1782769..82fc79b 100755 (executable)
@@ -19,9 +19,9 @@ if ! kubectl get nodes; then
 
   if [ "$(id -u)" = 0 ]; then
     echo "export KUBECONFIG=/etc/kubernetes/admin.conf" | \
-      tee -a "${HOME}/.profile"
+      tee -a "${HOME}/.bashrc"
     # shellcheck disable=SC1090
-    source "${HOME}/.profile"
+    source "${HOME}/.bashrc"
   else
     mkdir -p "${HOME}/.kube"
     sudo cp -i /etc/kubernetes/admin.conf "${HOME}/.kube/config"