mirror of
https://github.com/YunoHost-Apps/pufferpanel_ynh.git
synced 2024-09-03 20:16:03 +02:00
moving the data folder to the standard ynh one
This commit is contained in:
parent
1bc3c13261
commit
94f627e963
4 changed files with 49 additions and 30 deletions
|
@ -11,12 +11,12 @@
|
||||||
},
|
},
|
||||||
"daemon": {
|
"daemon": {
|
||||||
"data": {
|
"data": {
|
||||||
"cache": "/var/lib/__APP__/cache",
|
"cache": "__DATA_DIR__/cache",
|
||||||
"servers": "/var/lib/__APP__/servers"
|
"servers": "__DATA_DIR__/servers"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"web": {
|
"web": {
|
||||||
"host": "127.0.0.1:__PORT__"
|
"host": "127.0.0.1:__PORT__"
|
||||||
},
|
},
|
||||||
"panel": {
|
"panel": {
|
||||||
"email": {
|
"email": {
|
||||||
|
|
1
doc/ADMIN.md
Normal file
1
doc/ADMIN.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Game server files are stored in `__DATA_DIR__`
|
|
@ -9,12 +9,14 @@ version = "2.6.9~ynh2"
|
||||||
|
|
||||||
maintainers = [""]
|
maintainers = [""]
|
||||||
|
|
||||||
|
|
||||||
[upstream]
|
[upstream]
|
||||||
license = "Apache-2.0"
|
license = "Apache-2.0"
|
||||||
website = "https://www.pufferpanel.com/"
|
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,41 +27,45 @@ disk = "50M"
|
||||||
ram.build = "350M"
|
ram.build = "350M"
|
||||||
ram.runtime = "50M"
|
ram.runtime = "50M"
|
||||||
|
|
||||||
|
|
||||||
[install]
|
[install]
|
||||||
[install.domain]
|
[install.domain]
|
||||||
type = "domain"
|
type = "domain"
|
||||||
|
|
||||||
[install.init_main_permission]
|
[install.init_main_permission]
|
||||||
type = "group"
|
type = "group"
|
||||||
default = "visitors"
|
default = "visitors"
|
||||||
|
|
||||||
[install.admin]
|
[install.admin]
|
||||||
help.en = "Admin username minimum length is five characters."
|
help.en = "Admin username minimum length is five characters."
|
||||||
help.fr = "La longueur minimale du nom d'utilisateur de l'administrateur est de cinq caractères."
|
help.fr = "La longueur minimale du nom d'utilisateur de l'administrateur est de cinq caractères."
|
||||||
type = "user"
|
type = "user"
|
||||||
|
|
||||||
|
[install.password]
|
||||||
|
type = "password"
|
||||||
|
|
||||||
[install.password]
|
|
||||||
type = "password"
|
|
||||||
|
|
||||||
[resources]
|
[resources]
|
||||||
[resources.system_user]
|
[resources.system_user]
|
||||||
allow_email = true
|
allow_email = true
|
||||||
|
|
||||||
[resources.install_dir]
|
[resources.install_dir]
|
||||||
|
|
||||||
[resources.ports]
|
[resources.data_dir]
|
||||||
|
subdirs = ["binaries", "cache", "servers"]
|
||||||
|
|
||||||
[resources.permissions]
|
[resources.ports]
|
||||||
main.url = "/"
|
|
||||||
main.auth_header = false
|
|
||||||
|
|
||||||
[resources.apt]
|
[resources.permissions]
|
||||||
packages = "postgresql"
|
main.url = "/"
|
||||||
|
main.auth_header = false
|
||||||
|
|
||||||
extras.pufferpanel.repo = "deb https://packagecloud.io/pufferpanel/pufferpanel/debian/ buster main"
|
[resources.apt]
|
||||||
extras.pufferpanel.key = "https://packagecloud.io/pufferpanel/pufferpanel/gpgkey"
|
packages = "postgresql"
|
||||||
extras.pufferpanel.packages = "pufferpanel"
|
|
||||||
|
|
||||||
[resources.database]
|
extras.pufferpanel.repo = "deb https://packagecloud.io/pufferpanel/pufferpanel/debian/ buster main"
|
||||||
type = "postgresql"
|
extras.pufferpanel.key = "https://packagecloud.io/pufferpanel/pufferpanel/gpgkey"
|
||||||
|
extras.pufferpanel.packages = "pufferpanel"
|
||||||
|
|
||||||
|
[resources.database]
|
||||||
|
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"
|
||||||
|
rm -r "/var/lib/$app"
|
||||||
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# UPGRADE DEPENDENCIES
|
# UPGRADE DEPENDENCIES
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
Loading…
Add table
Reference in a new issue