documentation/services/minetest.libre-service.eu.md

100 lines
2.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Minetest
# Installation
Ouvrir les ports nécessaires :
```
iptables -A INPUT -i $WAN -p udp --dport 30000 -j ACCEPT
```
Installer le serveur Minetest :
```
apt-get install minetest-server minetestmapper
```
# Mineclone2
## Install
Récupérer le zip :
* https://content.minetest.net/packages/Wuzzy/mineclone2/
* cliquer sur le bouton `Download`
Décompresser :
```
unzip mineclone2_6745.zip
```
Ranger dans l'arborescence de Minetest :
```
mv mineclone2 /usr/share/games/minetest/games/
```
## Création d'un monde
Créer un fichier de configuration vierge :
```
cp /etc/minetest/minetest.conf /etc/minetest/fooland.conf
```
Éditer le fichier de configuration :
```
- server_name = My Minetest server
+ server_name = Miclouland Mineclone2 LibreServiceEU
- server_description = Minetest server powered by Debian
+ server_description = Mineclone2 en libre-service sur LibreServiceEU
- server_address = minetest.libre-service.eu
+ server_url = https://minetest.libre-service.eu/
- default_game = minetest
+ default_game = mineclone2
- motd = Welcome to Minetest. Enjoy your stay!
+ motd = Bienvenue sur le Minetest de Libre-service.eu \o/
- max_users = 15
+ max_users = 64
- enable_damage = false
+ enable_damage = true
- # disallow_empty_password = false
+ disallow_empty_password = false
```
Créer le nouveau monde :
```
systemctl start minetest-server@fooland.service
```
Tester le nouveau monde en se connectant avec client Minetest.
Migrer le nouveau monde vers le backend Postgres :
```
systemctl stop minetest-server@fooland.service
minetestserver --migrate PostgreSQL --world TODOOOOOOOOOOOOOO
```
Optimiser Postgresql :
- en modifiant `/etc/postgresql/13/main/postgresql.conf` :
```
-shared_buffers = 128MB # min 128kB
+shared_buffers = 512MB # min 128kB
```
- avoir au moins 512MB de mémoire disponible pour Minetest hors Postgresql.
Vérifier les réglages du backend dans `/TODO` :
```
backend = postgresql
pgsql_connection = host=127.0.0.1 port=5432 user=minetest password=XXXXX dbname=minetest-fooland-db
auth_backend = postgresql
pgsql_auth_connection = host=127.0.0.1 port=5432 user=minetest password=XXXXXX dbname=minetest-fooland-auth
player_backend = postgresql
pgsql_player_connection = host=127.0.0.1 port=5432 user=minetest password=XXXXXX dbname=minetest-fooland-users
```
## Play
Information about Mineclone2 : https://wiki.minetest.net/Games/MineClone_2/Differences_from_Minetest_Game