Update 'Setup-Repo.sh'

This commit is contained in:
Bram Prieshof
2020-09-24 13:01:08 +02:00
parent c41da48da9
commit c0c14e0ff6

View File

@@ -7,9 +7,9 @@ dist_name=$(grep -oP '(?<=^VERSION_CODENAME=).+' /etc/os-release | tr -d '"')
init () {
if [ "$osrel" = "ubu1804" ] || [ "$osrel" = "ubu2004" ] ; then
$PKGI software-properties-common gnupg > $OUTPUT 2>&1
$PKGI software-properties-common gnupg
elif [ "$osrel" = "deb10" ]; then
$PKGI gnupg2 apt-transport-https lsb-release ca-certificates curl > $OUTPUT 2>&1
$PKGI gnupg2 apt-transport-https lsb-release ca-certificates curl
elif [ "$osrel" = "cent8" ]; then
$PKGI gnupg
fi
@@ -40,7 +40,7 @@ fi
universe () {
if [ "$osrel" = "ubu1804" ] || [ "$osrel" = "ubu2004" ] ; then
add-apt-repository --no-update universe -y -n > $OUTPUT 2>&1
add-apt-repository --no-update universe -y -n
fi
}
@@ -57,7 +57,7 @@ fi
apache () {
if [ "$osrel" = "ubu1804" ] || [ "$osrel" = "ubu2004" ] ; then
add-apt-repository --no-update ppa:ondrej/apache2 -y -n > $OUTPUT 2>&1
add-apt-repository --no-update ppa:ondrej/apache2 -y -n
elif [ "$osrel" = "deb10" ]; then
wget -O /etc/apt/trusted.gpg.d/apache2.gpg https://packages.sury.org/apache2/apt.gpg
echo "deb https://packages.sury.org/apache2/ "$dist_name" main" > /etc/apt/sources.list.d/apache2.list
@@ -87,7 +87,7 @@ fi
php () {
if [ "$osrel" = "ubu1804" ] || [ "$osrel" = "ubu2004" ] ; then
add-apt-repository --no-update ppa:ondrej/php -y -n > $OUTPUT 2>&1
add-apt-repository --no-update ppa:ondrej/php -y -n
elif [ "$osrel" = "deb10" ]; then
wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg
echo "deb https://packages.sury.org/php/ "$dist_name" main" > /etc/apt/sources.list.d/php.list
@@ -98,7 +98,7 @@ fi
certbot () {
if [ "$osrel" = "ubu1804" ] ; then
add-apt-repository --no-update ppa:certbot/certbot -y -n > $OUTPUT 2>&1
add-apt-repository --no-update ppa:certbot/certbot -y -n
fi
}
@@ -107,7 +107,7 @@ fi
redis () {
if [ "$osrel" = "ubu1804" ] || [ "$osrel" = "ubu2004" ] ; then
add-apt-repository --no-update ppa:chris-lea/redis-server -y -n > $OUTPUT 2>&1
add-apt-repository --no-update ppa:chris-lea/redis-server -y -n
fi
}