mirror of
https://github.com/bol-van/zapret.git
synced 2024-11-30 05:50:53 +03:00
install_easy: improve systemd detection
This commit is contained in:
parent
49027e141f
commit
65165e536c
@ -158,7 +158,7 @@ check_system()
|
||||
local UNAME=$(uname)
|
||||
if [ "$UNAME" = "Linux" ]; then
|
||||
# some distros include systemctl without systemd
|
||||
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMD_DIR/systemd" ] && [ -x "$SYSTEMCTL" ]; then
|
||||
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMCTL" ] && [ "$(basename $(readlink /proc/1/exe))" = "systemd" ]; then
|
||||
SYSTEM=systemd
|
||||
elif [ -f "/etc/openwrt_release" ] && exists opkg && exists uci ; then
|
||||
SYSTEM=openwrt
|
||||
|
@ -54,7 +54,7 @@ check_system()
|
||||
local UNAME=$(uname)
|
||||
if [ "$UNAME" = "Linux" ]; then
|
||||
# some distros include systemctl without systemd
|
||||
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMD_DIR/systemd" ] && [ -x "$SYSTEMCTL" ]; then
|
||||
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMCTL" ] && [ "$(basename $(readlink /proc/1/exe))" = "systemd" ]; then
|
||||
SYSTEM=systemd
|
||||
elif [ -f "/etc/openwrt_release" ] && exists opkg && exists uci ; then
|
||||
SYSTEM=openwrt
|
||||
|
Loading…
Reference in New Issue
Block a user