NO IP GATEWAY : EXIT
This commit is contained in:
parent
918e55396a
commit
4f604593a3
|
@ -19,6 +19,9 @@ source $HOME/.profile
|
||||||
export YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1)
|
export YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1)
|
||||||
[[ $IPFSNODEID ]] && export IPFSNODEID=$IPFSNODEID || export IPFSNODEID=$(ipfs id -f='<id>\n')
|
[[ $IPFSNODEID ]] && export IPFSNODEID=$IPFSNODEID || export IPFSNODEID=$(ipfs id -f='<id>\n')
|
||||||
|
|
||||||
|
### NO IP GATEWAY : EXIT
|
||||||
|
ping -q -w 1 -c 1 `ip r | grep default | cut -d ' ' -f 3` > /dev/null && echo ok || (echo "NO GATEWAY CONNEXION" && exit 1)
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
# HELP DEVLT: Search "TODO" in code
|
# HELP DEVLT: Search "TODO" in code
|
||||||
# Write what you thing about the situation
|
# Write what you thing about the situation
|
||||||
|
|
|
@ -17,4 +17,4 @@ WHOAMI=$(sbotc whoami | jq -r .id) || er+=" sbotc whoami problem"
|
||||||
|
|
||||||
[[ -f ~/.zen/ipfs/.$IPFSNODEID/G1SSB/_g1.gchange_title ]] && XZUID=$(cat ~/.zen/ipfs/.$IPFSNODEID/G1SSB/_g1.gchange_title)
|
[[ -f ~/.zen/ipfs/.$IPFSNODEID/G1SSB/_g1.gchange_title ]] && XZUID=$(cat ~/.zen/ipfs/.$IPFSNODEID/G1SSB/_g1.gchange_title)
|
||||||
|
|
||||||
ipfs p2p listen /x/$XZUID-ssh /ip4/127.0.0.1/tcp/22 # or CLOSE ipfs p2p close /x/$UIDNA-ssh
|
[[ $XZUID ]] && ipfs p2p listen /x/$XZUID-ssh /ip4/127.0.0.1/tcp/22 # or CLOSE ipfs p2p close /x/$UIDNA-ssh
|
||||||
|
|
Loading…
Reference in New Issue