install & init script

This commit is contained in:
qo-op 2021-02-03 02:05:20 +01:00
parent f715e0e9e2
commit 0f5d64b98c
3 changed files with 6 additions and 6 deletions

View File

@ -7,9 +7,9 @@ ME="${0##*/}"
# CHECK not root user !!
if [ "$EUID" -eq 0 ]
then echo -e "${c_red}DO NOT EXECUTE AS root. Choose a user for your Astroport Station (we like pi)$c_"
then echo -e "DO NOT EXECUTE AS root. Choose a user for your Astroport Station (we like pi)"
exit 1
else echo -e "${c_yellow}OK $USER, let's go!$c_";
else echo -e "OK $USER, let's go!";
fi
# Ask user password on start
@ -17,7 +17,7 @@ sudo true
## Error funciton
err() {
echo -e "${c_red}$1$c_"
echo -e "ERREUR: $1"
exit 1
}
@ -32,7 +32,7 @@ fi
[[ -d ~/.ipfs ]] && echo "IPFS install exist! Please remove or backup before executing this script" && exit 1
echo -e "${c_yellow}Astroport IPFS Layer installation...$c_"
echo -e "Astroport IPFS Layer installation..."
# CHECK node IP isLAN?
myIP=$(hostname -I | awk '{print $1}')

View File

@ -111,7 +111,7 @@ mkdir -p ~/.zen/ipfs/.${IPFSNODEID}/G1SSB
########################################################################
XZUID=$(~/.zen/astrXbian/zen/tools/diceware.sh 1 | xargs)${RANDOM:0:2}$(~/.zen/astrXbian/zen/tools/diceware.sh 1 | xargs)
echo "SETTING GCHANGE+ PROFILE NAME = $XZUID"
mkdir -p ~/.zen/ipfs/xbian
mkdir -p ~/.zen/ipfs/xbian/${IPFSNODEID}
echo "$XZUID" > ~/.zen/ipfs/.${IPFSNODEID}/_xbian.zuid
########################################################################

View File

@ -5,13 +5,13 @@
########################################################################
{
[ $(id -u) -eq 0 ] && echo "LANCEMENT root INTERDIT. Utilisez un simple utilisateur du groupe \"sudo\" SVP" && exit 1
[[ ! $(which kodi) ]] && echo "Installez KODI svp (https://kodi.tv/) puis relancez l'installation" && exit 1
# Check requirements
echo "AstrXbian installateur pour https://xbian.org et autres ditributions basées sur DEBIAN"
sudo apt-get update
sudo apt-get install git fail2ban inotify-tools curl net-tools libsodium* python3-dev python3-pip python3-setuptools python3-wheel mpack libssl-dev libffi-dev -y
sudo apt-get install build-essential qrencode jq bc gawk ffmpeg sqlite dnsutils -y
[[ ! $(which kodi) ]] && sudo apt-get install kodi -y
[[ ! $(which apache2)]] && sudo apt-get install mariadb-server nginx ssl-cert php-imap php-cli php-curl php-sqlite3 php-gd php-json php-xml php-mbstring php-gettext php-mysql php-fpm -y
pip3 install cryptography Ed25519 base58 google protobuf duniterpy