mirror of
https://github.com/bol-van/zapret.git
synced 2024-12-23 14:53:18 +00:00
install_easy: improve openrc detection
This commit is contained in:
parent
8110ea06b9
commit
528328a2b5
@ -209,10 +209,10 @@ check_system()
|
|||||||
# some distros include systemctl without systemd
|
# some distros include systemctl without systemd
|
||||||
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMCTL" ] && [ "$(basename $(readlink /proc/1/exe))" = "systemd" ]; then
|
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMCTL" ] && [ "$(basename $(readlink /proc/1/exe))" = "systemd" ]; then
|
||||||
SYSTEM=systemd
|
SYSTEM=systemd
|
||||||
|
elif exists rc-update && [ "$(basename $(readlink /proc/1/exe))" = "openrc-init" ]; then
|
||||||
|
SYSTEM=openrc
|
||||||
elif [ -f "/etc/openwrt_release" ] && exists opkg && exists uci ; then
|
elif [ -f "/etc/openwrt_release" ] && exists opkg && exists uci ; then
|
||||||
SYSTEM=openwrt
|
SYSTEM=openwrt
|
||||||
elif exists /sbin/openrc-run || exists /usr/sbin/openrc-run ; then
|
|
||||||
SYSTEM=openrc
|
|
||||||
else
|
else
|
||||||
echo system is not either systemd, openrc or openwrt based
|
echo system is not either systemd, openrc or openwrt based
|
||||||
echo easy installer can set up config settings but can\'t configure auto start
|
echo easy installer can set up config settings but can\'t configure auto start
|
||||||
|
@ -56,10 +56,10 @@ check_system()
|
|||||||
# some distros include systemctl without systemd
|
# some distros include systemctl without systemd
|
||||||
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMCTL" ] && [ "$(basename $(readlink /proc/1/exe))" = "systemd" ]; then
|
if [ -d "$SYSTEMD_DIR" ] && [ -x "$SYSTEMCTL" ] && [ "$(basename $(readlink /proc/1/exe))" = "systemd" ]; then
|
||||||
SYSTEM=systemd
|
SYSTEM=systemd
|
||||||
|
elif exists rc-update && [ "$(basename $(readlink /proc/1/exe))" = "openrc-init" ]; then
|
||||||
|
SYSTEM=openrc
|
||||||
elif [ -f "/etc/openwrt_release" ] && exists opkg && exists uci ; then
|
elif [ -f "/etc/openwrt_release" ] && exists opkg && exists uci ; then
|
||||||
SYSTEM=openwrt
|
SYSTEM=openwrt
|
||||||
elif exists /sbin/openrc-run || exists /usr/sbin/openrc-run ; then
|
|
||||||
SYSTEM=openrc
|
|
||||||
else
|
else
|
||||||
echo system is not either systemd, openrc or openwrt based
|
echo system is not either systemd, openrc or openwrt based
|
||||||
echo check readme.txt for manual setup info.
|
echo check readme.txt for manual setup info.
|
||||||
|
Loading…
Reference in New Issue
Block a user