parsing fix
This commit is contained in:
parent
9a2546f897
commit
e2f62a8526
|
|
@ -6,7 +6,7 @@ systemd_version=0
|
||||||
if ! command -V systemctl >/dev/null 2>&1; then
|
if ! command -V systemctl >/dev/null 2>&1; then
|
||||||
use_systemctl="False"
|
use_systemctl="False"
|
||||||
else
|
else
|
||||||
systemd_version=$(systemctl --version | head -1 | sed 's/systemd //g')
|
systemd_version=$(systemctl --version | head -1 | sed 's/systemd //g' | sed 's/ .*//')
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cleanup() {
|
cleanup() {
|
||||||
|
|
@ -49,7 +49,7 @@ cleanInstall() {
|
||||||
else
|
else
|
||||||
# rhel/centos7 cannot use ExecStartPre=+ to specify the pre start should be run as root
|
# rhel/centos7 cannot use ExecStartPre=+ to specify the pre start should be run as root
|
||||||
# even if you want your service to run as non root.
|
# even if you want your service to run as non root.
|
||||||
if [ "${systemd_version}" -lt 231 ]; then
|
if [] "${systemd_version}" -lt 231 ]; then
|
||||||
printf "\033[31m systemd version %s is less then 231, fixing the service file \033[0m\n" "${systemd_version}"
|
printf "\033[31m systemd version %s is less then 231, fixing the service file \033[0m\n" "${systemd_version}"
|
||||||
sed -i "s/=+/=/g" /etc/systemd/service/unpoller.service
|
sed -i "s/=+/=/g" /etc/systemd/service/unpoller.service
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue