mirror of
https://github.com/YunoHost-Apps/hotspot_ynh.git
synced 2024-09-03 19:25:53 +02:00
commit
dc7139bed4
2 changed files with 12 additions and 15 deletions
|
@ -289,12 +289,6 @@ devfromid() {
|
|||
|
||||
if [ "$1" != restart ]; then
|
||||
|
||||
# Restart php7.0-fpm at the first start (it needs to be restarted after the slapd start)
|
||||
if [ ! -e /tmp/.ynh-hotspot-boot ]; then
|
||||
touch /tmp/.ynh-hotspot-boot
|
||||
systemctl restart php__PHPVERSION__-fpm
|
||||
fi
|
||||
|
||||
# Variables
|
||||
|
||||
echo -n "Retrieving Yunohost settings... "
|
||||
|
@ -337,6 +331,12 @@ case "$1" in
|
|||
elif [ "${ynh_service_enabled}" != "enabled" ]; then
|
||||
echo "Disabled service"
|
||||
else
|
||||
|
||||
if [ -z "${ynh_wifi_device}" ]; then
|
||||
echo "[ERR] No wifi device selected. Make sure your wifi antenna is plugged-in / available and select it in the Hotspot admin"
|
||||
exitcode=1
|
||||
fi
|
||||
|
||||
echo "[hotspot] Starting..."
|
||||
touch /tmp/.ynh-hotspot-started
|
||||
|
||||
|
@ -488,6 +488,11 @@ case "$1" in
|
|||
exitcode=1
|
||||
fi
|
||||
|
||||
if [ -z "${ynh_wifi_device}" ]; then
|
||||
echo "[ERR] No wifi device selected. Make sure your wifi antenna is plugged-in / available and select it in the Hotspot admin"
|
||||
exitcode=1
|
||||
fi
|
||||
|
||||
echo "[INFO] Autodetected internet interface: ${new_internet_device} (last start: ${old_internet_device})"
|
||||
|
||||
if is_nat_set "${new_internet_device}"; then
|
||||
|
|
|
@ -144,7 +144,7 @@ fi
|
|||
#=================================================
|
||||
# INSTALL DEPENDENCIES
|
||||
#=================================================
|
||||
ynh_script_progression --message="Creating a MySQL database..."
|
||||
ynh_script_progression --message="Installing dependencies"
|
||||
|
||||
ynh_install_app_dependencies "$pkg_dependencies" "$packages"
|
||||
|
||||
|
@ -323,14 +323,6 @@ else
|
|||
ynh_systemd_action --service_name=$service_name --action="start" --log_path=systemd #--line_match="Started YunoHost Wifi Hotspot"
|
||||
fi
|
||||
|
||||
#=================================================
|
||||
# RELOAD NGINX AND PHP-FPM
|
||||
#=================================================
|
||||
ynh_script_progression --message="Reloading nginx web server..."
|
||||
|
||||
ynh_systemd_action --service_name=php$phpversion-fpm --action=reload
|
||||
ynh_systemd_action --service_name=nginx --action=reload
|
||||
|
||||
#=================================================
|
||||
# END OF SCRIPT
|
||||
#=================================================
|
||||
|
|
Loading…
Add table
Reference in a new issue