@cryptotaxi247 / netdata-1 / commits / 160173934

Fix handling of disabling telemetry in static builds. (#11689)

Austin S. Hemmelgarn committed Oct 21, 2021 at 07:21 UTC 160173934b43d4129fdb59024bd30f4e58e818fd
1 file changed +3 -1
packaging/makeself/install-or-update.sh
+3 -1
@@ -49,6 +49,7 @@ while [ "${1}" ]; do
49 REINSTALL_OPTIONS="${REINSTALL_OPTIONS} ${1}"
50 ;;
51 "--disable-telemetry")
52 + NETDATA_DISABLE_TELEMETRY=1
53 REINSTALL_OPTIONS="${REINSTALL_OPTIONS} ${1}"
54 ;;
55
@@ -58,6 +59,7 @@ while [ "${1}" ]; do
59 done
60
61 if [ ! "${DO_NOT_TRACK:-0}" -eq 0 ] || [ -n "$DO_NOT_TRACK" ]; then
62 + NETDATA_DISABLE_TELEMETRY=1
63 REINSTALL_OPTIONS="${REINSTALL_OPTIONS} --disable-telemetry"
64 fi
65
@@ -138,7 +140,7 @@ install_netdata_logrotate || run_failed "Cannot install logrotate file for netda
140 progress "Telemetry configuration"
141
142 # Opt-out from telemetry program
141 -if [ -n "${NETDATA_DISABLE_TELEMETRY+x}" ]; then
143 +if [ -n "${NETDATA_DISABLE_TELEMETRY}" ]; then
144 run touch "${NETDATA_USER_CONFIG_DIR}/.opt-out-from-anonymous-statistics"
145 else
146 printf "You can opt out from anonymous statistics via the --disable-telemetry option, or by creating an empty file %s \n\n" "${NETDATA_USER_CONFIG_DIR}/.opt-out-from-anonymous-statistics"