Fix apt
This commit is contained in:
10
install.sh
10
install.sh
@@ -68,8 +68,8 @@ fi
|
||||
|
||||
case "$OS_ID" in
|
||||
ubuntu|debian|linuxmint)
|
||||
PKG_UPDATE="apt-get update -qq"
|
||||
PKG_INSTALL="DEBIAN_FRONTEND=noninteractive apt-get install -y"
|
||||
PKG_UPDATE="apt update -qq"
|
||||
PKG_INSTALL="DEBIAN_FRONTEND=noninteractive apt install -y"
|
||||
PKG_DEPS="curl wget git rsync build-essential postgresql postgresql-contrib ca-certificates unzip openssh-client openssl iptables nftables"
|
||||
;;
|
||||
centos|rhel|rocky|almalinux)
|
||||
@@ -83,9 +83,9 @@ case "$OS_ID" in
|
||||
PKG_DEPS="curl wget git rsync gcc make postgresql-server postgresql-contrib ca-certificates unzip openssh-clients openssl iptables nftables"
|
||||
;;
|
||||
*)
|
||||
warn "Unknown OS '$OS_ID' — attempting apt-get…"
|
||||
PKG_UPDATE="apt-get update -qq"
|
||||
PKG_INSTALL="DEBIAN_FRONTEND=noninteractive apt-get install -y"
|
||||
warn "Unknown OS '$OS_ID' — attempting apt…"
|
||||
PKG_UPDATE="apt update -qq"
|
||||
PKG_INSTALL="DEBIAN_FRONTEND=noninteractive apt install -y"
|
||||
PKG_DEPS="curl wget git rsync build-essential postgresql postgresql-contrib ca-certificates unzip openssh-client openssl iptables nftables"
|
||||
;;
|
||||
esac
|
||||
|
||||
12
update.sh
12
update.sh
@@ -84,9 +84,9 @@ install_git_if_missing() {
|
||||
return 0
|
||||
fi
|
||||
warn "git is not installed. Trying to install it..."
|
||||
if command -v apt-get >/dev/null 2>&1; then
|
||||
apt-get update -qq
|
||||
DEBIAN_FRONTEND=noninteractive apt-get install -y git ca-certificates
|
||||
if command -v apt >/dev/null 2>&1; then
|
||||
apt update -qq
|
||||
DEBIAN_FRONTEND=noninteractive apt install -y git ca-certificates
|
||||
elif command -v dnf >/dev/null 2>&1; then
|
||||
dnf install -y git ca-certificates
|
||||
elif command -v yum >/dev/null 2>&1; then
|
||||
@@ -458,9 +458,9 @@ info "[0/7] Pre-flight checks..."
|
||||
need_cmd python3
|
||||
if ! command -v rsync >/dev/null 2>&1; then
|
||||
warn "rsync is not installed. Trying to install it..."
|
||||
if command -v apt-get >/dev/null 2>&1; then
|
||||
apt-get update -qq
|
||||
DEBIAN_FRONTEND=noninteractive apt-get install -y rsync
|
||||
if command -v apt >/dev/null 2>&1; then
|
||||
apt update -qq
|
||||
DEBIAN_FRONTEND=noninteractive apt install -y rsync
|
||||
elif command -v dnf >/dev/null 2>&1; then
|
||||
dnf install -y rsync
|
||||
elif command -v yum >/dev/null 2>&1; then
|
||||
|
||||
Reference in New Issue
Block a user