mirror of
https://github.com/YunoHost-Apps/nextcloud_ynh.git
synced 2024-09-03 19:55:57 +02:00
Merge branch 'testing' into v2_PostgreSQL
This commit is contained in:
commit
2f88a3e043
3 changed files with 10 additions and 2 deletions
|
@ -45,7 +45,7 @@ is_url_handled() {
|
||||||
# Return 1 if the URL isn't handled.
|
# Return 1 if the URL isn't handled.
|
||||||
# Which means either cURL got a 404 (or the admin) or the SSO.
|
# Which means either cURL got a 404 (or the admin) or the SSO.
|
||||||
# A handled URL should redirect to a publicly accessible URL.
|
# A handled URL should redirect to a publicly accessible URL.
|
||||||
# Return 1 if the url has returned 404
|
# Return 1 if the URL has returned 404
|
||||||
if [ "$http_code" = "404" ] || [[ $redirection =~ "/yunohost/admin" ]]; then
|
if [ "$http_code" = "404" ] || [[ $redirection =~ "/yunohost/admin" ]]; then
|
||||||
return 1
|
return 1
|
||||||
# Return 1 if the URL is redirected to the SSO
|
# Return 1 if the URL is redirected to the SSO
|
||||||
|
|
|
@ -30,15 +30,23 @@ ynh_backup --src_path="$data_dir" --is_big
|
||||||
# SYSTEM CONFIGURATION
|
# SYSTEM CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
|
# Backup the PHP-FPM configuration
|
||||||
ynh_backup --src_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
|
ynh_backup --src_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
|
||||||
|
|
||||||
|
# Backup the nginx configuration
|
||||||
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
|
||||||
|
|
||||||
|
# Backup the logrotate configuration
|
||||||
ynh_backup --src_path="/etc/logrotate.d/$app"
|
ynh_backup --src_path="/etc/logrotate.d/$app"
|
||||||
|
|
||||||
|
# Backup the Fail2Ban config
|
||||||
ynh_backup --src_path="/etc/fail2ban/jail.d/$app.conf"
|
ynh_backup --src_path="/etc/fail2ban/jail.d/$app.conf"
|
||||||
ynh_backup --src_path="/etc/fail2ban/filter.d/$app.conf"
|
ynh_backup --src_path="/etc/fail2ban/filter.d/$app.conf"
|
||||||
|
|
||||||
|
#=================================================
|
||||||
|
# BACKUP VARIOUS FILES
|
||||||
|
#=================================================
|
||||||
|
|
||||||
ynh_backup --src_path="/etc/cron.d/$app"
|
ynh_backup --src_path="/etc/cron.d/$app"
|
||||||
|
|
||||||
ynh_backup --src_path="/var/log/$app"
|
ynh_backup --src_path="/var/log/$app"
|
||||||
|
|
|
@ -48,7 +48,7 @@ then
|
||||||
# Change hostname for activity notifications
|
# Change hostname for activity notifications
|
||||||
exec_occ config:system:set overwrite.cli.url --value="https://${new_domain}${new_path}"
|
exec_occ config:system:set overwrite.cli.url --value="https://${new_domain}${new_path}"
|
||||||
|
|
||||||
# Reload php fpm, necessary for force nextcloud to re-read config.php, cf opcache.revalidate_freq
|
# Reload PHP-FPM, necessary for force Nextcloud to re-read config.php, cf opcache.revalidate_freq
|
||||||
ynh_systemd_action --service_name=php${phpversion}-fpm --action=reload
|
ynh_systemd_action --service_name=php${phpversion}-fpm --action=reload
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue