mirror of
https://github.com/YunoHost-Apps/minetest_ynh.git
synced 2024-09-03 20:36:00 +02:00
commit
7e99935a63
14 changed files with 74 additions and 24 deletions
|
@ -17,6 +17,8 @@
|
|||
setup_private=0
|
||||
setup_public=0
|
||||
upgrade=1
|
||||
# 5.4.1~ynh2
|
||||
upgrade=1 from_commit=bd09fd83cb3f127d242f551786d49202a434c4b2
|
||||
backup_restore=1
|
||||
multi_instance=1
|
||||
incorrect_path=0
|
||||
|
|
|
@ -4,3 +4,4 @@ SOURCE_SUM_PRG=sha256sum
|
|||
SOURCE_FORMAT=tar.gz
|
||||
SOURCE_IN_SUBDIR=true
|
||||
SOURCE_FILENAME=minetest-5.4.1.tar.gz
|
||||
SOURCE_EXTRACT=true
|
||||
|
|
0
doc/.gitkeep
Normal file
0
doc/.gitkeep
Normal file
1
doc/DESCRIPTION.md
Normal file
1
doc/DESCRIPTION.md
Normal file
|
@ -0,0 +1 @@
|
|||
Minetest is a free open-source voxel game engine with easy modding and game creation.
|
1
doc/DESCRIPTION_fr.md
Normal file
1
doc/DESCRIPTION_fr.md
Normal file
|
@ -0,0 +1 @@
|
|||
Minetest est un moteur de jeu voxel open-source avec modding et création de jeux faciles.
|
22
doc/DISCLAIMER.md
Normal file
22
doc/DISCLAIMER.md
Normal file
|
@ -0,0 +1,22 @@
|
|||
## Configuration
|
||||
|
||||
How to configure this app: by SSH
|
||||
|
||||
## Additional information
|
||||
|
||||
* Migration from old package
|
||||
|
||||
* You can’t migrate directly with an update.
|
||||
* Before installing the new package you need to download this folder from your server `/var/games/minetest-server/.minetest/worlds/world` (this folder contains all world data)
|
||||
* Uninstall the old package `sudo yunohost app remove minetest`
|
||||
* Install the new one `sudo yunohost app install https://github.com/YunoHost-Apps/minetest_ynh`
|
||||
* Stop Minetest service `sudo systemctl stop minetest`
|
||||
* Copy the folder you have copied before in `/home/yunohost.app/minetest/.minetest/worlds`
|
||||
* Start the Minetest service `sudo systemctl start minetest`
|
||||
|
||||
* Installing mods
|
||||
* For installing mods you need to create a `worldmods` folder in `/home/yunohost.app/minetest/.minetest/worlds/world/`
|
||||
* Clone the repo of the mod in this folder (ex: `git clone https://github.com/minetest-mods/mesecons`)
|
||||
* Edit `/home/yunohost.app/minetest/.minetest/worlds/world/world.mt` and add at the end `load_mod_mesecons = true`
|
||||
* Restart Minetest with `sudo systemctl restart minetest`
|
||||
* The mod is now installed :)
|
22
doc/DISCLAIMER_fr.md
Normal file
22
doc/DISCLAIMER_fr.md
Normal file
|
@ -0,0 +1,22 @@
|
|||
## Configuration
|
||||
|
||||
Comment configurer cette application : par SSH
|
||||
|
||||
## Renseignements supplémentaires
|
||||
|
||||
* Migration de l’ancien paquet
|
||||
|
||||
* Vous ne pouvez pas migrer directement avec une mise à jour.
|
||||
* Avant d’installer le nouveau paquet, vous devez télécharger ce dossier depuis votre serveur `/var/games/minetest-server/.minetest/worlds/world` (ce dossier contient toutes les données des mondes)
|
||||
* Désinstallez l’ancien paquet `sudo yunohost app remove minetest`
|
||||
* Installez le nouveau `sudo yunohost app install https://github.com/YunoHost-Apps/minetest_ynh`
|
||||
* Stoppez le service Minetest `sudo systemctl stop minetest`
|
||||
* Copiez le dossier que vous avez copié auparavant dans `/home/yunohost.app/minetest/.minetest/.worlds`
|
||||
* Démarrez le service Minetest `sudo systemctl start minetest`
|
||||
|
||||
* Installation des mods
|
||||
* Pour installer des mods, vous devez créer un dossier `worldmods` dans `/home/yunohost.app/minetest/.minetest/worlds/world/`
|
||||
* Clonez le repo du mod dans ce dossier (ex : `git clone https://github.com/minetest-mods/mesecons`)
|
||||
* Éditez `/home/yunohost.app/minetest/.minetest/worlds/world/world/world.mt` et ajoutez à la fin `load_mod_mesecons = true`
|
||||
* Redémarrez Minetest avec `sudo systemctl restart minetest`
|
||||
* Le mod est maintenant installé :)
|
0
doc/screenshots/.gitkeep
Normal file
0
doc/screenshots/.gitkeep
Normal file
BIN
doc/screenshots/1.jpg
Normal file
BIN
doc/screenshots/1.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 235 KiB |
|
@ -8,6 +8,11 @@
|
|||
},
|
||||
"version": "5.4.1~ynh2",
|
||||
"url": "http://www.minetest.net/",
|
||||
"upstream": {
|
||||
"license": "MIT",
|
||||
"website": "http://www.minetest.net",
|
||||
"code": "https://github.com/minetest/minetest"
|
||||
},
|
||||
"license": "MIT",
|
||||
"maintainer": {
|
||||
"name": "rafi59",
|
||||
|
@ -17,10 +22,10 @@
|
|||
"previous_maintainers": {
|
||||
"name": "Luc Didry",
|
||||
"email": "luc@framasoft.org",
|
||||
"url": "https://framasoft.org"
|
||||
"url": "https://framasoft.org"
|
||||
},
|
||||
"requirements": {
|
||||
"yunohost": ">= 4.1.7"
|
||||
"yunohost": ">= 4.3.0"
|
||||
},
|
||||
"multi_instance": true,
|
||||
"services": [
|
||||
|
@ -30,8 +35,7 @@
|
|||
"install" : [
|
||||
{
|
||||
"name": "domain",
|
||||
"type": "domain",
|
||||
"example": "domain.org"
|
||||
"type": "domain"
|
||||
},
|
||||
{
|
||||
"name": "is_public",
|
||||
|
|
|
@ -15,7 +15,7 @@ source /usr/share/yunohost/helpers
|
|||
#=================================================
|
||||
|
||||
ynh_clean_setup () {
|
||||
ynh_clean_check_starting
|
||||
true
|
||||
}
|
||||
# Exit if an error occurs during the execution of the script
|
||||
ynh_abort_if_errors
|
||||
|
|
|
@ -42,12 +42,12 @@ ynh_script_progression --message="Stopping and removing the systemd service..."
|
|||
ynh_remove_systemd_config
|
||||
|
||||
#=================================================
|
||||
# REMOVE DEPENDENCIES
|
||||
# REMOVE LOGROTATE CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Removing dependencies..."
|
||||
ynh_script_progression --message="Removing logrotate configuration..."
|
||||
|
||||
# Remove metapackage and its dependencies
|
||||
ynh_remove_app_dependencies
|
||||
# Remove the app-specific logrotate config
|
||||
ynh_remove_logrotate
|
||||
|
||||
#=================================================
|
||||
# REMOVE APP MAIN DIR
|
||||
|
@ -58,12 +58,12 @@ ynh_script_progression --message="Removing app main directory..."
|
|||
ynh_secure_remove --file="$final_path"
|
||||
|
||||
#=================================================
|
||||
# REMOVE LOGROTATE CONFIGURATION
|
||||
# REMOVE DEPENDENCIES
|
||||
#=================================================
|
||||
ynh_script_progression --message="Removing logrotate configuration..."
|
||||
ynh_script_progression --message="Removing dependencies..."
|
||||
|
||||
# Remove the app-specific logrotate config
|
||||
ynh_remove_logrotate
|
||||
# Remove metapackage and its dependencies
|
||||
ynh_remove_app_dependencies
|
||||
|
||||
#=================================================
|
||||
# CLOSE A PORT
|
||||
|
@ -71,7 +71,7 @@ ynh_remove_logrotate
|
|||
|
||||
if yunohost firewall list | grep -q "\- $port$"
|
||||
then
|
||||
ynh_script_progression --message="Closing port $port"
|
||||
ynh_script_progression --message="Closing port $port..."
|
||||
ynh_exec_warn_less yunohost firewall disallow UDP $port
|
||||
fi
|
||||
|
||||
|
|
|
@ -86,6 +86,13 @@ ynh_script_progression --message="Restoring the systemd configuration..."
|
|||
ynh_restore_file --origin_path="/etc/systemd/system/$app.service"
|
||||
systemctl enable $app.service --quiet
|
||||
|
||||
#=================================================
|
||||
# RESTORE THE LOGROTATE CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Restoring the logrotate configuration..."
|
||||
|
||||
ynh_restore_file --origin_path="/etc/logrotate.d/$app"
|
||||
|
||||
#=================================================
|
||||
# INTEGRATE SERVICE IN YUNOHOST
|
||||
#=================================================
|
||||
|
@ -100,13 +107,6 @@ ynh_script_progression --message="Starting a systemd service..."
|
|||
|
||||
ynh_systemd_action --service_name=$app --action="start" --log_path="/var/log/$app/minetest.log" --line_match="listening on"
|
||||
|
||||
#=================================================
|
||||
# RESTORE THE LOGROTATE CONFIGURATION
|
||||
#=================================================
|
||||
ynh_script_progression --message="Restoring the logrotate configuration..."
|
||||
|
||||
ynh_restore_file --origin_path="/etc/logrotate.d/$app"
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALIZATION
|
||||
#=================================================
|
||||
|
|
|
@ -25,7 +25,6 @@ pvp=$(ynh_app_setting_get --app=$app --key=pvp)
|
|||
creative=$(ynh_app_setting_get --app=$app --key=creative)
|
||||
damage=$(ynh_app_setting_get --app=$app --key=damage)
|
||||
servername=$(ynh_app_setting_get --app=$app --key=servername)
|
||||
is_public=$(ynh_app_setting_get --app=$app --key=is_public)
|
||||
|
||||
#=================================================
|
||||
# CHECK VERSION
|
||||
|
@ -43,7 +42,6 @@ ynh_script_progression --message="Backing up the app before upgrading (may take
|
|||
ynh_backup_before_upgrade
|
||||
ynh_clean_setup () {
|
||||
ynh_clean_check_starting
|
||||
|
||||
# Restore it if the upgrade fails
|
||||
ynh_restore_upgradebackup
|
||||
}
|
||||
|
@ -102,7 +100,6 @@ ynh_system_user_create --username=$app --home_dir=$home_path --use_shell
|
|||
#=================================================
|
||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||
#=================================================
|
||||
ynh_script_progression --message="Upgrading source files..."
|
||||
|
||||
if [ "$upgrade_type" == "UPGRADE_APP" ]
|
||||
then
|
||||
|
|
Loading…
Reference in a new issue