1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/shlink_ynh.git synced 2024-09-03 20:16:22 +02:00

Merge branch 'testing'

This commit is contained in:
Éric Gaspar 2023-01-10 20:53:45 +01:00
commit 8fe66a7ea0
3 changed files with 12 additions and 6 deletions

View file

@ -1,4 +1,5 @@
location / { #sub_path_only rewrite ^__PATH__$ __PATH__/ permanent;
location __PATH__/ {
# Path to source # Path to source
alias __FINALPATH__/; alias __FINALPATH__/;

View file

@ -113,13 +113,10 @@ ynh_add_nginx_config
ynh_script_progression --message="Adding a configuration file..." --weight=2 ynh_script_progression --message="Adding a configuration file..." --weight=2
ynh_add_config --template="../conf/.env-sample" --destination="$final_path/.env" ynh_add_config --template="../conf/.env-sample" --destination="$final_path/.env"
#ynh_add_config --template="../conf/servers.json" --destination="$final_path/servers.json"
chmod 400 "$final_path/.env" chmod 400 "$final_path/.env"
chown $app:$app "$final_path/.env" chown $app:$app "$final_path/.env"
#$final_path/bin/cli api-key:generate --domain-only=$domain
#================================================= #=================================================
# SETUP SSOWAT # SETUP SSOWAT
#================================================= #=================================================

View file

@ -24,7 +24,7 @@ ynh_abort_if_errors
#================================================= #=================================================
# LOAD SETTINGS # LOAD SETTINGS
#================================================= #=================================================
ynh_script_progression --message="Loading installation settings..." --time --weight=1 ynh_script_progression --message="Loading installation settings..." --weight=1
app=$YNH_APP_INSTANCE_NAME app=$YNH_APP_INSTANCE_NAME
@ -39,7 +39,7 @@ phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#================================================= #=================================================
# CHECK IF THE APP CAN BE RESTORED # CHECK IF THE APP CAN BE RESTORED
#================================================= #=================================================
ynh_script_progression --message="Validating restoration parameters..." --time --weight=1 ynh_script_progression --message="Validating restoration parameters..." --weight=1
test ! -d $final_path \ test ! -d $final_path \
|| ynh_die --message="There is already a directory: $final_path " || ynh_die --message="There is already a directory: $final_path "
@ -65,6 +65,14 @@ chmod 750 "$final_path"
chmod -R o-rwx "$final_path" chmod -R o-rwx "$final_path"
chown -R $app:www-data "$final_path" chown -R $app:www-data "$final_path"
#=================================================
# REINSTALL DEPENDENCIES
#=================================================
ynh_script_progression --message="Reinstalling dependencies..." --weight=1
# Define and install dependencies
ynh_install_app_dependencies $pkg_dependencies
#================================================= #=================================================
# RESTORE THE PHP-FPM CONFIGURATION # RESTORE THE PHP-FPM CONFIGURATION
#================================================= #=================================================