diff --git a/hack/local-up-cluster.sh b/hack/local-up-cluster.sh index f218465a58..2528fb7e73 100755 --- a/hack/local-up-cluster.sh +++ b/hack/local-up-cluster.sh @@ -318,6 +318,14 @@ cleanup() exit 0 } +function warning { + message=$1 + + echo $(tput bold)$(tput setaf 1) + echo "WARNING: ${message}" + echo $(tput sgr0) +} + function start_etcd { echo "Starting etcd" kube::etcd::start @@ -727,7 +735,20 @@ if [[ "${START_MODE}" != "kubeletonly" ]]; then fi if [[ "${START_MODE}" != "nokubelet" ]]; then - start_kubelet + ## TODO remove this check if/when kubelet is supported on darwin + # Detect the OS name/arch so that we can find our binary + case "$(uname -s)" in + Darwin) + warning "kubelet is not currently supported in darwin, kubelet aborted." + KUBELET_LOG="" + ;; + Linux) + start_kubelet + ;; + *) + echo "Unsupported host OS. Must be Linux or Mac OS X." >&2 + ;; + esac fi if [[ -n "${PSP_ADMISSION}" && "${ENABLE_RBAC}" = true ]]; then @@ -739,3 +760,5 @@ print_success if [[ "${ENABLE_DAEMON}" = false ]]; then while true; do sleep 1; done fi + +