Change cesium pods and duniter node ofr good one; Fix MY_PATH for symlink; Add jaklis to env in setup.sh
This commit is contained in:
parent
efed7354df
commit
9117def4b9
|
@ -2,9 +2,11 @@
|
||||||
DUNIKEY=
|
DUNIKEY=
|
||||||
|
|
||||||
# Noeud Duniter
|
# Noeud Duniter
|
||||||
NODE=https://g1.librelois.fr/gva
|
NODE=https://duniter-g1.p2p.legal/gva
|
||||||
|
|
||||||
# Adresse du pod Cesium ou Gchange à utiliser
|
# Adresse du pod Cesium ou Gchange à utiliser
|
||||||
POD=https://g1.data.le-sou.org
|
POD="https://g1.data.e-is.pro"
|
||||||
|
#POD="https://g1.data.adn.life"
|
||||||
|
#POD=https://g1.data.le-sou.org
|
||||||
#POD=https://g1.data.duniter.fr
|
#POD=https://g1.data.duniter.fr
|
||||||
#POD=https://data.gchange.fr
|
#POD=https://data.gchange.fr
|
||||||
|
|
|
@ -3,3 +3,4 @@ __pycache__
|
||||||
|
|
||||||
*.dunikey
|
*.dunikey
|
||||||
not4U
|
not4U
|
||||||
|
.vscode/settings.json
|
||||||
|
|
|
@ -6,9 +6,9 @@ from shutil import copyfile
|
||||||
from dotenv import load_dotenv
|
from dotenv import load_dotenv
|
||||||
from duniterpy.key import SigningKey
|
from duniterpy.key import SigningKey
|
||||||
|
|
||||||
__version__ = "0.0.4"
|
__version__ = "0.0.5"
|
||||||
|
|
||||||
MY_PATH = os.path.realpath(os.path.dirname(sys.argv[0])) + '/'
|
MY_PATH = os.path.realpath(sys.argv[0]).replace('jaklis.py','')
|
||||||
|
|
||||||
# Get variables environment
|
# Get variables environment
|
||||||
if not os.path.isfile(MY_PATH + '.env'):
|
if not os.path.isfile(MY_PATH + '.env'):
|
||||||
|
@ -19,11 +19,11 @@ load_dotenv(dotenv_path)
|
||||||
# Set global values (default parameters) , regarding variables environments
|
# Set global values (default parameters) , regarding variables environments
|
||||||
node = os.getenv('NODE')
|
node = os.getenv('NODE')
|
||||||
if not node:
|
if not node:
|
||||||
node="https://g1.librelois.fr/gva"
|
node="https://duniter-g1.p2p.legal/gva"
|
||||||
|
|
||||||
pod = os.getenv('POD')
|
pod = os.getenv('POD')
|
||||||
if not pod:
|
if not pod:
|
||||||
pod="https://g1.data.le-sou.org"
|
pod="https://g1.data.e-is.pro"
|
||||||
|
|
||||||
destPubkey = False
|
destPubkey = False
|
||||||
|
|
||||||
|
|
11
setup.sh
11
setup.sh
|
@ -1,5 +1,7 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
hasError=0
|
||||||
|
|
||||||
for i in gcc python3-pip python3-setuptools libpq-dev python3-dev python3-wheel; do
|
for i in gcc python3-pip python3-setuptools libpq-dev python3-dev python3-wheel; do
|
||||||
if [ $(dpkg-query -W -f='${Status}' $i 2>/dev/null | grep -c "ok installed") -eq 0 ]; then
|
if [ $(dpkg-query -W -f='${Status}' $i 2>/dev/null | grep -c "ok installed") -eq 0 ]; then
|
||||||
[[ ! $j ]] && sudo apt update
|
[[ ! $j ]] && sudo apt update
|
||||||
|
@ -8,5 +10,12 @@ for i in gcc python3-pip python3-setuptools libpq-dev python3-dev python3-wheel;
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
pip3 install -r requirements.txt
|
pip3 install -r requirements.txt || hasError=1
|
||||||
chmod u+x jaklis.py
|
chmod u+x jaklis.py
|
||||||
|
ln -sf $(realpath jaklis.py) /usr/local/bin/jaklis || hasError=1
|
||||||
|
|
||||||
|
if [[ hasError -eq 0 ]]; then
|
||||||
|
echo "Setup done. You can use 'jaklis' command, try it."
|
||||||
|
else
|
||||||
|
echo "An error has occurred"
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in New Issue