From b966ad18dae03223c3d02341f3fde04dd16d5f17 Mon Sep 17 00:00:00 2001 From: Eric Leu Date: Sun, 31 May 2020 14:48:10 -0700 Subject: [PATCH] update install.sh to respect K3S_TOKEN_FILE --- install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install.sh b/install.sh index f72331b058..4c348bfbd5 100755 --- a/install.sh +++ b/install.sh @@ -150,8 +150,8 @@ setup_env() { if [ -z "${K3S_URL}" ]; then CMD_K3S=server else - if [ -z "${K3S_TOKEN}" ] && [ -z "${K3S_CLUSTER_SECRET}" ]; then - fatal "Defaulted k3s exec command to 'agent' because K3S_URL is defined, but K3S_TOKEN or K3S_CLUSTER_SECRET is not defined." + if [ -z "${K3S_TOKEN}" ] && [ -z "${K3S_TOKEN_FILE}" ] && [ -z "${K3S_CLUSTER_SECRET}" ]; then + fatal "Defaulted k3s exec command to 'agent' because K3S_URL is defined, but K3S_TOKEN, K3S_TOKEN_FILE or K3S_CLUSTER_SECRET is not defined." fi CMD_K3S=agent fi