mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
apt: always add yarn repo because it's annoying to have to deal with an extra repo in each nodejs app just to install a single package..
This commit is contained in:
parent
2f2ff6eb19
commit
f1200b81dc
1 changed files with 23 additions and 3 deletions
|
@ -23,19 +23,33 @@ Pin-Priority: 500" >>"${pending_dir}/etc/apt/preferences.d/extra_php_version"
|
|||
for package in $packages_to_refuse_from_sury; do
|
||||
echo "
|
||||
Package: $package
|
||||
Pin: origin \"packages.sury.org\"
|
||||
Pin: origin \"packages.sury.org\"
|
||||
Pin-Priority: -1" >>"${pending_dir}/etc/apt/preferences.d/extra_php_version"
|
||||
done
|
||||
|
||||
# Add yarn
|
||||
echo "deb https://dl.yarnpkg.com/debian/ stable main" > "${pending_dir}/etc/apt/sources.list.d/yarn.list"
|
||||
|
||||
# Ban everything from Yarn except Yarn
|
||||
echo "
|
||||
Package: *
|
||||
Pin: origin \"dl.yarnpkg.com\"
|
||||
Pin-Priority: -1
|
||||
|
||||
Package: yarn
|
||||
Pin: origin \"dl.yarnpkg.com\"
|
||||
Pin-Priority: 500" >>"${pending_dir}/etc/apt/preferences.d/yarn"
|
||||
|
||||
# Ban apache2, bind9
|
||||
echo "
|
||||
|
||||
# PLEASE READ THIS WARNING AND DON'T EDIT THIS FILE
|
||||
|
||||
# You are probably reading this file because you tried to install apache2 or
|
||||
# You are probably reading this file because you tried to install apache2 or
|
||||
# bind9. These 2 packages conflict with YunoHost.
|
||||
|
||||
# Installing apache2 will break nginx and break the entire YunoHost ecosystem
|
||||
# on your server, therefore don't remove those lines!
|
||||
# on your server, therefore don't remove those lines!
|
||||
|
||||
# You have been warned.
|
||||
|
||||
|
@ -69,6 +83,12 @@ do_post_regen() {
|
|||
wget --timeout 900 --quiet "https://packages.sury.org/php/apt.gpg" --output-document=- | gpg --dearmor >"/etc/apt/trusted.gpg.d/extra_php_version.gpg"
|
||||
fi
|
||||
|
||||
# Similar to Sury
|
||||
if [[ ! -s /etc/apt/trusted.gpg.d/yarn.gpg ]]
|
||||
then
|
||||
wget --timeout 900 --quiet "https://dl.yarnpkg.com/debian/pubkey.gpg" --output-document=- | gpg --dearmor >"/etc/apt/trusted.gpg.d/yarn.gpg"
|
||||
fi
|
||||
|
||||
# Make sure php7.4 is the default version when using php in cli
|
||||
if test -e /usr/bin/php$YNH_DEFAULT_PHP_VERSION
|
||||
then
|
||||
|
|
Loading…
Add table
Reference in a new issue