Map is the Territory
This commit is contained in:
parent
c2cd235e25
commit
e6879b7fbb
|
@ -1,63 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
copylaradio() {
|
|
||||||
###########################################
|
|
||||||
echo "NO READY TO USE. REWRITING..." && exit 1
|
|
||||||
###########################################
|
|
||||||
|
|
||||||
MY_PATH="`dirname \"$0\"`" # relative
|
|
||||||
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
|
||||||
|
|
||||||
isARM=$(cat $MY_PATH/.OS | grep YES)
|
|
||||||
|
|
||||||
##################################
|
|
||||||
## INSTALL TOOLS
|
|
||||||
######## YOUTUBE-DL ##########
|
|
||||||
if [[ ! $(which youtube-dl) ]]; then
|
|
||||||
sudo wget https://yt-dl.org/downloads/latest/youtube-dl -O /usr/local/bin/youtube-dl || exit 1
|
|
||||||
sudo chmod a+rx /usr/local/bin/youtube-dl
|
|
||||||
sudo chown $USER /usr/local/bin/youtube-dl
|
|
||||||
fi
|
|
||||||
sudo apt install libid3-tools mpd mpc lame omxplayer -y || err=1
|
|
||||||
sudo apt-get install lame sox libsox-fmt-mp3 eyed3 python-chardet imagemagick curl -y #libav-tools || err=1
|
|
||||||
sudo apt-get install ca-certificates git-core binutils rsync alsa-utils bc libid3-tools espeak mpg321 fuse atomicparsley -y || err=1
|
|
||||||
|
|
||||||
## CONFIG MPD
|
|
||||||
sudo cp -f $MY_PATH/templates/copylaradio/mpd.conf /etc/mpd.conf
|
|
||||||
sudo sed -i "s/_USER/$USER/g" /etc/mpd.conf || err=1
|
|
||||||
|
|
||||||
sudo chown -R $USER /var/lib/mpd/ /var/run/mpd /run/mpd /var/log/mpd
|
|
||||||
sudo service mpd restart || err=1
|
|
||||||
|
|
||||||
|
|
||||||
sudo apt-get install fail2ban nginx ssl-cert openssl-blacklist php-curl php-sqlite3 php-gd php-json php-xml php-mbstring php-fpm sqlite -y || err=1
|
|
||||||
|
|
||||||
|
|
||||||
# CONFIG NGINX TODO: NEED FIXING !!!
|
|
||||||
sudo cp -f $MY_PATH/../www/rompr.conf /etc/nginx/sites-available/
|
|
||||||
sudo sed -i "s/_USER/$USER/g" /etc/nginx/sites-available/default
|
|
||||||
|
|
||||||
sudo systemctl restart nginx || err=1
|
|
||||||
|
|
||||||
#################################
|
|
||||||
## Get _CopyLaRadio distrib
|
|
||||||
# ipfs get Qm.... > /tmp/copylaradio.zip
|
|
||||||
|
|
||||||
# Add CopyLaRadio to system PATH
|
|
||||||
#export PATH=$PATH:/home/$USER/_CopyLaRadio
|
|
||||||
# etc....
|
|
||||||
|
|
||||||
# INSTALL ROMPR WebSite LINKs
|
|
||||||
sudo ln -s $MY_PATH/../www/rompr /var/www/rompr
|
|
||||||
sudo chmod 777 $MY_PATH/../www/rompr/albumart
|
|
||||||
sudo chmod 777 $MY_PATH/../www/rompr/prefs
|
|
||||||
|
|
||||||
if [[ $err ]]; then
|
|
||||||
echo -e "${c_red}Installation de copylaradio incomplète$c_"
|
|
||||||
exit 1
|
|
||||||
else
|
|
||||||
echo -e "${c_green}CopyLaRadio a été installé avec succès$c_"
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
$@
|
|
|
@ -1,5 +1,5 @@
|
||||||
music_directory "/home/_USER/music"
|
music_directory "/home/_USER/.zen/music"
|
||||||
playlist_directory "/home/_USER/playlists"
|
playlist_directory "/home/_USER/.zen/playlists"
|
||||||
user "$USER"
|
user "$USER"
|
||||||
bind_to_address "any"
|
bind_to_address "any"
|
||||||
auto_update "yes"
|
auto_update "yes"
|
||||||
|
|
|
@ -19,8 +19,8 @@
|
||||||
MY_PATH="`dirname \"$0\"`" # relative
|
MY_PATH="`dirname \"$0\"`" # relative
|
||||||
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
||||||
|
|
||||||
[[ -f /tmp/sms.commands ]] && echo "" > /tmp/sms.commands
|
# tail -fn 1 /tmp/sms.commands | while read -r line
|
||||||
tail -fn 1 /tmp/sms.commands | while read -r line
|
for line in $(cat /tmp/sms.commands)
|
||||||
do
|
do
|
||||||
if [[ $line != "" ]]; then
|
if [[ $line != "" ]]; then
|
||||||
mycmd="$MY_PATH/g1sms/sms_AUTH.sh $line"
|
mycmd="$MY_PATH/g1sms/sms_AUTH.sh $line"
|
||||||
|
@ -28,3 +28,4 @@ do
|
||||||
eval "$mycmd" >> /tmp/sms.commmand.result
|
eval "$mycmd" >> /tmp/sms.commmand.result
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
[[ -f /tmp/sms.commands ]] && echo "" > /tmp/sms.commands
|
||||||
|
|
|
@ -77,3 +77,24 @@ Let's join our efforts and invent protocols to make our systems able to communic
|
||||||
|
|
||||||
## [The Map is the Territory](https://solarpunk.cool/zines/map-is-the-territory/)
|
## [The Map is the Territory](https://solarpunk.cool/zines/map-is-the-territory/)
|
||||||
|
|
||||||
|
![https://solarpunk.cool/zines/map-is-the-territory/aesthetic/tmitt_dither.png]
|
||||||
|
|
||||||
|
```
|
||||||
|
cd ~/.zen/
|
||||||
|
|
||||||
|
curl -L coolguy.website/earth | grep "~~*" -A2 | tail -2 >> earth
|
||||||
|
curl -L angblev.com/water | grep "~~*" -A2 | tail -2 >> water
|
||||||
|
curl -L solarpunk.cool/magic/fire | grep "~~*" -A2 | tail -2 >> fire
|
||||||
|
curl -L apileof.rocks | grep "~~*" -A2 | tail -2 >> air
|
||||||
|
curl -L solarpunk.cool/magic/end | grep "~~*" -A2 | tail -2 >> end
|
||||||
|
|
||||||
|
cat begin earth water fire air end
|
||||||
|
|
||||||
|
### YOUR KEY IS IMPORTANT
|
||||||
|
cat ~/.zen/secret.astroport.key
|
||||||
|
|
||||||
|
# SECURITY AND FREEDOM IS IMPORTANT TO YOU ?
|
||||||
|
############################################# USE LINUX !! ####
|
||||||
|
### My favorite distribution is Linux Mint
|
||||||
|
|
||||||
|
```
|
||||||
|
|
|
@ -12,7 +12,10 @@
|
||||||
########################################################################
|
########################################################################
|
||||||
MY_PATH="`dirname \"$0\"`" # relative
|
MY_PATH="`dirname \"$0\"`" # relative
|
||||||
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
||||||
source ./zen/functions.sh
|
source ./g1sms/functions.sh
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# REWRITING .... NEEDED
|
||||||
|
|
||||||
SOURCE="$1" # id@channel
|
SOURCE="$1" # id@channel
|
||||||
COMMAND="$2" # command received (message, comment, ...)
|
COMMAND="$2" # command received (message, comment, ...)
|
||||||
|
|
|
@ -8,9 +8,25 @@ MY_PATH="`dirname \"$0\"`" # relative
|
||||||
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
||||||
ME="${0##*/}"
|
ME="${0##*/}"
|
||||||
|
|
||||||
[[ ! $(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1) ]] && echo "ipfs daemon not running. EXIT" && exit 1
|
########################################################################
|
||||||
|
### MODIFY WITH GREAT CARE!!! MUST BE BUG FREE !!!!!
|
||||||
|
### EVERY STATION RUN THIS SCRIPT EVERY MINUTE
|
||||||
|
### DEPENDING ON EXE AND PS
|
||||||
|
isMinetestRunning=$(ps auxf --sort=+utime | grep -w minetest | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
|
||||||
|
isG1smsRunning=$(ps auxf --sort=+utime | grep -w gammu | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
|
||||||
|
#isNextcloudRunning=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1)
|
||||||
|
### ACTIVATE DIFFERENT FLAVOUR
|
||||||
|
########################################################################
|
||||||
|
|
||||||
ipfsnodeid=$(/usr/local/bin/ipfs id -f='<id>\n')
|
[[ ! $(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d ' ' -f 1) ]] \
|
||||||
|
&& echo "ipfs daemon not running. EXIT" \
|
||||||
|
&& exit 1
|
||||||
|
|
||||||
|
# CORRECT PATH
|
||||||
|
[[ ! $(echo $PATH | grep "/usr/local/bin") ]] && export PATH="$PATH:/usr/local/bin"
|
||||||
|
[[ ! $(echo $PATH | grep "~/.local/bin") ]] && export PATH="$PATH:~/.local/bin"
|
||||||
|
|
||||||
|
ipfsnodeid=$(ipfs id -f='<id>\n')
|
||||||
g1pub=$(cat ~/.ssb/secret.dunikey | grep 'pub:' | cut -d ' ' -f 2)
|
g1pub=$(cat ~/.ssb/secret.dunikey | grep 'pub:' | cut -d ' ' -f 2)
|
||||||
|
|
||||||
# UNIVERSAL TIME (TODO ntpdate, but sudo problem)
|
# UNIVERSAL TIME (TODO ntpdate, but sudo problem)
|
||||||
|
@ -29,9 +45,6 @@ echo $timebar
|
||||||
[[ $(($minute % 5)) == 0 ]] && sleep $((1 + RANDOM % 12)) && cd $MY_PATH && git pull
|
[[ $(($minute % 5)) == 0 ]] && sleep $((1 + RANDOM % 12)) && cd $MY_PATH && git pull
|
||||||
|
|
||||||
|
|
||||||
# CORRECT PATH
|
|
||||||
[[ ! $(echo $PATH | grep "/usr/local/bin") ]] && export PATH="$PATH:/usr/local/bin"
|
|
||||||
[[ ! $(echo $PATH | grep "~/.local/bin") ]] && export PATH="$PATH:~/.local/bin"
|
|
||||||
|
|
||||||
##################################################################
|
##################################################################
|
||||||
# REFRESH IPFS SWARM DATA EVERY 12 minutes
|
# REFRESH IPFS SWARM DATA EVERY 12 minutes
|
||||||
|
|
|
@ -1,25 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
################################################################################
|
|
||||||
# Author: Fred (support@qo-op.com)
|
|
||||||
# Version: 0.1
|
|
||||||
# License: AGPL-3.0 (https://choosealicense.com/licenses/agpl-3.0/)
|
|
||||||
################################################################################
|
|
||||||
# Activate SUPPORT MODE: open ssh over IPFS
|
|
||||||
MY_PATH="`dirname \"$0\"`" # relative
|
|
||||||
MY_PATH="`( cd \"$MY_PATH\" && pwd )`" # absolutized and normalized
|
|
||||||
|
|
||||||
exit
|
|
||||||
|
|
||||||
# Arrange local port forwarded to swarm
|
|
||||||
# GET _uidna
|
|
||||||
|
|
||||||
YOU=$(ps aux --sort=+utime | grep ipfs | tail -n 1 | cut -d " " -f 1)
|
|
||||||
|
|
||||||
IPFSNODEID=$(ipfs id -f='<id>\n')
|
|
||||||
UIDNA=$(cat ~/.zen/ipfs/.$IPFSNODEID/G1SSB/_uidna)
|
|
||||||
|
|
||||||
p2p close --all
|
|
||||||
ipfs p2p listen /x/ssh /ip4/127.0.0.1/tcp/22
|
|
||||||
ipfs p2p listen /x/http /ip4/127.0.0.1/tcp/80
|
|
||||||
ipfs p2p listen /x/https /ip4/127.0.0.1/tcp/443
|
|
||||||
ipfs p2p ls
|
|
|
@ -59,7 +59,7 @@
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<a class="btn btn-primary" href="./cesium/index.html" target="cesium">Cesium</a>
|
<a class="btn btn-primary" href="./cesium/index.html" target="cesium">Cesium</a>
|
||||||
<a class="btn btn-primary" href="./gchange/index.html" target="gchange">Gchange</a>
|
<a class="btn btn-primary" href="./gchange/index.html" target="gchange">Gchange</a>
|
||||||
<a class="btn btn-primary" href="./DUQR/index.html" target="g1billets">G1Billets</a>
|
<a class="btn btn-primary" href="./g1billet/test.php" target="g1billets">G1Billets</a>
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue