|
|
@ -82,6 +82,10 @@ verify_prereqs() {
|
|
|
|
error_exit "Can't connect to 'docker' daemon."
|
|
|
|
error_exit "Can't connect to 'docker' daemon."
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if docker inspect kubelet >/dev/null 2>&1 ; then
|
|
|
|
|
|
|
|
error_exit "Kubernetes is already running"
|
|
|
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
$KUBECTL version --client >/dev/null || download_kubectl
|
|
|
|
$KUBECTL version --client >/dev/null || download_kubectl
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -99,7 +103,7 @@ get_latest_version_number() {
|
|
|
|
|
|
|
|
|
|
|
|
# Detect ip address od docker host
|
|
|
|
# Detect ip address od docker host
|
|
|
|
detect_docker_host_ip() {
|
|
|
|
detect_docker_host_ip() {
|
|
|
|
if [ -n "${DOCKER_HOST:-}" ]; then
|
|
|
|
if [[ -n "${DOCKER_HOST:-}" ]]; then
|
|
|
|
awk -F'[/:]' '{print $4}' <<< "$DOCKER_HOST"
|
|
|
|
awk -F'[/:]' '{print $4}' <<< "$DOCKER_HOST"
|
|
|
|
else
|
|
|
|
else
|
|
|
|
ifconfig docker0 \
|
|
|
|
ifconfig docker0 \
|
|
|
|