1 ########################################################################################
2 # This script wraps {$OOM}/kubernetes/config/createConfig.sh script #
3 # and will only terminated when the configuration is Completed or failed #
5 # To run it, just enter the following command: #
6 # ./autoCreateConfig.bash <namespace, default is "onap"> #
7 ########################################################################################
14 echo "Namespace is not specified, use onap namespace."
18 echo "Create $NS config under config directory..."
20 ./createConfig.sh -n $NS
24 echo "...done : kubectl get namespace
25 -----------------------------------------------
26 >>>>>>>>>>>>>> k8s namespace"
31 -----------------------------------------------
32 >>>>>>>>>>>>>> helm : helm ls --all"
37 -----------------------------------------------
38 >>>>>>>>>>>>>> pod : kubectl get pods -n $NS -a"
39 kubectl get pods -n $NS -a
44 echo "wait for $NS config pod reach to Completed STATUS"
46 echo "-----------------------------------------------"
47 kubectl get pods -n $NS -a
49 status=`kubectl get pods -n $NS -a |grep config |xargs echo | cut -d' ' -f3`
51 if [ "$status" = "Completed" ]
53 echo "$NS config is Completed!!!"
57 if [ "$status" = "Error" ]
60 $NS config is failed with Error!!!
62 kubectl logs config -n $NS -f