forked from STI/Astroport.ONE
EVOLVE TO P2P QOS MAP
This commit is contained in:
parent
61b8e4aa92
commit
19f2da3a53
|
@ -15,13 +15,16 @@ start=`date +%s`
|
|||
## PROCESS TW BACKOFFICE TREATMENT
|
||||
cd ~/.zen/Astroport.ONE/
|
||||
git pull
|
||||
## SOON /ipns/ Address !!!
|
||||
|
||||
# Refresh ~/.zen/game/world/G1VOEU
|
||||
~/.zen/Astroport.ONE/ASTROBOT/VOEUX.refresh.sh
|
||||
|
||||
# Refresh ~/.zen/game/players/PLAYER
|
||||
~/.zen/Astroport.ONE/ASTROBOT/PLAYER.refresh.sh
|
||||
|
||||
|
||||
## ADD A_boostrap_nodes.txt TO BOOTSTRAP
|
||||
|
||||
## REFRESH BOOTSTRAP LIST (OFFICIAL SWARM)
|
||||
ipfs bootstrap rm --all > /dev/null 2>&1
|
||||
for bootnode in $(cat ~/.zen/Astroport.ONE/A_boostrap_nodes.txt | grep -Ev "#") # remove comments
|
||||
do
|
||||
|
|
|
@ -26,7 +26,13 @@ for PLAYER in $(ls ~/.zen/game/players/); do
|
|||
rm -Rf ~/.zen/tmp/astro
|
||||
mkdir -p ~/.zen/tmp/astro
|
||||
|
||||
ipfs --timeout 12s cat /ipns/$ASTRONAUTENS > ~/.zen/tmp/astro/index.html
|
||||
|
||||
echo "Getting latest online TW..."
|
||||
YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1);
|
||||
LIBRA=$(head -n 2 ~/.zen/Astroport.ONE/A_boostrap_nodes.txt | tail -n 1 | cut -d ' ' -f 2)
|
||||
echo "$LIBRA/ipns/$voeuns"
|
||||
[[ $YOU ]] && ipfs --timeout 12s cat /ipns/$ASTRONAUTENS > ~/.zen/tmp/astro/index.html \
|
||||
|| curl -so ~/.zen/tmp/astro/index.html "$LIBRA/ipns/$ASTRONAUTENS"
|
||||
|
||||
|
||||
if [ ! -s ~/.zen/tmp/astro/index.html ]; then
|
||||
|
@ -34,7 +40,7 @@ for PLAYER in $(ls ~/.zen/game/players/); do
|
|||
continue
|
||||
else
|
||||
## Replace tube links with downloaded video ## TODO create LOG tiddler
|
||||
$MY_PATH/../tools/TUBE.copy.sh ~/.zen/tmp/astro/index.html $PLAYER
|
||||
$MY_PATH/TUBE.copy.sh ~/.zen/tmp/astro/index.html $PLAYER
|
||||
|
||||
## LAN TO WAN MIGRATION
|
||||
myIP=$(hostname -I | awk '{print $1}' | head -n 1)
|
||||
|
@ -167,7 +173,10 @@ done
|
|||
|
||||
done
|
||||
|
||||
#################################################################
|
||||
## IPFSNODEID ROUTING
|
||||
## PUBLISHING ASTRONAUTS LIST
|
||||
## EVOLVE TO P2P QOS MAP
|
||||
ROUTING=$(ipfs add -q ~/.zen/game/astronautes.txt)
|
||||
echo "PUBLISHING IPFSNODEID / Astronaute List"
|
||||
ipfs name publish /ipfs/$ROUTING
|
||||
|
|
|
@ -12,7 +12,6 @@ ME="${0##*/}"
|
|||
# Backup and chain
|
||||
|
||||
[[ $PLAYER == "" ]] && PLAYER=$(cat ~/.zen/game/players/.current/.player 2>/dev/null)
|
||||
|
||||
############################################
|
||||
echo "## WORLD VOEUX"
|
||||
|
||||
|
@ -31,7 +30,11 @@ do
|
|||
mkdir -p ~/.zen/tmp/work
|
||||
|
||||
echo "Getting latest online TW..."
|
||||
ipfs --timeout 12s cat /ipns/$voeuns > ~/.zen/tmp/work/index.html
|
||||
YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1);
|
||||
LIBRA=$(head -n 2 ~/.zen/Astroport.ONE/A_boostrap_nodes.txt | tail -n 1 | cut -d ' ' -f 2)
|
||||
echo "$LIBRA/ipns/$voeuns"
|
||||
[[ $YOU ]] && ipfs --timeout 12s cat /ipns/$voeuns > ~/.zen/tmp/work/index.html \
|
||||
|| curl -so ~/.zen/tmp/work/index.html "$LIBRA/ipns/$voeuns"
|
||||
|
||||
if [[ ! -s ~/.zen/tmp/work/index.html ]]; then
|
||||
echo "UNAVAILABLE WISH! If you want to remove $W $voeu"
|
||||
|
@ -42,7 +45,7 @@ do
|
|||
continue
|
||||
else
|
||||
## Replace tube links with downloaded video
|
||||
$MY_PATH/../tools/TUBE.copy.sh ~/.zen/tmp/work/index.html $voeu
|
||||
$MY_PATH/TUBE.copy.sh ~/.zen/tmp/work/index.html $voeu
|
||||
|
||||
## LAN TO WAN MIGRATION
|
||||
myIP=$(hostname -I | awk '{print $1}' | head -n 1)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# CONTAINS Address of 1st Bootstrap Stations (24/24 Public IP)
|
||||
# CONTAINS Address of 1st Bootstrap Stations (24/24 Public IP) - DO NOT EDIT MANUALY -
|
||||
# http://libra.copylaradio.com:8080
|
||||
/ip4/149.102.158.67/udp/4001/quic/p2p/12D3KooWL2FcDJ41U9SyLuvDmA5qGzyoaj2RoEHiJPpCvY8jvx9u
|
||||
# cancer.astroport.com
|
||||
/ip4/185.202.238.69/tcp/4001/p2p/12D3KooWSnxRBuoeCZGdXBbSKiW8qM4HxLp3RLypW9dg82o41ZqM
|
||||
# libra.copylaradio.com
|
||||
/ip4/149.102.158.67/udp/4001/quic/p2p/12D3KooWL2FcDJ41U9SyLuvDmA5qGzyoaj2RoEHiJPpCvY8jvx9u
|
||||
# aries.copylaradio.com
|
||||
/ip4/37.187.127.175/tcp/4001/p2p/12D3KooWSQYTxeoZZ39SNosEKxi7RUdGTtAQAqpKeZJxjzqqrZTx
|
||||
|
|
|
@ -203,7 +203,7 @@ ipfs config --json Experimental.P2pHttpProxy true
|
|||
ipfs config --json Swarm.ConnMgr.LowWater 0
|
||||
ipfs config --json Swarm.ConnMgr.HighWater 0
|
||||
myIP=$(hostname -I | awk '{print $1}' | head -n 1)
|
||||
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Origin '["http://'$myIP':8080", "http://127.0.0.1:8080", "http://astroport", "https://astroport.com", "https://qo-op.com", "https://tube.copylaradio.com" ]'
|
||||
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Origin '["http://'$myIP':8080", "http://127.0.0.1:8080", "http://astroport", "https://astroport.com", "https://qo-op.com", "https://tube.copylaradio.com", "http://libra.copylaradio.com:8080" ]'
|
||||
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Methods '["PUT", "GET", "POST"]'
|
||||
ipfs config --json API.HTTPHeaders.Access-Control-Allow-Credentials '["true"]'
|
||||
|
||||
|
|
Loading…
Reference in New Issue