From: garciadeblas Date: Wed, 8 Jul 2020 14:30:29 +0000 (+0000) Subject: full_install_osm.sh: separate taint of master node and deployment of osm X-Git-Tag: release-v9.0-start~73 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=f6ed60ca8f23cc859d43baa6483fd9ddb9db6768;p=osm%2Fdevops.git full_install_osm.sh: separate taint of master node and deployment of osm Change-Id: I6b5b314949d9775b6e71312d97dc293a49385945 Signed-off-by: garciadeblas (cherry picked from commit f7d00303fa336fc223280cceca30a1b3679f6795) --- diff --git a/installers/full_install_osm.sh b/installers/full_install_osm.sh index 06880687..fcb7ec1c 100755 --- a/installers/full_install_osm.sh +++ b/installers/full_install_osm.sh @@ -798,11 +798,15 @@ function kube_secrets(){ kubectl create secret generic pol-secret -n $OSM_STACK_NAME --from-env-file=$OSM_DOCKER_WORK_DIR/pol.env } -#deploys osm pods and services -function deploy_osm_services() { +#taints K8s master node +function taint_master_node() { K8S_MASTER=$(kubectl get nodes | awk '$3~/master/'| awk '{print $1}') kubectl taint node $K8S_MASTER node-role.kubernetes.io/master:NoSchedule- sleep 5 +} + +#deploys osm pods and services +function deploy_osm_services() { kubectl apply -n $OSM_STACK_NAME -f $OSM_K8S_WORK_DIR } @@ -1173,6 +1177,7 @@ EOF kube_secrets [ ! $OSM_DOCKER_TAG == "7" ] && parse_yaml $OSM_DOCKER_TAG namespace_vol + taint_master_node deploy_osm_services if [ -n "$INSTALL_PLA"]; then # optional PLA install