forked from axiom-team/astrXbian
Compare commits
3 Commits
840bdedc2d
...
e9bda280dd
Author | SHA1 | Date |
---|---|---|
Boris | e9bda280dd | |
Boris | 062ae4dbb2 | |
Boris | 892641bfac |
|
@ -0,0 +1 @@
|
|||
minetest.conf
|
|
@ -0,0 +1,102 @@
|
|||
|
||||
|
||||
enable_damage = false
|
||||
enable_pvp = false
|
||||
creative_mode = true
|
||||
enable_build_where_you_stand = true
|
||||
|
||||
# Controls length of day/night cycle.
|
||||
# Examples:
|
||||
# 72 = 20min, 360 = 4min, 1 = 24hour, 0 = day/night/whatever stays unchanged.
|
||||
# type: int
|
||||
time_speed = 1
|
||||
|
||||
# Name of map generator to be used when creating a new world.
|
||||
# Creating a world in the main menu will override this.
|
||||
# Current mapgens in a highly unstable state:
|
||||
# - The optional floatlands of v7 (disabled by default).
|
||||
# type: enum values: v7, valleys, carpathian, v5, flat, fractal, singlenode, v6
|
||||
# mg_name = v7
|
||||
mg_name = singlenode
|
||||
# singlenode = que de l'air ; le mod "startanode" permet d'ajouter un cube au spawn
|
||||
|
||||
# Player is able to fly without being affected by gravity.
|
||||
# This requires the "fly" privilege on the server.
|
||||
# type: bool
|
||||
free_move = true
|
||||
|
||||
# Fast movement (via the "special" key).
|
||||
# This requires the "fast" privilege on the server.
|
||||
# type: bool
|
||||
fast_move = false
|
||||
|
||||
|
||||
# The privileges that new users automatically get.
|
||||
# See /privs in game for a full list on your server and mod configuration.
|
||||
# type: string
|
||||
default_privs = interact, shout, fly, fast
|
||||
|
||||
# Privileges that players with basic_privs can grant
|
||||
# type: string
|
||||
basic_privs = interact, shout, fly, fast
|
||||
|
||||
# If this is set, players will always (re)spawn at the given position.
|
||||
# type: string
|
||||
static_spawnpoint = (0, 24, 0)
|
||||
|
||||
# Where the map generator stops.
|
||||
# Please note:
|
||||
# - Limited to 31000 (setting above has no effect)
|
||||
# - The map generator works in groups of 80x80x80 nodes (5x5x5 MapBlocks).
|
||||
# - Those groups have an offset of -32, -32 nodes from the origin.
|
||||
# - Only groups which are within the map_generation_limit are generated
|
||||
# type: int min: 0 max: 31000
|
||||
mapgen_limit = 216
|
||||
mg_flags = trees,decorations
|
||||
mgv6_spflags = jungles,biomeblend,mudflow,snowbiomes,noflat,trees
|
||||
mgv6_freq_desert = 0.05
|
||||
mgv6_freq_beach = 0.95
|
||||
|
||||
# Humidity variation for biomes.
|
||||
# type: noise_params_2d
|
||||
mgv6_np_humidity = {
|
||||
offset = 0.5,
|
||||
scale = 0.5,
|
||||
spread = (2, 3, 2),
|
||||
seed = 72384,
|
||||
octaves = 3,
|
||||
persistence = 0.50,
|
||||
lacunarity = 2.0,
|
||||
flags = eased
|
||||
}
|
||||
|
||||
# Defines tree areas and tree density.
|
||||
# type: noise_params_2d
|
||||
mgv6_np_trees = {
|
||||
offset = 0,
|
||||
scale = 1,
|
||||
spread = (2, 3, 2),
|
||||
seed = 2,
|
||||
octaves = 4,
|
||||
persistence = 0.66,
|
||||
lacunarity = 2.0,
|
||||
flags = eased
|
||||
}
|
||||
|
||||
# Defines areas with sandy beaches.
|
||||
# type: noise_params_2d
|
||||
mgv6_np_beach = {
|
||||
offset = 0,
|
||||
scale = 1,
|
||||
spread = (50, 50, 50),
|
||||
seed = 59420,
|
||||
octaves = 3,
|
||||
persistence = 0.50,
|
||||
lacunarity = 2.0,
|
||||
flags = eased
|
||||
}
|
||||
|
||||
secure.trusted_mods = wiki
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,209 @@
|
|||
#!/bin/sh
|
||||
|
||||
MINETEST_PATH=/home/pi/.minetest
|
||||
WORLD_NAME=astroport
|
||||
WORLD_PATH=$MINETEST_PATH/worlds/$WORLD_NAME
|
||||
|
||||
rm -R $WORLD_PATH
|
||||
|
||||
mkdir $WORLD_PATH
|
||||
|
||||
|
||||
echo "
|
||||
gameid = minetest
|
||||
auth_backend = sqlite3
|
||||
player_backend = sqlite3
|
||||
backend = sqlite3
|
||||
" > $WORLD_PATH/world.mt
|
||||
|
||||
cd ~/.zen/astrXbian/minetest
|
||||
cat ./minetest-common.conf > ./minetest.conf
|
||||
echo "
|
||||
|
||||
server_name = Astroport "$XZUID"
|
||||
|
||||
# Message of the day displayed to players connecting.
|
||||
# type: string
|
||||
motd = Bienvenue sur l'Astroport \""$XZUID"\". Un petit cube auto-hébergé par son heureux propriétaire.
|
||||
|
||||
server_description = Astroport
|
||||
|
||||
# Domain name of server, to be displayed in the serverlist.
|
||||
# type: string
|
||||
#server_address = astroport.com
|
||||
|
||||
# Homepage of server, to be displayed in the serverlist.
|
||||
# type: string
|
||||
#server_url = https://astroport.com
|
||||
|
||||
# Automatically report to the serverlist.
|
||||
# type: bool
|
||||
server_announce = false
|
||||
|
||||
# Network port to listen (UDP).
|
||||
# This value will be overridden when starting from the main menu.
|
||||
# type: int
|
||||
port = 30010
|
||||
|
||||
# The network interface that the server listens on.
|
||||
# type: string
|
||||
# bind_address =
|
||||
|
||||
|
||||
" >> ./minetest.conf
|
||||
|
||||
mkdir $WORLD_PATH/worldmods
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods ]; then
|
||||
mkdir $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
# ## mg - Experimental Mapgen for Minetest
|
||||
#
|
||||
# if [ ! -d $MINETEST_PATH/mods/mg-master ]; then
|
||||
#
|
||||
# if [ ! -f $MINETEST_PATH/mods/mg.zip ]; then
|
||||
# wget https://github.com/minetest-mods/mg/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/mg.zip
|
||||
# fi
|
||||
#
|
||||
# unzip $MINETEST_PATH/mods/mg.zip -d $MINETEST_PATH/mods
|
||||
# fi
|
||||
#
|
||||
# cp -r $MINETEST_PATH/mods/mg-master $WORLD_PATH/worldmods
|
||||
|
||||
|
||||
## startanode
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/startanode-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/startanode.zip ]; then
|
||||
wget https://github.com/minetest-mods/startanode/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/startanode.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/startanode.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/startanode-master $WORLD_PATH/worldmods
|
||||
|
||||
|
||||
|
||||
# ## Spawnbuilder
|
||||
#
|
||||
# spawnBuilderLocation=`find $MINETEST_PATH/mods -type d -name spawnbuilder`
|
||||
# if [ -z $spawnBuilderLocation ]; then
|
||||
#
|
||||
# if [ ! -f $MINETEST_PATH/mods/spawnbuilder.zip ]; then
|
||||
# wget https://repo.or.cz/minetest_spawnbuilder.git/snapshot/1.1.0.zip -O $MINETEST_PATH/mods/spawnbuilder.zip
|
||||
# fi
|
||||
#
|
||||
# unzip $MINETEST_PATH/mods/spawnbuilder.zip -d $MINETEST_PATH/mods/spawnbuilder/
|
||||
# fi
|
||||
#
|
||||
# mkdir $WORLD_PATH/worldmods/spawnbuilder
|
||||
# cp -r $MINETEST_PATH/mods/spawnbuilder/minetest_spawnbuilder-*/* $WORLD_PATH/worldmods/spawnbuilder
|
||||
#
|
||||
# echo "
|
||||
# #Side length of the surface area of the spawn platform
|
||||
# #If the number is odd, the platform will be centered at spawn.
|
||||
# #Using a width lower than 3 is not recommended.
|
||||
# spawnbuilder_width (Spawn platform width) int 5 1
|
||||
# " > $WORLD_PATH/worldmods/spawnbuilder/mod.conf
|
||||
|
||||
|
||||
|
||||
## Unified inventory mod
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/unified_inventory-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/unified_inventory.zip ]; then
|
||||
wget https://github.com/minetest-mods/unified_inventory/archive/master.zip -O $MINETEST_PATH/mods/unified_inventory.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/unified_inventory.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/unified_inventory-master $WORLD_PATH/worldmods
|
||||
|
||||
## Spawn mod
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/spawn_command-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/spawn_command.zip ]; then
|
||||
wget https://github.com/minetest-mods/spawn_command/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/spawn_command.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/spawn_command.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/spawn_command-master $WORLD_PATH/worldmods
|
||||
|
||||
|
||||
## Jukebok mod
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/jukebox-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/jukebox.zip ]; then
|
||||
wget https://github.com/minetest-mods/jukebox/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/jukebox.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/jukebox.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/jukebox-master $WORLD_PATH/worldmods
|
||||
|
||||
## xdecor mod
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/xdecor-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/xdecor.zip ]; then
|
||||
wget https://github.com/minetest-mods/xdecor/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/xdecor.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/xdecor.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/xdecor-master $WORLD_PATH/worldmods
|
||||
|
||||
## Display modpack
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/display_modpack-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/display_modpack.zip ]; then
|
||||
wget https://github.com/pyrollo/display_modpack/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/display_modpack.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/display_modpack.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/display_modpack-master $WORLD_PATH/worldmods
|
||||
|
||||
## Letters
|
||||
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/letters-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/letters.zip ]; then
|
||||
wget https://github.com/minetest-mods/letters/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/letters.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/letters.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/letters-master $WORLD_PATH/worldmods
|
||||
|
||||
## mydoors
|
||||
|
||||
|
||||
if [ ! -d $MINETEST_PATH/mods/mydoors-master ]; then
|
||||
|
||||
if [ ! -f $MINETEST_PATH/mods/mydoors.zip ]; then
|
||||
wget https://github.com/minetest-mods/mydoors/archive/refs/heads/master.zip -O $MINETEST_PATH/mods/mydoors.zip
|
||||
fi
|
||||
|
||||
unzip $MINETEST_PATH/mods/mydoors.zip -d $MINETEST_PATH/mods
|
||||
fi
|
||||
|
||||
cp -r $MINETEST_PATH/mods/mydoors-master $WORLD_PATH/worldmods
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
#!/bin/sh
|
||||
|
||||
/usr/lib/minetest/minetestserver --port 30010 --world /home/pi/.minetest/worlds/astroport --config /home/pi/.zen/astrXbian/minetest/minetest.conf
|
|
@ -0,0 +1,39 @@
|
|||
server {
|
||||
|
||||
root /home/pi/.zen/astrXbian/www/boris;
|
||||
listen 80 default_server;
|
||||
server_name _;
|
||||
|
||||
# This section can be copied into an existing default setup
|
||||
location / {
|
||||
allow all;
|
||||
index index.php index.html index.htm;
|
||||
location ~ \.php {
|
||||
try_files $uri index.php =404;
|
||||
fastcgi_pass unix:/run/php/php7.3-fpm.sock;
|
||||
fastcgi_index index.php;
|
||||
fastcgi_param SCRIPT_FILENAME $request_filename;
|
||||
include /etc/nginx/fastcgi_params;
|
||||
fastcgi_read_timeout 1800;
|
||||
}
|
||||
error_page 404 = /error/404.html;
|
||||
try_files $uri $uri/ =404;
|
||||
location ~ /albumart/* {
|
||||
expires -1s;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
location /ipfs {
|
||||
proxy_pass http://127.0.0.1:8181;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
}
|
||||
|
||||
location /ipns {
|
||||
proxy_pass http://127.0.0.1:8181;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Forwarded-For $remote_addr;
|
||||
}
|
||||
|
||||
}
|
|
@ -16,8 +16,7 @@ foreach ($videos as $v) {
|
|||
list($category, $videoID, $p3, $videoName, $p5, $src, $p7, $definition, $videoURI) = explode(";", $v);
|
||||
|
||||
|
||||
$videoURL = 'http://'. HOST. $videoURI;
|
||||
$videoEco = 'http://'. HOST. '/ipns/' . $p7;
|
||||
$videoEco = '/ipns/' . $p7;
|
||||
$mimeType = guessTypeFromFilename($videoURI);
|
||||
|
||||
|
||||
|
@ -38,7 +37,6 @@ foreach ($videos as $v) {
|
|||
'thumbURL' => $thumbURL,
|
||||
'category' => $category,
|
||||
'mime' => $mimeType,
|
||||
'url' => $videoURL,
|
||||
'eco' => $videoEco,
|
||||
'uri' => $videoURI,
|
||||
'name' => $videoName,
|
||||
|
|
|
@ -2,7 +2,8 @@
|
|||
require_once('functions.php');
|
||||
require_once('conf.php');
|
||||
|
||||
$videoURL = 'http://'. HOST. htmlentities($_GET['uri']);
|
||||
//$videoURL = 'http://'. HOST;
|
||||
$videoURL = htmlentities($_GET['uri']);
|
||||
$videoName = htmlentities(urldecode($_GET['name']));
|
||||
$videoMIME = htmlentities($_GET['mime']);
|
||||
|
||||
|
|
|
@ -4,13 +4,13 @@
|
|||
<title>$TITLE in Astroport</title>
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="Refresh" content="7;URL=http://astroport/ipns/$IPNSLINK/${G1PUB}/">
|
||||
<link rel='stylesheet' href='http://astroport/styles/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='http://astroport/styles/astroport/logo.png' />
|
||||
<link rel='stylesheet' href='/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='/styles/astroport/logo.png' />
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<h6>
|
||||
<a href='http://astroport/'><span>ASTROPORT</span> <q>${XZUID}</q></a>
|
||||
<a href='/'><span>ASTROPORT</span> <q>${XZUID}</q></a>
|
||||
</h6>
|
||||
</header>
|
||||
<main>
|
||||
|
@ -50,4 +50,4 @@
|
|||
</article>
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
<head>
|
||||
<title>$TITLE in Astroport</title>
|
||||
<meta charset="UTF-8">
|
||||
<link rel='stylesheet' href='http://astroport/styles/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='http://astroport/styles/astroport/logo.png' />
|
||||
<link rel='stylesheet' href='/styles/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='/styles/astroport/logo.png' />
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
|
@ -16,8 +16,8 @@
|
|||
<main>
|
||||
<article>
|
||||
<video autoplay="autoplay" controls>
|
||||
<source src="http://astroport/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">
|
||||
<a href="http://astroport/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">$TITLE</a>
|
||||
<source src="/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">
|
||||
<a href="/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">$TITLE</a>
|
||||
</video>
|
||||
|
||||
<h1 class="video-title">
|
||||
|
|
|
@ -298,13 +298,13 @@ cat >~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/index.html <<EOF
|
|||
<title>$TITLE in Astroport</title>
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="Refresh" content="7;URL=http://astroport/ipns/$IPNSLINK/${G1PUB}/">
|
||||
<link rel='stylesheet' href='http://astroport/styles/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='http://astroport/styles/astroport/logo.png' />
|
||||
<link rel='stylesheet' href='/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='/styles/astroport/logo.png' />
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
<h6>
|
||||
<a href='http://astroport/'><span>ASTROPORT</span> <q>${XZUID}</q></a>
|
||||
<a href='/'><span>ASTROPORT</span> <q>${XZUID}</q></a>
|
||||
</h6>
|
||||
</header>
|
||||
<main>
|
||||
|
@ -344,7 +344,7 @@ cat >~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/index.html <<EOF
|
|||
</article>
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
||||
EOF
|
||||
|
||||
|
@ -358,8 +358,8 @@ cat > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/${G1PUB}/index.html <<EOF
|
|||
<head>
|
||||
<title>$TITLE in Astroport</title>
|
||||
<meta charset="UTF-8">
|
||||
<link rel='stylesheet' href='http://astroport/styles/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='http://astroport/styles/astroport/logo.png' />
|
||||
<link rel='stylesheet' href='/styles/astroport/style.css' type='text/css' />
|
||||
<link rel='icon' type='image/png' href='/styles/astroport/logo.png' />
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
|
@ -371,8 +371,8 @@ cat > ~/.zen/ipfs/.${IPFSNODEID}/KEY/${MEDIAKEY}/${G1PUB}/index.html <<EOF
|
|||
<main>
|
||||
<article>
|
||||
<video autoplay="autoplay" controls>
|
||||
<source src="http://astroport/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">
|
||||
<a href="http://astroport/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">$TITLE</a>
|
||||
<source src="/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">
|
||||
<a href="/ipfs/$IPFSREPFILEID/$URLENCODE_FILE_NAME">$TITLE</a>
|
||||
</video>
|
||||
|
||||
<h1 class="video-title">
|
||||
|
|
Loading…
Reference in New Issue