From df7d41bfc7f26460ba5bb6f0a209b02c778ed312 Mon Sep 17 00:00:00 2001 From: fred Date: Mon, 27 Feb 2023 15:49:04 +0100 Subject: [PATCH] setup is for resetting IPFSNODEID & check tools are working --- install.sh | 17 ----------------- setup.sh | 40 +++++++++++++++++++++++----------------- tools/ipfs_setup.sh | 17 +++++++++++++++++ 3 files changed, 40 insertions(+), 34 deletions(-) diff --git a/install.sh b/install.sh index ba76f895..034433d6 100755 --- a/install.sh +++ b/install.sh @@ -213,23 +213,6 @@ echo " ### EXPERIMENTAL ### FINISH ASTROPORT/KODI SETUP BY IPFS ## OUI ? ENTER s && sudo ln -s ~/.zen/Astroport.ONE/tools/download_from_kodi_log.sh /usr/local/bin/download_from_kodi_log \ || echo "SOMETHING IS NOT WORKING WELL : PLEASE CREATE AN ISSSUE" - ######################################################################## - echo "ADDING nameserver 1.1.1.1 TO /etc/resolv.conf TO BYPASS LAN COUNTRY RESTRICTIONS" # Avoid provider restrictions - ######################################################################## - ACTUAL=$(cat /etc/resolv.conf | grep nameserver | head -n 1) - - sudo chattr -i /etc/resolv.conf - sudo cat > /tmp/resolv.conf < ~/.xbian-config-start - -fi - ######################################################################## # CREATE ~/astroport FILESYSTEM GATE mkdir -p ~/Astroport/film @@ -92,6 +75,29 @@ echo "# ADDING <<>> DESKTOP SHORTCUT" [[ -d ~/Bureau ]] && sed "s/_USER_/$USER/g" ~/.zen/Astroport.ONE/astroport.desktop > ~/Bureau/astroport.desktop && chmod +x ~/Bureau/astroport.desktop [[ -d ~/Desktop ]] && sed "s/_USER_/$USER/g" ~/.zen/Astroport.ONE/astroport.desktop > ~/Desktop/astroport.desktop && chmod +x ~/Desktop/astroport.desktop + + ######################################################################## + echo "ADDING nameserver 1.1.1.1 TO /etc/resolv.conf TO BYPASS LAN COUNTRY RESTRICTIONS" # Avoid provider restrictions + ######################################################################## + ACTUAL=$(cat /etc/resolv.conf | grep nameserver | head -n 1) + + sudo chattr -i /etc/resolv.conf + sudo cat > /tmp/resolv.conf <> /etc/hosts + + + mkdir -p ~/.zen/tmp diff --git a/tools/ipfs_setup.sh b/tools/ipfs_setup.sh index b8f0c4c9..b3932cb4 100755 --- a/tools/ipfs_setup.sh +++ b/tools/ipfs_setup.sh @@ -45,6 +45,23 @@ fi echo -e "Astroport activate IPFS Layer installation..." +if [[ "$USER" == "xbian" ]] +then + echo "enabling ipfs initV service autostart" + cd /etc/rc2.d && sudo ln -s ../init.d/ipfs S02ipfs + cd /etc/rc3.d && sudo ln -s ../init.d/ipfs S02ipfs + cd /etc/rc4.d && sudo ln -s ../init.d/ipfs S02ipfs + cd /etc/rc5.d && sudo ln -s ../init.d/ipfs S02ipfs + + cd /etc/rc0.d && sudo ln -s ../init.d/ipfs K01ipfs + cd /etc/rc1.d && sudo ln -s ../init.d/ipfs K01ipfs + cd /etc/rc6.d && sudo ln -s ../init.d/ipfs K01ipfs + + # Disable xbian-config auto launch + echo 0 > ~/.xbian-config-start + +fi + ## DEBIAN echo "CREATE SYSTEMD ipfs SERVICE >>>>>>>>>>>>>>>>>>" cat > /tmp/ipfs.service <