mirror of
https://github.com/YunoHost-Apps/duniter_ynh.git
synced 2024-09-03 18:26:35 +02:00
fix cpu and ipv4 conf, there is still an issue installing on Debian: I can't find the binary
This commit is contained in:
parent
157bc8e8ca
commit
d88b206720
5 changed files with 15 additions and 15 deletions
|
@ -2,5 +2,5 @@
|
|||
|
||||
* [uCoin project](http://ucoin.io)
|
||||
* [YunoHost project](https://yunohost.org/#/)
|
||||
* Only tested on Debian Jessie 64bits
|
||||
* There is still an issue installing on Debian Jessie 64bits
|
||||
* There is still an issue installing uCoin on ARM
|
||||
|
|
|
@ -63,13 +63,6 @@
|
|||
"en": "Password of your account",
|
||||
"fr": "Mot de passe de votre compte"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "cpu",
|
||||
"ask": {
|
||||
"en": "Which CPU load limit would you like your uCoin node don't exceed?",
|
||||
"fr": "Quel pourcentage de charge processeur ne souhaitez-vous pas que le nÅ“ud uCoin dÃpasse ?"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
7
manifest.json.future
Normal file
7
manifest.json.future
Normal file
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"name": "cpu",
|
||||
"ask": {
|
||||
"en": "Which CPU load limit would you like your uCoin node don't exceed?",
|
||||
"fr": "Quel pourcentage de charge processeur ne souhaitez-vous pas que le nÅ<93>ud uCoin dÃpasse ?"
|
||||
}
|
||||
}
|
|
@ -1,16 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Retrieve arguments
|
||||
ipv4=ifconfig | grep "inet addr:" | sed '1!d' | cut -d : -f 2 | cut -b -14
|
||||
ipv4=$(ifconfig | grep "inet addr:" | sed '1!d' | cut -d : -f 2 | cut -b -14)
|
||||
domain=$1
|
||||
port=$2
|
||||
sync_node=$3
|
||||
sync_port=$4
|
||||
salt=$5
|
||||
pwd=$6
|
||||
cpu=$(($7/100))
|
||||
#cpu=$(($7/100))
|
||||
#cpu=`expr $7 / 100`
|
||||
#cpu=calc{$7/100}
|
||||
|
||||
# Install dependencies: nodejs, npm
|
||||
sudo apt-get -y -qq install nodejs npm nodejs-legacy
|
||||
|
@ -25,12 +24,13 @@ if [[ ! $? -eq 0 ]]; then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
# Open port in firewall
|
||||
# Open port on firewall
|
||||
sudo yunohost firewall allow TCP $port > /dev/null 2>&1
|
||||
|
||||
# Configure and sync uCoin node
|
||||
ucoind config --noupnp --ipv4 $ipv4 --remote4 $ipv4 --remoteh $domain --port $port --remotep $port --salt $salt --passwd $pwd --cpu $cpu
|
||||
ucoind config --noupnp --ipv4 $ipv4 --remote4 $ipv4 --remoteh $domain --port $port --remotep $port --salt $salt --passwd $pwd
|
||||
# --cpu $cpu
|
||||
ucoind sync $sync_node $sync_port
|
||||
|
||||
# Launch uCoin node with daemon pm2
|
||||
# Launch uCoin node with pm2 daemon
|
||||
pm2 start /usr/bin/ucoind -- start
|
||||
|
|
|
@ -8,7 +8,7 @@ pm2 delete ucoind
|
|||
|
||||
# Remove uCoin node
|
||||
sudo npm remove ucoin pm2
|
||||
sudo apt-get -y remove nodejs npm
|
||||
#sudo apt-get -y remove nodejs npm
|
||||
|
||||
# Close opened port
|
||||
sudo yunohost firewall disallow TCP $port
|
||||
|
|
Loading…
Add table
Reference in a new issue