forked from STI/Astroport.ONE
fx
This commit is contained in:
parent
288c909a43
commit
8dc4956ab1
@ -55,8 +55,8 @@ if [[ -d ~/.zen/tmp/${IPFSNODEID} ]]; then
|
|||||||
## INFORM GPS LOCATION
|
## INFORM GPS LOCATION
|
||||||
[[ -s ~/.zen/game/players/.current/GPS.json ]] \
|
[[ -s ~/.zen/game/players/.current/GPS.json ]] \
|
||||||
&& cp ~/.zen/game/players/.current/GPS.json ~/.zen/tmp/${IPFSNODEID}/ \
|
&& cp ~/.zen/game/players/.current/GPS.json ~/.zen/tmp/${IPFSNODEID}/ \
|
||||||
&& LAT=$(cat ~/.zen/tmp/${IPFSNODEID}/GPS.json | jq -r .lat) \
|
&& LAT=$(cat ~/.zen/tmp/${IPFSNODEID}/GPS.json | jq -r .[].lat) \
|
||||||
&& LON=$(cat ~/.zen/tmp/${IPFSNODEID}/GPS.json | jq -r .lon) \
|
&& LON=$(cat ~/.zen/tmp/${IPFSNODEID}/GPS.json | jq -r .[].lon) \
|
||||||
&& echo "LAT=${LAT}; LON=${LON}" > ~/.zen/GPS
|
&& echo "LAT=${LAT}; LON=${LON}" > ~/.zen/GPS
|
||||||
|
|
||||||
## REFRESH TIMESTAMPING
|
## REFRESH TIMESTAMPING
|
||||||
|
@ -102,8 +102,8 @@ for PLAYER in ${PLAYERONE[@]}; do
|
|||||||
NOWCHAIN=$(cat ~/.zen/game/players/${PLAYER}/ipfs/moa/.chain)
|
NOWCHAIN=$(cat ~/.zen/game/players/${PLAYER}/ipfs/moa/.chain)
|
||||||
LASTCHAIN=$(cat ~/.zen/game/players/${PLAYER}/ipfs/moa/.chain.* | tail -n 1)
|
LASTCHAIN=$(cat ~/.zen/game/players/${PLAYER}/ipfs/moa/.chain.* | tail -n 1)
|
||||||
try=$(cat ~/.zen/game/players/${PLAYER}/ipfs/moa/.try 2>/dev/null) || try=3
|
try=$(cat ~/.zen/game/players/${PLAYER}/ipfs/moa/.try 2>/dev/null) || try=3
|
||||||
echo "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx<br>"
|
echo "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
|
||||||
echo "<a href='$myIPFS/ipns/${ASTRONAUTENS}'>TW REFRESH FAILED</a>"
|
echo "$myIPFS/ipns/${ASTRONAUTENS}'>TW REFRESH FAILED"
|
||||||
echo ">> %%% WARNING TRY LEFT : $try %%%"
|
echo ">> %%% WARNING TRY LEFT : $try %%%"
|
||||||
echo "------------------------------------------------"
|
echo "------------------------------------------------"
|
||||||
echo " * <a href='${myIPFS}/ipfs/${LASTCHAIN}'>LAST</a>"
|
echo " * <a href='${myIPFS}/ipfs/${LASTCHAIN}'>LAST</a>"
|
||||||
@ -111,16 +111,23 @@ for PLAYER in ${PLAYERONE[@]}; do
|
|||||||
echo "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
|
echo "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
|
||||||
|
|
||||||
## SEND AN EMAIL ALERT TO PLAYER
|
## SEND AN EMAIL ALERT TO PLAYER
|
||||||
echo "<html><body><a href='$myIPFS/ipns/${ASTRONAUTENS}'>TW REFRESH FAILED</a>" > ~/.zen/tmp/result
|
echo "<html><head>
|
||||||
|
<style>
|
||||||
|
body {
|
||||||
|
font-family: 'Courier New', monospace;
|
||||||
|
}
|
||||||
|
pre {
|
||||||
|
white-space: pre-wrap;
|
||||||
|
}
|
||||||
|
</style></head><body><a href='$myIPFS/ipns/${ASTRONAUTENS}'>TW LOADING TIMEOUT</a>" > ~/.zen/tmp/result
|
||||||
echo "<br>------------------------------------------------" >> ~/.zen/tmp/result
|
echo "<br>------------------------------------------------" >> ~/.zen/tmp/result
|
||||||
echo "<br>" >> ~/.zen/tmp/result
|
echo "<br>" >> ~/.zen/tmp/result
|
||||||
echo "<br><a href='${myIPFS}/ipfs/${LASTCHAIN}'>TW[-1]</a>" >> ~/.zen/tmp/result
|
echo "<br><a href='${myIPFS}/ipfs/${LASTCHAIN}'>TW[-1]</a>: /ipfs/${LASTCHAIN}" >> ~/.zen/tmp/result
|
||||||
echo "<br><a href='${myIPFS}/ipfs/${NOWCHAIN}'>TW[0]</a>" >> ~/.zen/tmp/result
|
echo "<br><a href='${myIPFS}/ipfs/${NOWCHAIN}'>TW[0]</a>: /ipfs/${NOWCHAIN}" >> ~/.zen/tmp/result
|
||||||
echo "<br>" >> ~/.zen/tmp/result
|
echo "<br>" >> ~/.zen/tmp/result
|
||||||
echo "<br> %%% WARNING %%% $try TRY LEFT %%%" >> ~/.zen/tmp/result
|
echo "<br> %%% WARNING %%% $try TRY LEFT %%%" >> ~/.zen/tmp/result
|
||||||
echo "<br>------------------------------------------------" >> ~/.zen/tmp/result
|
echo "<br>------------------------------------------------" >> ~/.zen/tmp/result
|
||||||
echo "<br>REPAIR BY SAVING ONLINE<br>" >> ~/.zen/tmp/result
|
echo "<br>ipfs name publish --key=${PLAYER} /ipfs/${NOWCHAIN}" >> ~/.zen/tmp/result
|
||||||
echo "COMMAND :<br>ipfs name publish --key=${PLAYER} /ipfs/${NOWCHAIN}" >> ~/.zen/tmp/result
|
|
||||||
echo "</body></html>" >> ~/.zen/tmp/result
|
echo "</body></html>" >> ~/.zen/tmp/result
|
||||||
|
|
||||||
|
|
||||||
@ -132,7 +139,7 @@ for PLAYER in ${PLAYERONE[@]}; do
|
|||||||
try=$((try-1))
|
try=$((try-1))
|
||||||
echo "$try" > ~/.zen/game/players/${PLAYER}/ipfs/moa/.try
|
echo "$try" > ~/.zen/game/players/${PLAYER}/ipfs/moa/.try
|
||||||
|
|
||||||
$MY_PATH/../tools/mailjet.sh "${PLAYER}" ~/.zen/tmp/result "TW[+1] REFRESH WARNING"
|
$MY_PATH/../tools/mailjet.sh "${PLAYER}" ~/.zen/tmp/result "TW LOADING TIMEOUT"
|
||||||
|
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
@ -358,7 +358,7 @@ for SECTOR in ${SECTORS[@]}; do
|
|||||||
###############################
|
###############################
|
||||||
echo "% PUBLISHING ${SECTOR} ${myIPFS}/ipns/${TODATENS}"
|
echo "% PUBLISHING ${SECTOR} ${myIPFS}/ipns/${TODATENS}"
|
||||||
start=`date +%s`
|
start=`date +%s`
|
||||||
ipfs --timeout 180s name publish -k ${TODATE}${G1PUB} /ipfs/${IPFSPOP}
|
ipfs --timeout 240s name publish -k ${TODATE}${G1PUB} /ipfs/${IPFSPOP}
|
||||||
ipfs key rm ${YESTERDATE}${G1PUB} ${G1PUB} > /dev/null 2>&1
|
ipfs key rm ${YESTERDATE}${G1PUB} ${G1PUB} > /dev/null 2>&1
|
||||||
|
|
||||||
######################################################
|
######################################################
|
||||||
|
Loading…
Reference in New Issue
Block a user