mirror of
https://github.com/YunoHost-Apps/funkwhale_ynh.git
synced 2024-09-03 18:36:24 +02:00
Remove port openning
This commit is contained in:
parent
860cb41ea2
commit
c22807493e
2 changed files with 10 additions and 1 deletions
|
@ -63,7 +63,6 @@ ynh_app_setting_set "$app" admin "$admin"
|
|||
# Find a free port
|
||||
port=$(ynh_find_port 5000)
|
||||
# Open this port
|
||||
yunohost firewall allow --no-upnp TCP "$port" 2>&1
|
||||
ynh_app_setting_set "$app" port "$port"
|
||||
|
||||
#=================================================
|
||||
|
|
|
@ -69,6 +69,16 @@ path_url=$(ynh_normalize_url_path "$path_url")
|
|||
|
||||
#=================================================
|
||||
# STANDARD UPGRADE STEPS
|
||||
#=================================================
|
||||
# CLOSE A PORT
|
||||
#=================================================
|
||||
|
||||
if yunohost firewall list | grep -q "\- $port$"
|
||||
then
|
||||
echo "Close port $port"
|
||||
yunohost firewall disallow TCP $port 2>&1
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue