Skip to content

Commit

Permalink
Fix install script for minikube 0.24.x (Kube 1.8.0) (#207)
Browse files Browse the repository at this point in the history
  • Loading branch information
tamalsaha authored Mar 29, 2018
1 parent eec02c4 commit ad364c8
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions deploy/kubedb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,7 @@ export KUBEDB_UNINSTALL=0
export KUBEDB_PURGE=0

KUBE_APISERVER_VERSION=$(kubectl version -o=json | $ONESSL jsonpath '{.serverVersion.gitVersion}')
$ONESSL semver --check='>=1.9.0' $KUBE_APISERVER_VERSION
if [ $? -eq 0 ]; then
export KUBEDB_ENABLE_ADMISSION_WEBHOOK=true
fi
$ONESSL semver --check='<1.9.0' $KUBE_APISERVER_VERSION || { export KUBEDB_ENABLE_ADMISSION_WEBHOOK=true; }

show_help() {
echo "kubedb.sh - install kubedb operator"
Expand Down Expand Up @@ -146,8 +143,8 @@ done

if [ "$KUBEDB_UNINSTALL" -eq 1 ]; then
# delete webhooks and apiservices
kubectl delete validatingwebhookconfiguration -l app=kubedb
kubectl delete mutatingwebhookconfiguration -l app=kubedb
kubectl delete validatingwebhookconfiguration -l app=kubedb || true
kubectl delete mutatingwebhookconfiguration -l app=kubedb || true
kubectl delete apiservice -l app=kubedb
# delete kubedb operator
kubectl delete deployment -l app=kubedb --namespace $KUBEDB_NAMESPACE
Expand Down

0 comments on commit ad364c8

Please sign in to comment.