diff --git a/templates/shared/provisioners/generate-version-info.sh b/templates/shared/provisioners/generate-version-info.sh index d6b5b3c44..4670820d2 100644 --- a/templates/shared/provisioners/generate-version-info.sh +++ b/templates/shared/provisioners/generate-version-info.sh @@ -16,14 +16,14 @@ OUTPUT_FILE="$1" sudo rpm --query --all --queryformat '\{"%{NAME}": "%{VERSION}-%{RELEASE}"\}\n' | jq --slurp --sort-keys 'add | {packages:(.)}' > "$OUTPUT_FILE" # binaries -KUBELET_VERSION=$(kubelet --version | awk '{print $2}') +KUBELET_VERSION=$(sudo kubelet --version | awk '{print $2}') if [ "$?" != 0 ]; then echo "unable to get kubelet version" exit 1 fi echo $(jq ".binaries.kubelet = \"$KUBELET_VERSION\"" $OUTPUT_FILE) > $OUTPUT_FILE -CLI_VERSION=$(aws --version | awk '{print $1}' | cut -d '/' -f 2) +CLI_VERSION=$(sudo aws --version | awk '{print $1}' | cut -d '/' -f 2) if [ "$?" != 0 ]; then echo "unable to get aws cli version" exit 1