From c402e39df6c2c5bbc39f7e26ca4369b341264a7b Mon Sep 17 00:00:00 2001 From: qo-op Date: Wed, 2 Jun 2021 00:37:17 +0200 Subject: [PATCH] ipfs --timeout=5s --- zen/gchange_INIT.sh | 2 +- zen/gchange_IPFS_swarm.sh | 2 +- zen/ipfs_SWARM_refresh.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/zen/gchange_INIT.sh b/zen/gchange_INIT.sh index 96290b7..ec13cf7 100755 --- a/zen/gchange_INIT.sh +++ b/zen/gchange_INIT.sh @@ -16,7 +16,7 @@ ME="${0##*/}" # INITIALISATION & CONTROL ######################################################################## YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1); -IPFSNODEID=$(ipfs id -f='\n') +IPFSNODEID=$(ipfs --timeout=5s id -f='\n') [[ $IPFSNODEID == "" ]] && echo "ERROR missing IPFS Node id !! EXIT" && exit 1 ######################################################################## [[ ! -f ~/.zen/secret.dunikey ]] && echo "Missing ~/.zen/secret.dunikey. EXIT" && exit 1 diff --git a/zen/gchange_IPFS_swarm.sh b/zen/gchange_IPFS_swarm.sh index 2334202..ab009c3 100755 --- a/zen/gchange_IPFS_swarm.sh +++ b/zen/gchange_IPFS_swarm.sh @@ -9,7 +9,7 @@ MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized ME="${0##*/}" YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) && [[ ! $YOU ]] && echo "ipfs NOT RUNNING. EXIT" && exit 1 G1PUB=$(cat ~/.zen/secret.dunikey | grep 'pub:' | cut -d ' ' -f 2) && [[ ! $G1PUB ]] && echo "ERREUR G1PUB. EXIT" && exit 1 -IPFSNODEID=$(ipfs id -f='\n') && [[ "$IPFSNODEID" == "" ]] && echo 'ERROR missing IPFS Node id !! IPFS is not installed !?' && exit 1 +IPFSNODEID=$(ipfs --timeout=5s id -f='\n') && [[ "$IPFSNODEID" == "" ]] && echo 'ERROR missing IPFS Node id !! IPFS is not installed !?' && exit 1 # CLEAN "A_my_swarm.txt" and "A_swarm_map.txt" if [[ $(cat ~/.zen/A_swarm_map.txt | wc -l) -gt 300 ]]; then diff --git a/zen/ipfs_SWARM_refresh.sh b/zen/ipfs_SWARM_refresh.sh index fadb567..85b1bba 100755 --- a/zen/ipfs_SWARM_refresh.sh +++ b/zen/ipfs_SWARM_refresh.sh @@ -9,7 +9,7 @@ MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized ME="${0##*/}" YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) && [[ ! $YOU ]] && echo "ipfs NOT RUNNING. EXIT" && exit 1 G1PUB=$(cat ~/.zen/secret.dunikey | grep 'pub:' | cut -d ' ' -f 2) && [[ ! $G1PUB ]] && echo "ERREUR G1PUB. EXIT" && exit 1 -IPFSNODEID=$(ipfs id -f='\n') && [[ "$IPFSNODEID" == "" ]] && echo 'ERROR missing IPFS Node id !! IPFS is not installed !?' && exit 1 +IPFSNODEID=$(ipfs --timeout=5s id -f='\n') && [[ "$IPFSNODEID" == "" ]] && echo 'ERROR missing IPFS Node id !! IPFS is not installed !?' && exit 1 ######################################################################## ######################################################################## # This script is controling IPFS swarm