summaryrefslogtreecommitdiffstats
path: root/netdata-installer.sh
diff options
context:
space:
mode:
authorAustin S. Hemmelgarn <austin@netdata.cloud>2023-02-16 07:31:06 -0500
committerGitHub <noreply@github.com>2023-02-16 07:31:06 -0500
commit5c7bd2c6488cd19fa4a0eb435221223ea5e7de81 (patch)
tree68ca846d6778b3f161a4fad6d44c411d649820b3 /netdata-installer.sh
parentfe5f3b64927e9efb26bdf6d6401e6cd078b738ea (diff)
Assorted shellcheck cleanup. (#14524)
* Add shellcheck config file to globally disable dead code checks. These checks have an extremely high false positive rate and even when they’re correctly flagging code the impact is generally very low. * Fix assorted shellcheck errors in installer code. This should make reviewing PRs relating to this code much easier. * Make shellcheck quit complaining about shellcheckrc formatting.
Diffstat (limited to 'netdata-installer.sh')
-rwxr-xr-xnetdata-installer.sh12
1 files changed, 6 insertions, 6 deletions
diff --git a/netdata-installer.sh b/netdata-installer.sh
index e45eead14b..384af100a4 100755
--- a/netdata-installer.sh
+++ b/netdata-installer.sh
@@ -788,7 +788,7 @@ copy_libbpf() {
}
bundle_libbpf() {
- if { [ -n "${NETDATA_DISABLE_EBPF}" ] && [ ${NETDATA_DISABLE_EBPF} = 1 ]; } || [ "$(uname -s)" != Linux ]; then
+ if { [ -n "${NETDATA_DISABLE_EBPF}" ] && [ "${NETDATA_DISABLE_EBPF}" = 1 ]; } || [ "$(uname -s)" != Linux ]; then
return 0
fi
@@ -822,14 +822,14 @@ bundle_libbpf() {
rm -rf "${tmp}"; then
run_ok "libbpf built and prepared."
else
- if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ ${NETDATA_DISABLE_EBPF} = 0 ]; then
+ if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ "${NETDATA_DISABLE_EBPF}" = 0 ]; then
fatal "failed to build libbpf." I0005
else
run_failed "Failed to build libbpf. eBPF support will be disabled"
fi
fi
else
- if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ ${NETDATA_DISABLE_EBPF} = 0 ]; then
+ if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ "${NETDATA_DISABLE_EBPF}" = 0 ]; then
fatal "Failed to fetch sources for libbpf." I0006
else
run_failed "Unable to fetch sources for libbpf. eBPF support will be disabled"
@@ -846,7 +846,7 @@ copy_co_re() {
}
bundle_ebpf_co_re() {
- if { [ -n "${NETDATA_DISABLE_EBPF}" ] && [ ${NETDATA_DISABLE_EBPF} = 1 ]; } || [ "$(uname -s)" != Linux ]; then
+ if { [ -n "${NETDATA_DISABLE_EBPF}" ] && [ "${NETDATA_DISABLE_EBPF}" = 1 ]; } || [ "$(uname -s)" != Linux ]; then
return 0
fi
@@ -869,7 +869,7 @@ bundle_ebpf_co_re() {
rm -rf "${tmp}"; then
run_ok "libbpf built and prepared."
else
- if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ ${NETDATA_DISABLE_EBPF} = 0 ]; then
+ if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ "${NETDATA_DISABLE_EBPF}" = 0 ]; then
fatal "Failed to get eBPF CO-RE files." I0007
else
run_failed "Failed to get eBPF CO-RE files. eBPF support will be disabled"
@@ -878,7 +878,7 @@ bundle_ebpf_co_re() {
fi
fi
else
- if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ ${NETDATA_DISABLE_EBPF} = 0 ]; then
+ if [ -n "${NETDATA_DISABLE_EBPF}" ] && [ "${NETDATA_DISABLE_EBPF}" = 0 ]; then
fatal "Failed to fetch eBPF CO-RE files." I0008
else
run_failed "Failed to fetch eBPF CO-RE files. eBPF support will be disabled"