From f18abb1128e4d8c35aa8b075c0a60fb1a25ac214 Mon Sep 17 00:00:00 2001 From: siwinter <45730097+siwinter@users.noreply.github.com> Date: Wed, 25 Aug 2021 16:19:03 +0200 Subject: [PATCH] MPD extension --- scripts/restore | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/restore b/scripts/restore index faa5fd6..e66af1c 100755 --- a/scripts/restore +++ b/scripts/restore @@ -27,6 +27,7 @@ app=$YNH_APP_INSTANCE_NAME domain=$(ynh_app_setting_get --app=$app --key=domain) path_url=$(ynh_app_setting_get --app=$app --key=path) final_path=$(ynh_app_setting_get --app=$app --key=final_path) +mpd_port=$(ynh_app_setting_get --app=$app --key=mpd_port) # other variables media_dir="/home/yunohost.multimedia/share/Music" @@ -86,6 +87,14 @@ chown -R $app:www-data "$final_path" #================================================= # SPECIFIC RESTORATION +#================================================= +# OPEN PORT +#================================================= + +if [ $mpd_port -ne 0 ]; then + ynh_exec_warn_less yunohost firewall allow --no-upnp TCP $mpd_port +fi + #================================================= # REINSTALL DEPENDENCIES #=================================================