|
|
@ -10,15 +10,15 @@ PROGRAM_BINARY=$PROGRAM".sh"
|
|
|
|
PROGRAM_BATCH=$PROGRAM"-batch.sh"
|
|
|
|
PROGRAM_BATCH=$PROGRAM"-batch.sh"
|
|
|
|
SSH_FILTER="ssh_filter.sh"
|
|
|
|
SSH_FILTER="ssh_filter.sh"
|
|
|
|
|
|
|
|
|
|
|
|
SCRIPT_BUILD=2020112901
|
|
|
|
SCRIPT_BUILD=2023061101
|
|
|
|
INSTANCE_ID="installer-$SCRIPT_BUILD"
|
|
|
|
INSTANCE_ID="installer-$SCRIPT_BUILD"
|
|
|
|
|
|
|
|
|
|
|
|
## osync / obackup / pmocr / zsnap install script
|
|
|
|
## osync / obackup / pmocr / zsnap install script
|
|
|
|
## Tested on RHEL / CentOS 6 & 7, Fedora 23, Debian 7 & 8, Mint 17 and FreeBSD 8, 10 and 11
|
|
|
|
## Tested on RHEL / CentOS 6 & 7, Fedora 23, Debian 7 & 8, Mint 17 and FreeBSD 8, 10 and 11
|
|
|
|
## Please adapt this to fit your distro needs
|
|
|
|
## Please adapt this to fit your distro needs
|
|
|
|
|
|
|
|
|
|
|
|
_OFUNCTIONS_VERSION=2.5.0
|
|
|
|
_OFUNCTIONS_VERSION=2.5.1
|
|
|
|
_OFUNCTIONS_BUILD=2023061001
|
|
|
|
_OFUNCTIONS_BUILD=2023061401
|
|
|
|
_OFUNCTIONS_BOOTSTRAP=true
|
|
|
|
_OFUNCTIONS_BOOTSTRAP=true
|
|
|
|
|
|
|
|
|
|
|
|
if ! type "$BASH" > /dev/null; then
|
|
|
|
if ! type "$BASH" > /dev/null; then
|
|
|
@ -655,15 +655,26 @@ function SetLocalOSSettings {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function GetInit {
|
|
|
|
function GetInit {
|
|
|
|
|
|
|
|
init="none"
|
|
|
|
if [ -f /sbin/openrc-run ]; then
|
|
|
|
if [ -f /sbin/openrc-run ]; then
|
|
|
|
init="openrc"
|
|
|
|
init="openrc"
|
|
|
|
Logger "Detected openrc." "NOTICE"
|
|
|
|
Logger "Detected openrc." "NOTICE"
|
|
|
|
|
|
|
|
elif [ -f /usr/lib/systemd/systemd ]; then
|
|
|
|
|
|
|
|
init="systemd"
|
|
|
|
|
|
|
|
Logger "Detected systemd." "NOTICE"
|
|
|
|
elif [ -f /sbin/init ]; then
|
|
|
|
elif [ -f /sbin/init ]; then
|
|
|
|
if file /sbin/init | grep systemd > /dev/null; then
|
|
|
|
if type -p file > /dev/null 2>&1; then
|
|
|
|
init="systemd"
|
|
|
|
if file /sbin/init | grep systemd > /dev/null; then
|
|
|
|
Logger "Detected systemd." "NOTICE"
|
|
|
|
init="systemd"
|
|
|
|
|
|
|
|
Logger "Detected systemd." "NOTICE"
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
init="initV"
|
|
|
|
|
|
|
|
fi
|
|
|
|
else
|
|
|
|
else
|
|
|
|
init="initV"
|
|
|
|
init="initV"
|
|
|
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ $init == "initV" ]; then
|
|
|
|
Logger "Detected initV." "NOTICE"
|
|
|
|
Logger "Detected initV." "NOTICE"
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
else
|
|
|
|
else
|
|
|
|