Merge "Use Multi-arch etcd yaml to support Calico"
[iec.git] / src / foundation / scripts / nginx.sh
index 40a9377..3e419b9 100755 (executable)
@@ -36,6 +36,11 @@ spec:
         - containerPort: 80
 EOF
 
+if [ -f "$HOME/.bashrc" ]; then
+  # shellcheck source=/dev/null
+  source "$HOME/.bashrc"
+fi
+
 if ! kubectl get services | grep -q nginx; then
   kubectl create -f "${NGINX_APP}"
 fi
@@ -57,8 +62,9 @@ done
 
 svcip=$(kubectl get services nginx  -o json | grep clusterIP | cut -f4 -d'"')
 sleep 10
-wget "http://$svcip"
+wget -O /dev/null "http://$svcip"
 kubectl delete -f "${NGINX_APP}"
+rm -f "${NGINX_APP}"
 kubectl get rc
 kubectl get pods
 kubectl get services