Add default version to scripts

This commit is contained in:
harry
2015-09-07 14:16:45 +08:00
committed by Harry Zhang
parent 8cc75a4734
commit 365562c0b9
3 changed files with 13 additions and 6 deletions

View File

@@ -27,8 +27,8 @@ fi
# Make sure k8s version env is properly set
if [ -z ${K8S_VERSION} ]; then
echo "Please export K8S_VERSION in your env"
exit 1
K8S_VERSION="1.0.3"
echo "K8S_VERSION is not set, using default: ${K8S_VERSION}"
else
echo "k8s version is set to: ${K8S_VERSION}"
fi

View File

@@ -27,13 +27,14 @@ fi
# Make sure k8s version env is properly set
if [ -z ${K8S_VERSION} ]; then
echo "Please export K8S_VERSION in your env"
exit 1
K8S_VERSION="1.0.3"
echo "K8S_VERSION is not set, using default: ${K8S_VERSION}"
else
echo "k8s version is set to: ${K8S_VERSION}"
fi
# Run as root
if [ "$(id -u)" != "0" ]; then
echo >&2 "Please run as root"