mirror of
https://github.com/YunoHost-Apps/pufferpanel_ynh.git
synced 2024-09-03 20:16:03 +02:00
Merge pull request #14 from YunoHost-Apps/datadir
moving the data folder to the standard ynh one
This commit is contained in:
commit
696f111be0
4 changed files with 25 additions and 6 deletions
|
@ -11,8 +11,8 @@
|
||||||
},
|
},
|
||||||
"daemon": {
|
"daemon": {
|
||||||
"data": {
|
"data": {
|
||||||
"cache": "/var/lib/__APP__/cache",
|
"cache": "__DATA_DIR__/cache",
|
||||||
"servers": "/var/lib/__APP__/servers"
|
"servers": "__DATA_DIR__/servers"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"web": {
|
"web": {
|
||||||
|
|
1
doc/ADMIN.md
Normal file
1
doc/ADMIN.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Game server files are stored in `__DATA_DIR__`
|
|
@ -7,7 +7,8 @@ description.fr = "Système de gestion de serveur de jeu"
|
||||||
|
|
||||||
version = "2.6.9~ynh2"
|
version = "2.6.9~ynh2"
|
||||||
|
|
||||||
maintainers = [""]
|
maintainers = [ "" ]
|
||||||
|
|
||||||
|
|
||||||
[upstream]
|
[upstream]
|
||||||
license = "Apache-2.0"
|
license = "Apache-2.0"
|
||||||
|
@ -15,6 +16,7 @@ website = "https://www.pufferpanel.com/"
|
||||||
admindoc = "https://docs.pufferpanel.com/en/latest/"
|
admindoc = "https://docs.pufferpanel.com/en/latest/"
|
||||||
code = "https://github.com/PufferPanel/PufferPanel"
|
code = "https://github.com/PufferPanel/PufferPanel"
|
||||||
|
|
||||||
|
|
||||||
[integration]
|
[integration]
|
||||||
yunohost = ">= 11.2"
|
yunohost = ">= 11.2"
|
||||||
architectures = "all"
|
architectures = "all"
|
||||||
|
@ -25,6 +27,7 @@ disk = "50M"
|
||||||
ram.build = "350M"
|
ram.build = "350M"
|
||||||
ram.runtime = "50M"
|
ram.runtime = "50M"
|
||||||
|
|
||||||
|
|
||||||
[install]
|
[install]
|
||||||
[install.domain]
|
[install.domain]
|
||||||
type = "domain"
|
type = "domain"
|
||||||
|
@ -41,12 +44,16 @@ ram.runtime = "50M"
|
||||||
[install.password]
|
[install.password]
|
||||||
type = "password"
|
type = "password"
|
||||||
|
|
||||||
|
|
||||||
[resources]
|
[resources]
|
||||||
[resources.system_user]
|
[resources.system_user]
|
||||||
allow_email = true
|
allow_email = true
|
||||||
|
|
||||||
[resources.install_dir]
|
[resources.install_dir]
|
||||||
|
|
||||||
|
[resources.data_dir]
|
||||||
|
subdirs = [ "binaries", "cache", "servers" ]
|
||||||
|
|
||||||
[resources.ports]
|
[resources.ports]
|
||||||
|
|
||||||
[resources.permissions]
|
[resources.permissions]
|
||||||
|
@ -62,4 +69,3 @@ ram.runtime = "50M"
|
||||||
|
|
||||||
[resources.database]
|
[resources.database]
|
||||||
type = "postgresql"
|
type = "postgresql"
|
||||||
|
|
|
@ -30,6 +30,18 @@ ynh_script_progression --message="Stopping a systemd service..."
|
||||||
|
|
||||||
ynh_systemd_action --service_name="$app" --action="stop" --log_path="systemd"
|
ynh_systemd_action --service_name="$app" --action="stop" --log_path="systemd"
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# ENSURE DOWNWARD COMPATIBILITY
|
||||||
|
#=================================================
|
||||||
|
ynh_script_progression --message="Ensuring downward compatibility..."
|
||||||
|
|
||||||
|
# moving the data folder to the standard ynh one
|
||||||
|
if [ -d "/var/lib/$app" ]; then
|
||||||
|
ynh_print_info --message="Moving the data folder from '/var/lib/$app' to '$data_dir'"
|
||||||
|
mv "/var/lib/$app" "$data_dir"
|
||||||
|
ynh_secure_remove "/var/lib/$app"
|
||||||
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# UPGRADE DEPENDENCIES
|
# UPGRADE DEPENDENCIES
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
Loading…
Add table
Reference in a new issue