From 7ed26009c38388575fc492bf00fe021e2fc5b4d4 Mon Sep 17 00:00:00 2001 From: Christoph Date: Mon, 14 May 2018 03:11:41 +0200 Subject: [PATCH] Fix error in determin apache2 systemd service file. runs into an error, if apache2 was installed from debian package system. --- install_postfixadmin.sh | 4 ++-- install_roundcube.sh | 4 ++-- upgrade_roundcube.sh | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/install_postfixadmin.sh b/install_postfixadmin.sh index 8719a35..d95e2a4 100755 --- a/install_postfixadmin.sh +++ b/install_postfixadmin.sh @@ -147,11 +147,11 @@ if $systemd_supported ; then # - Is Service exclusive controlled by systemd # - if systemctl -t service list-unit-files \ - | grep -e "^apache" \ + | grep -e "^apache2.service" \ | grep -q -E "(enabled|disabled)" 2> /devnull ; then APACHE_SERVICE_FILE=$(systemctl -t service list-unit-files \ - | grep -e "^apache" \ + | grep -e "^apache2.service" \ | awk '{print$1}') fi diff --git a/install_roundcube.sh b/install_roundcube.sh index 3e7c1b5..b880e55 100755 --- a/install_roundcube.sh +++ b/install_roundcube.sh @@ -108,11 +108,11 @@ if $systemd_supported ; then # - Is Service exclusive controlled by systemd # - if systemctl -t service list-unit-files \ - | grep -e "^apache" \ + | grep -e "^apache2.service" \ | grep -q -E "(enabled|disabled)" 2> /devnull ; then APACHE_SERVICE_FILE=$(systemctl -t service list-unit-files \ - | grep -e "^apache" \ + | grep -e "^apache2.service" \ | awk '{print$1}') fi diff --git a/upgrade_roundcube.sh b/upgrade_roundcube.sh index b4dd710..56915ba 100755 --- a/upgrade_roundcube.sh +++ b/upgrade_roundcube.sh @@ -112,11 +112,11 @@ if $systemd_supported ; then # - Is Service exclusive controlled by systemd # - if systemctl -t service list-unit-files \ - | grep -e "^apache" \ + | grep -e "^apache2.service" \ | grep -q -E "(enabled|disabled)" 2> /devnull ; then APACHE_SERVICE_FILE=$(systemctl -t service list-unit-files \ - | grep -e "^apache" \ + | grep -e "^apache2.service" \ | awk '{print$1}') fi