summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorAustin S. Hemmelgarn <austin@netdata.cloud>2023-03-06 07:13:38 -0500
committerGitHub <noreply@github.com>2023-03-06 07:13:38 -0500
commit0275a0d468d8b41d4b1d84955b99a77c9eed8759 (patch)
tree217b70d3542c28636d56267b91155f4b04daa67f /system
parentbf1a5246047c92528f87006b6ea14ef18bb7a8b9 (diff)
Properly handle service type detection failures when installing as a system service. (#14658)
Diffstat (limited to 'system')
-rwxr-xr-xsystem/install-service.sh.in4
1 files changed, 2 insertions, 2 deletions
diff --git a/system/install-service.sh.in b/system/install-service.sh.in
index e76ac826e5..3784cd1fd9 100755
--- a/system/install-service.sh.in
+++ b/system/install-service.sh.in
@@ -644,7 +644,7 @@ detect_linux_svc_type() {
install_linux_service() {
t="$(detect_linux_svc_type)"
- if [ -z "${t}" ]; then
+ if [ -z "${t}" ] || [ "${t}" = 'detect' ]; then
exit 2
fi
@@ -654,7 +654,7 @@ install_linux_service() {
linux_cmds() {
t="$(detect_linux_svc_type)"
- if [ -z "${t}" ]; then
+ if [ -z "${t}" ] || [ "${t}" = 'detect' ]; then
exit 2
fi