forked from axiom-team/astrXbian
xbian first
This commit is contained in:
parent
e38b4c24c1
commit
1cf80f7d52
|
@ -25,8 +25,9 @@ howmany=$(cat /tmp/ipfs.timeout)
|
||||||
if [[ ! $IPFSNODEID ]]; then
|
if [[ ! $IPFSNODEID ]]; then
|
||||||
## wait a howmany timeout before restarting ipfs
|
## wait a howmany timeout before restarting ipfs
|
||||||
howmany=$((howmany + 1)) && echo $howmany > /tmp/ipfs.timeout
|
howmany=$((howmany + 1)) && echo $howmany > /tmp/ipfs.timeout
|
||||||
[ $howmany -gt 3 ] && [[ -f /etc/sudoers.d/systemctl ]] && echo "IPFS NOT RUNNING $(date) $(ps auxf)" >> ~/.zen/restart.txt && rm /tmp/ipfs.timeout && rm /config/ipfs/repo.lock && sudo systemctl restart ipfs
|
[ $howmany -gt 3 ] && [[ "${USER}" == "xbian" ]] && echo "IPFS NOT RUNNING" && rm /tmp/ipfs.timeout && rm /config/ipfs/repo.lock && sudo service ipfs restart && exit 1
|
||||||
[ $howmany -gt 3 ] && [[ "${USER}" == "xbian" ]] && echo "IPFS NOT RUNNING" && sudo service ipfs restart && exit 1
|
[ $howmany -gt 3 ] && [[ -f /etc/sudoers.d/systemctl ]] && echo "IPFS NOT RUNNING $(date)" && rm /tmp/ipfs.timeout && rm /config/ipfs/repo.lock && sudo systemctl restart ipfs
|
||||||
|
rm ~/.zen/restart.txt
|
||||||
exit 1
|
exit 1
|
||||||
else
|
else
|
||||||
echo 0 > /tmp/ipfs.timeout
|
echo 0 > /tmp/ipfs.timeout
|
||||||
|
|
Loading…
Reference in New Issue