diff --git a/.install/kodi/plugin.video.invidious-0.2.5.zip b/.install/kodi/plugin.video.invidious-0.2.5.zip deleted file mode 100644 index f1a2878..0000000 Binary files a/.install/kodi/plugin.video.invidious-0.2.5.zip and /dev/null differ diff --git a/.install/kodi/repository.vstream-0.0.3.zip b/.install/kodi/repository.vstream-0.0.3.zip deleted file mode 100644 index f1c12a1..0000000 Binary files a/.install/kodi/repository.vstream-0.0.3.zip and /dev/null differ diff --git a/install_jukebox.sh b/install_www.sh similarity index 100% rename from install_jukebox.sh rename to install_www.sh diff --git a/www/boris/astrocrowdbunker.png b/www/boris/astrocrowdbunker.png new file mode 100644 index 0000000..21e530d Binary files /dev/null and b/www/boris/astrocrowdbunker.png differ diff --git a/www/boris/cat.php b/www/boris/cat.php new file mode 100644 index 0000000..b770b89 --- /dev/null +++ b/www/boris/cat.php @@ -0,0 +1,5 @@ +'; print_r($files); echo ''; diff --git a/www/boris/conf.php b/www/boris/conf.php new file mode 100644 index 0000000..bf77504 --- /dev/null +++ b/www/boris/conf.php @@ -0,0 +1,20 @@ +=200 && $httpcode<300); +} + +function guessTypeFromFilename ($filename) { + + $ext = substr($filename, (strrpos($filename, '.') + 1)); + + switch ($ext) { + + case 'mkv': + $type = 'video/mkv'; + break; + + case 'flv': + $type = 'video/flv'; + break; + + case 'avi': + $type = 'video/x-msvideo'; + break; + + case 'webm': + $type = 'video/webm'; + break; + + case 'mkv': + $type = 'video/x-matroska'; + break; + + case '3gp': + $type = 'video/3gp'; + break; + + case 'ogv': + $type = 'video/ogv'; + break; + + default: + $type = 'video/mp4'; + break; + } + + return $type; +} diff --git a/www/boris/get_youtube_videos.sh b/www/boris/get_youtube_videos.sh new file mode 100755 index 0000000..f0ac6b4 --- /dev/null +++ b/www/boris/get_youtube_videos.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +cat ./{me,swarm}/.*/astroport/kodi/vstream/YASTRXBIAN | sort | uniq | tail -n +2 diff --git a/www/boris/index.php b/www/boris/index.php new file mode 100644 index 0000000..cba55aa --- /dev/null +++ b/www/boris/index.php @@ -0,0 +1,2 @@ +\n') + +[[ $(which apache2) ]] && echo "Apache est installé. Le plugin nécessite nginx. EXIT" && exit 1 +[[ $(netstat -tan | grep ':10111 ') ]] && echo "Serveur web existant sur port 10111. Installation manuelle recommandée... EXIT" && exit 1 + +######################################################################## +## INSTALL nginx + php + mariadb + ... +sudo apt-get update -y +sudo apt-get install mariadb-server nginx python3-certbot-nginx certbot ssl-cert php-imap php-cli php-curl php-sqlite3 php-gd php-json php-xml php-mbstring php-gettext php-mysql php-fpm -y + +####################################################################### +## CREATE symlinks for ~/.zen/www/swarm & me +mkdir -p ~/.zen/www/boris && cd ~/.zen/www/boris +ln -s ../ipfs_swarm swarm +ln -s ../ipfs me + +######################################################################## +## ACTIVATE sites-available/astroport +cd /etc/nginx/sites-enabled +sudo ln -s ../sites-available/astroport astroport + +######################################################################## +## CREATE site config file +printf " +server { + listen 10111 default_server; + listen [::]:10111 default_server; + + root " | sudo tee /etc/nginx/sites-available/astroport + +printf ~/.zen/www/boris | sudo tee -a /etc/nginx/sites-available/astroport + +printf "; + + # Add index.php to the list if you are using PHP + index index.html index.htm index.nginx-debian.html; + + server_name _; + + location / { + # First attempt to serve request as file, then + # as directory, then fall back to displaying a 404. + try_files \$uri \$uri/ =404; + } + + + index index.php; + + # pass PHP scripts to FastCGI server + + location ~ \.php$ { + include snippets/fastcgi-php.conf; + + # With php-fpm (or other unix sockets): + fastcgi_pass unix:/var/run/php/php-fpm.sock; + # With php-cgi (or other tcp sockets): + #fastcgi_pass 127.0.0.1:9000; + } +} +" | sudo tee -a /etc/nginx/sites-available/astroport diff --git a/www/boris/swarm_files.php b/www/boris/swarm_files.php new file mode 100644 index 0000000..410c265 --- /dev/null +++ b/www/boris/swarm_files.php @@ -0,0 +1,70 @@ +'. $peerName . ' ['. substr($peer, 0, 5) . '…' . substr($peer, -4) . ']'; + + $files = scandir('swarm/' . $peer . '/astroport/kodi/vstream'); + + foreach ($files as $f) { + + echo '

' . getCollectionType($f) . '

'; + + $collection = file_get_contents('swarm/' . $peer . '/astroport/kodi/vstream/' . $f); + $collection = trim($collection); + + $videos = explode("\n", $collection); + $videos = array_reverse($videos); + array_pop($videos); + + echo ''; +?> + + + + + diff --git a/www/boris/youtube_watch.php b/www/boris/youtube_watch.php new file mode 100644 index 0000000..6a87596 --- /dev/null +++ b/www/boris/youtube_watch.php @@ -0,0 +1,43 @@ + + + + AstroCrowdBuster + + + + + +
+
+ Astroport × Crowdbunker +
+
+ +
+ + + +

+ ' . $videoName . ' +

+ '; +?> +
+ + + + + diff --git a/www/multitube/index.php b/www/multitube/index.php new file mode 100644 index 0000000..e69de29 diff --git a/www/xbian/Readme.md b/www/xbian/Readme.md index 2929b3f..ed49c30 100644 --- a/www/xbian/Readme.md +++ b/www/xbian/Readme.md @@ -1,3 +1,9 @@ +DEPRECATED - TO REMOVE + +Maintenant les fichiers index sont accessibles par la passerelle IPFS + +--- + Ce répertoire contient les INDEX des liens de streaming utilisés par le plugin Vstream, site "ASTROPORT" Il est rendu accessible au travers de nginx http://localhost:10021/ tel que configuré dans ~/.kodi/addons/plugin.video.vstream/resources/sites/astroport.py