Adding suuport for OS Devuan

This commit is contained in:
smwltr 2016-04-12 12:18:47 +09:00
parent b12df5f125
commit 1882040a25
21 changed files with 29 additions and 21 deletions

View File

@ -49,6 +49,11 @@ if [ -f /etc/debian_version ]; then
echo debian
exit 0
fi
if [ -f /etc/devuan_version ]; then
echo devuan
exit 0
fi
###
if [ -f /etc/gentoo-release ]; then

View File

@ -33,6 +33,9 @@ case "$($__explorer/os)" in
debian)
cat /etc/debian_version
;;
devuan)
cat /etc/devuan_version
;;
fedora)
cat /etc/fedora-release
;;

View File

@ -22,7 +22,7 @@
os=$(cat "$__global/explorer/os")
case "$os" in
ubuntu|debian)
ubuntu|debian|devuan)
# No stinking recommends thank you very much.
# If I want something installed I will do so myself.
__file /etc/apt/apt.conf.d/99-no-recommends \

View File

@ -35,7 +35,7 @@ has_hostnamectl=$(cat "$__object/explorer/has_hostnamectl")
# If everything is ok -> exit
#
case "$os" in
archlinux|debian|suse|ubuntu)
archlinux|debian|suse|ubuntu|devuan)
if [ "$name_config" = "$name_should" -a "$name_running" = "$name_should" ]; then
exit 0
fi
@ -60,7 +60,7 @@ if [ "$has_hostnamectl" ]; then
echo "hostnamectl set-hostname '$name_should'"
else
case "$os" in
archlinux|debian|ubuntu)
archlinux|debian|ubuntu|devuan)
echo "hostname '$name_should'"
echo "printf '%s\n' '$name_should' > /etc/hostname"
;;

View File

@ -34,7 +34,7 @@ not_supported() {
}
case "$os" in
archlinux|debian|suse|ubuntu)
archlinux|debian|suse|ubuntu|devuan)
# handled in gencode-remote
:
;;

View File

@ -26,7 +26,7 @@ os=$(cat "$__global/explorer/os")
case "$os" in
debian)
debian|devuan)
# Debian needs a seperate package
__package locales --state present
;;

View File

@ -22,8 +22,8 @@
os=$(cat "$__global/explorer/os")
case "$os" in
debian|ubuntu)
debian|ubuntu|devuan)
# Debian and Ubuntu need to be updated,
# as seen in /etc/init.d/bootlogs
echo "uname -snrvm > /var/run/motd"

View File

@ -30,7 +30,7 @@ os=$(cat "$__global/explorer/os")
case "$os" in
debian|ubuntu)
debian|ubuntu|devuan)
destination=/etc/motd.tail
;;
*)

View File

@ -32,7 +32,7 @@ else
case "$os" in
amazon|centos|fedora|redhat) type="yum" ;;
archlinux) type="pacman" ;;
debian|ubuntu) type="apt" ;;
debian|ubuntu|devuan) type="apt" ;;
freebsd)
if [ -n "$(cat "$__object/explorer/pkgng_exists")" ]; then
type="pkgng_freebsd"

View File

@ -30,7 +30,7 @@ else
os="$(cat "$__global/explorer/os")"
case "$os" in
amazon|centos|fedora|redhat) type="yum" ;;
debian|ubuntu) type="apt" ;;
debian|ubuntu|devuan) type="apt" ;;
archlinux) type="pacman" ;;
*)
echo "Don't know how to manage packages on: $os" >&2

View File

@ -31,7 +31,7 @@ else
os="$(cat "$__global/explorer/os")"
case "$os" in
amazon|centos|fedora|redhat) type="yum" ;;
debian|ubuntu) type="apt" ;;
debian|ubuntu|devuan) type="apt" ;;
archlinux) type="pacman" ;;
*)
echo "Don't know how to manage packages on: $os" >&2

View File

@ -22,7 +22,7 @@
os=$(cat "$__global/explorer/os")
case "$os" in
ubuntu|debian|archlinux|suse|centos)
ubuntu|debian|archlinux|suse|centos|devuan)
__package postfix --state present
;;
*)

View File

@ -22,7 +22,7 @@
os=$(cat "$__global/explorer/os")
case "$os" in
ubuntu|debian|archlinux|centos)
ubuntu|debian|archlinux|centos|devuan)
:
;;
*)

View File

@ -22,7 +22,7 @@
os=$("$__explorer/os")
case "$os" in
ubuntu|debian|archlinux|suse|centos)
ubuntu|debian|archlinux|suse|centos|devuan)
:
;;
*)

View File

@ -21,7 +21,7 @@
os=$(cat "$__global/explorer/os")
case "$os" in
ubuntu|debian|archlinux|suse|centos)
ubuntu|debian|archlinux|suse|centos|devuan)
:
;;
*)

View File

@ -22,7 +22,7 @@
os=$(cat "$__global/explorer/os")
case "$os" in
ubuntu|debian|archlinux|centos)
ubuntu|debian|archlinux|centos|devuan)
echo "postfix reload"
;;
*)

View File

@ -37,7 +37,7 @@ if [ "$init" = 'systemd' ]; then
else
case "$os" in
debian|openwrt)
debian|openwrt|devuan)
state="present"
[ -f "/etc/rc$runlevel.d/S"??"$name" ] || state="absent"
;;

View File

@ -24,7 +24,7 @@ timezone="$__object_id"
os=$(cat "$__global/explorer/os")
case "$os" in
ubuntu|debian)
ubuntu|debian|devuan)
echo "echo \"$timezone\" > /etc/timezone"
;;
esac

View File

@ -26,7 +26,7 @@ timezone="$__object_id"
os=$(cat "$__global/explorer/os")
case "$os" in
archlinux|debian|ubuntu)
archlinux|debian|ubuntu|devuan)
__package tzdata
export require="__package/tzdata"
;;

View File

@ -23,7 +23,7 @@
os=$(cat "$__global/explorer/os")
case "$os" in
ubuntu|debian|archlinux)
ubuntu|debian|archlinux|devuan)
__package autofs --state present
__start_on_boot autofs --state present
;;

View File

@ -28,7 +28,7 @@ not_supported() {
}
case "$os" in
ubuntu|debian|archlinux)
ubuntu|debian|archlinux|devuan)
echo "pkill -HUP automount"
;;
*)