fix: pip config set global.break-system-packages true for non venv installs (#4692)

This commit is contained in:
openoms 2024-08-15 13:03:31 +02:00 committed by GitHub
parent f12c4738c0
commit a14cdc94d2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 4 additions and 0 deletions

View file

@ -18,6 +18,7 @@ if [ "$1" = "on" ];then
if [ ! -f "/home/bitcoin/cl-plugins-available/plugins/${plugin}/${plugin}.py" ]; then if [ ! -f "/home/bitcoin/cl-plugins-available/plugins/${plugin}/${plugin}.py" ]; then
cd /home/bitcoin/cl-plugins-available || exit 1 cd /home/bitcoin/cl-plugins-available || exit 1
sudo -u bitcoin git clone https://github.com/lightningd/plugins.git sudo -u bitcoin git clone https://github.com/lightningd/plugins.git
sudo -u bitcoin pip config set global.break-system-packages true
sudo -u bitcoin pip install -r /home/bitcoin/cl-plugins-available/plugins/${plugin}/requirements.txt sudo -u bitcoin pip install -r /home/bitcoin/cl-plugins-available/plugins/${plugin}/requirements.txt
fi fi
if [ ! -L /home/bitcoin/${netprefix}cl-plugins-enabled/${plugin}.py ];then if [ ! -L /home/bitcoin/${netprefix}cl-plugins-enabled/${plugin}.py ];then

View file

@ -45,6 +45,7 @@ if [ "$1" = "on" ]; then
else else
if [ $($lightningcli_alias | grep -c "/${plugin}") -eq 0 ]; then if [ $($lightningcli_alias | grep -c "/${plugin}") -eq 0 ]; then
echo "# Just start the ${plugin} plugin" echo "# Just start the ${plugin} plugin"
sudo -u bitcoin pip config set global.break-system-packages true
sudo -u bitcoin pip install -r /home/bitcoin/cl-plugins-available/plugins/${plugin}/requirements.txt sudo -u bitcoin pip install -r /home/bitcoin/cl-plugins-available/plugins/${plugin}/requirements.txt
$lightningcli_alias plugin start /home/bitcoin/cl-plugins-available/plugins/${plugin}/${plugin}.py $lightningcli_alias plugin start /home/bitcoin/cl-plugins-available/plugins/${plugin}/${plugin}.py
fi fi

View file

@ -217,6 +217,7 @@ if [ "$1" = "new" ] || [ "$1" = "new-force" ] || [ "$1" = "seed" ] || [ "$1" = "
# check for https://github.com/trezor/python-mnemonic # check for https://github.com/trezor/python-mnemonic
if [ $(pip list | grep -c mnemonic) -eq 0 ];then if [ $(pip list | grep -c mnemonic) -eq 0 ];then
pip config set global.break-system-packages true
pip install mnemonic==0.19 1>/dev/null pip install mnemonic==0.19 1>/dev/null
fi fi

View file

@ -490,6 +490,7 @@ alias ${netprefix}lndconf=\"sudo nano /home/bitcoin/.lnd/${netprefix}lnd.conf\"\
fi fi
# needed to make lnd.newwallet.py work # needed to make lnd.newwallet.py work
pip config set global.break-system-packages true
pip install --upgrade google-api-python-client pip install --upgrade google-api-python-client
exit 0 exit 0