1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/minchat_ynh.git synced 2024-09-03 19:36:29 +02:00

[fix] clean code & fix is_public to restore

This commit is contained in:
magikcypress 2017-05-08 19:25:22 +02:00
parent d4c46fa38d
commit 85283b25fc
2 changed files with 13 additions and 5 deletions

View file

@ -22,18 +22,21 @@ CHECK_DOMAINPATH
CHECK_FINALPATH
# Save app settings
ynh_app_setting_set $app domain $domain
ynh_app_setting_set $app path $path
ynh_app_setting_set $app is_public $is_public
# Create system user dedicace for this app
ynh_system_user_create $app
# Copy files to the right place
final_path=/var/www/$app
sudo mkdir -p $final_path
extract_source $final_path
ynh_app_setting_set $app final_path $final_path
# Copy files to the right place with the right permissions
final_path=/var/www/$app
sudo mkdir -p $final_path
sudo chown -R $app: $final_path
# Get source application
extract_source $final_path
# Modify Nginx configuration file and copy it to Nginx conf directory
ynh_nginx_config

View file

@ -71,6 +71,11 @@ if [[ $is_public -eq 0 ]]; then
ynh_app_setting_delete $app skipped_uris
fi
if [ $is_public -eq 1 ]
then
ynh_app_setting_set $app skipped_uris "/" # Make app public if necessary
fi
# Reload service
sudo systemctl reload nginx
sudo yunohost app ssowatconf