From 3251079286e68987e5191aa6e01c1a47c74cc78d Mon Sep 17 00:00:00 2001 From: Jimmy Monin Date: Sun, 14 Jun 2020 15:23:05 +0200 Subject: [PATCH 01/17] Upgrade to upstream version 19.0.0 --- README.md | 2 +- README_fr.md | 2 +- conf/nginx.conf | 4 ++-- manifest.json | 2 +- scripts/_common.sh | 2 +- scripts/upgrade.d/upgrade.18.sh | 7 +++++++ scripts/upgrade.d/upgrade.last.sh | 6 +++--- 7 files changed, 16 insertions(+), 9 deletions(-) create mode 100644 scripts/upgrade.d/upgrade.18.sh diff --git a/README.md b/README.md index 3c48bca..dd96415 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ own data. A personal cloud which run on your own server. With Nextcloud you can synchronize your files over your devices. -**Shipped version:** 18.0.4 +**Shipped version:** 19.0.0 ## Screenshots diff --git a/README_fr.md b/README_fr.md index 1adf19e..c849567 100644 --- a/README_fr.md +++ b/README_fr.md @@ -14,7 +14,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour [Nextcloud](https://nextcloud.com) vous donne la liberté et le contrôle sur vos données. Un nuage personnel qui tourne sur votre serveur. Avec NextCloud vous pouvez synchroniser vos fichiers sur vos appareils. -**Version incluse :** 18.0.4 +**Version incluse :** 19.0.0 ## Captures d'écran diff --git a/conf/nginx.conf b/conf/nginx.conf index c4b73e1..6cfb6e6 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -76,7 +76,7 @@ location ^~ __PATH__/ { deny all; } - location ~ ^__PATH__/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|oc[ms]-provider/.+)\.php(/.*|)$ { + location ~ ^__PATH__/(?:index|remote|public|cron|core/ajax/update|status|ocs/v[12]|updater/.+|oc[ms]-provider/.+|.+\/richdocumentscode\/proxy)\.php(/.*|)$ { fastcgi_split_path_info ^(.+?\.php)(/.*|)$; set $path_info $fastcgi_path_info; try_files $fastcgi_script_name =404; @@ -135,7 +135,7 @@ location ^~ __PATH__/ { access_log off; } - location ~* \.(?:png|html|ttf|ico|jpg|jpeg|bcmap)$ { + location ~* \.(?:png|html|ttf|ico|jpg|jpeg|bcmap|mp4|webm)$ { try_files $uri __PATH__/index.php$request_uri; # Optional: Don't log access to other assets access_log off; diff --git a/manifest.json b/manifest.json index c3cc160..1daa850 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "Access & share your files, calendars, contacts, mail & more from any device, on your terms", "fr": "Consultez et partagez vos fichiers, agendas, carnets d'adresses, emails et bien plus depuis les appareils de votre choix, sous vos conditions" }, - "version": "18.0.4~ynh1", + "version": "19.0.0~ynh1", "url": "https://nextcloud.com", "license": "AGPL-3.0", "maintainer": { diff --git a/scripts/_common.sh b/scripts/_common.sh index 7b84705..5bf88c4 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -6,7 +6,7 @@ pkg_dependencies="imagemagick acl tar smbclient at" YNH_PHP_VERSION="7.3" -extra_pkg_dependencies="php${YNH_PHP_VERSION}-bz2 php${YNH_PHP_VERSION}-imap php${YNH_PHP_VERSION}-smbclient php${YNH_PHP_VERSION}-gmp php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-json php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-apcu php${YNH_PHP_VERSION}-redis php${YNH_PHP_VERSION}-ldap php${YNH_PHP_VERSION}-imagick php${YNH_PHP_VERSION}-zip php${YNH_PHP_VERSION}-mbstring php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-igbinary" +extra_pkg_dependencies="php${YNH_PHP_VERSION}-bz2 php${YNH_PHP_VERSION}-imap php${YNH_PHP_VERSION}-smbclient php${YNH_PHP_VERSION}-gmp php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-json php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-apcu php${YNH_PHP_VERSION}-redis php${YNH_PHP_VERSION}-ldap php${YNH_PHP_VERSION}-imagick php${YNH_PHP_VERSION}-zip php${YNH_PHP_VERSION}-mbstring php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-igbinary php${YNH_PHP_VERSION}-bcmath" #================================================= # EXPERIMENTAL HELPERS diff --git a/scripts/upgrade.d/upgrade.18.sh b/scripts/upgrade.d/upgrade.18.sh new file mode 100644 index 0000000..e43bb76 --- /dev/null +++ b/scripts/upgrade.d/upgrade.18.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +# Last available nextcloud version +next_version="19.0.0" + +# Nextcloud tarball checksum sha256 +nextcloud_source_sha256="d23d429657c5e3476d7e73af1eafc70e42a81cfe2ed65b20655a005724fe0aae" diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 6a77d34..0c5e33c 100755 --- a/scripts/upgrade.d/upgrade.last.sh +++ b/scripts/upgrade.d/upgrade.last.sh @@ -1,10 +1,10 @@ #!/bin/bash # Last available nextcloud version -next_version="18.0.4" +next_version="19.0.0" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="fad8e12632b352247ffc5ae181d4e414d732b9072caa0401774cfdb93a714329" +nextcloud_source_sha256="d23d429657c5e3476d7e73af1eafc70e42a81cfe2ed65b20655a005724fe0aae" # This function will only be executed upon applying the last upgrade referenced above last_upgrade_operations () { @@ -12,5 +12,5 @@ last_upgrade_operations () { cp -a ../sources/patches_last_version/* ../sources/patches # Execute post-upgrade operations later on - (cd /tmp ; at now + 10 minutes <<< "(cd $final_path ; sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-indices ; sudo -u $app php${YNH_PHP_VERSION} occ db:convert-filecache-bigint -n) > /tmp/${app}_maintenance.log") + (cd /tmp ; at now + 10 minutes <<< "(cd $final_path ; sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-indices ; sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-columns ; sudo -u $app php${YNH_PHP_VERSION} occ db:convert-filecache-bigint -n) > /tmp/${app}_maintenance.log") } From ad4ea9d6e77c026d2036c7c393c2603135aa56b3 Mon Sep 17 00:00:00 2001 From: Jimmy Monin Date: Sun, 14 Jun 2020 15:23:34 +0200 Subject: [PATCH 02/17] Fix upgrade for first major versions --- scripts/upgrade | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 5d832b6..8054652 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -247,17 +247,19 @@ then major_version=${last_version%%.*} current_major_version=${current_version%%.*} + # Load the value for this version + source upgrade.d/upgrade.$current_major_version.sh + # If the current version has the same major version than the next one, # then it's the last upgrade to do - if [ "$major_version" -eq "$current_major_version" ]; then + # We also cover the case where the last version is the first of the current major version series + # (e.g. 19.0.0 is the latest version) + if [[ ("$major_version" -eq "$current_major_version") || ( ("$major_version" -eq "$((current_major_version+1))") && ("$next_version" == "$last_version") ) ]]; then current_major_version=last # Execute the commands dedicated to the last upgrade last_upgrade_operations fi - # Load the value for this version - source upgrade.d/upgrade.$current_major_version.sh - ynh_print_info --message="Upgrade to nextcloud $next_version" # Create an app.src for this version of nextcloud From 5cc1c57ddd04ab6659690b0d72dc61f137bc7221 Mon Sep 17 00:00:00 2001 From: Kay0u Date: Wed, 8 Jul 2020 10:59:54 +0200 Subject: [PATCH 03/17] fix var name --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index bcaf40b..2b9a766 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -6,7 +6,7 @@ pkg_dependencies="imagemagick acl tar smbclient at" YNH_PHP_VERSION="7.3" -extra_pkg_dependencies="php${YNH_PHP_VERSION}-bz2 php${YNH_PHP_VERSION}-imap php${YNH_PHP_VERSION}-smbclient php${YNH_PHP_VERSION}-gmp php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-json php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-apcu php${YNH_PHP_VERSION}-redis php${YNH_PHP_VERSION}-ldap php${YNH_PHP_VERSION}-imagick php${YNH_PHP_VERSION}-zip php${YNH_PHP_VERSION}-mbstring php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-igbinary php${YNH_PHP_VERSION}-bcmath" +extra_php_dependencies="php${YNH_PHP_VERSION}-bz2 php${YNH_PHP_VERSION}-imap php${YNH_PHP_VERSION}-smbclient php${YNH_PHP_VERSION}-gmp php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-json php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-apcu php${YNH_PHP_VERSION}-redis php${YNH_PHP_VERSION}-ldap php${YNH_PHP_VERSION}-imagick php${YNH_PHP_VERSION}-zip php${YNH_PHP_VERSION}-mbstring php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-igbinary php${YNH_PHP_VERSION}-bcmath" #================================================= # EXPERIMENTAL HELPERS From 3bbb080e94aaac81d3364634c9e851320457634b Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 12 Aug 2020 20:44:55 +0200 Subject: [PATCH 04/17] upgrade to 19.0.1 --- README.md | 2 +- README_fr.md | 2 +- manifest.json | 2 +- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index a735d2c..418b450 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ own data. A personal cloud which runs on your own server. With Nextcloud you can synchronize your files over your devices. -**Shipped version:** 18.0.7 +**Shipped version:** 19.0.1 ## Screenshots diff --git a/README_fr.md b/README_fr.md index ada1a91..4b76836 100644 --- a/README_fr.md +++ b/README_fr.md @@ -14,7 +14,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour [Nextcloud](https://nextcloud.com) vous donne la liberté et le contrôle sur vos données. Un nuage personnel qui tourne sur votre serveur. Avec NextCloud vous pouvez synchroniser vos fichiers sur vos appareils. -**Version incluse :** 18.0.7 +**Version incluse :** 19.0.1 ## Captures d'écran diff --git a/manifest.json b/manifest.json index 31bbafd..7320cfd 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "Access & share your files, calendars, contacts, mail & more from any device, on your terms", "fr": "Consultez et partagez vos fichiers, agendas, carnets d'adresses, emails et bien plus depuis les appareils de votre choix, sous vos conditions" }, - "version": "18.0.7~ynh1", + "version": "19.0.1~ynh1", "url": "https://nextcloud.com", "license": "AGPL-3.0", "maintainer": { diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index c6cf27a..fecdbdd 100755 --- a/scripts/upgrade.d/upgrade.last.sh +++ b/scripts/upgrade.d/upgrade.last.sh @@ -1,10 +1,10 @@ #!/bin/bash # Last available nextcloud version -next_version="18.0.7" +next_version="19.0.1" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="4b2cc7475d925faf9ce6c655d290cbbee8c02a40aaf0628d3d41b7ccd8416a5e" +nextcloud_source_sha256="4ef311e00d939915d3a9714cd3a1ad436db9157e04620e4a88c2f427e5e65b2d" # This function will only be executed upon applying the last upgrade referenced above last_upgrade_operations () { From 03f2641bb95c4037df3cfaeba2e05094c2795d58 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 12 Aug 2020 20:46:51 +0200 Subject: [PATCH 05/17] Create upgrade.18.sh --- scripts/upgrade.d/upgrade.18.sh | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 scripts/upgrade.d/upgrade.18.sh diff --git a/scripts/upgrade.d/upgrade.18.sh b/scripts/upgrade.d/upgrade.18.sh new file mode 100644 index 0000000..e43bb76 --- /dev/null +++ b/scripts/upgrade.d/upgrade.18.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +# Last available nextcloud version +next_version="19.0.0" + +# Nextcloud tarball checksum sha256 +nextcloud_source_sha256="d23d429657c5e3476d7e73af1eafc70e42a81cfe2ed65b20655a005724fe0aae" From 41dee40b09dc69f71a0b200a7ecaeb1b0fb4d715 Mon Sep 17 00:00:00 2001 From: Kay0u Date: Fri, 14 Aug 2020 12:01:51 +0200 Subject: [PATCH 06/17] Add action add_multimedia_directories --- actions.toml | 9 ++++ scripts/actions/add_multimedia_directories | 58 ++++++++++++++++++++++ scripts/upgrade | 14 ------ 3 files changed, 67 insertions(+), 14 deletions(-) create mode 100755 scripts/actions/add_multimedia_directories diff --git a/actions.toml b/actions.toml index 38c52a8..fc6cb0f 100644 --- a/actions.toml +++ b/actions.toml @@ -6,3 +6,12 @@ command = "/bin/bash scripts/actions/disable_maintenance" # accepted_return_codes = [0, 1, 2, 3] # optional accepted_return_codes = [0] description = "Disable the maintenance mode of Nextcloud if you're stuck after an upgrade" + +[add_multimedia_directories] +name = "Add multimedia directories" +command = "/bin/bash scripts/actions/add_multimedia_directories" +# user = "root" # optional +# cwd = "/" # optional +# accepted_return_codes = [0, 1, 2, 3] # optional +accepted_return_codes = [0] +description = "Add the multimedia and shared multimedia directories again" diff --git a/scripts/actions/add_multimedia_directories b/scripts/actions/add_multimedia_directories new file mode 100755 index 0000000..2f34980 --- /dev/null +++ b/scripts/actions/add_multimedia_directories @@ -0,0 +1,58 @@ +#!/bin/bash + +#================================================= +# GENERIC STARTING +#================================================= +# IMPORT GENERIC HELPERS +#================================================= + +source scripts/_common.sh +source /usr/share/yunohost/helpers + +#================================================= +# RETRIEVE ARGUMENTS +#================================================= + +app=$YNH_APP_INSTANCE_NAME + +#================================================= +# CHECK IF ARGUMENTS ARE CORRECT +#================================================= + +#================================================= +# DEFINE FUNCTION +#================================================= + +# Define a function to add an external storage +# Create the external storage for the given folders and enable sharing +create_external_storage() { +local datadir="$1" +local mount_name="$2" +local mount_id=`exec_occ files_external:create --output=json \ + "$mount_name" 'local' 'null::null' -c "datadir=$datadir" || true` +! [[ $mount_id =~ ^[0-9]+$ ]] \ + && ynh_print_warn --message="Unable to create external storage" \ + || exec_occ files_external:option "$mount_id" enable_sharing true +} + +#================================================= +# SPECIFIC ACTION +#================================================= +# YUNOHOST MULTIMEDIA INTEGRATION +#================================================= +ynh_script_progression --message="Updating multimedia directories..." --weight=6 + +# Build YunoHost multimedia directories +ynh_multimedia_build_main_dir +# Mount the user directory in Nextcloud +exec_occ app:enable files_external +create_external_storage "/home/yunohost.multimedia/\$user" "Multimedia" +create_external_storage "/home/yunohost.multimedia/share" "Shared multimedia" +# Allow nextcloud to write into these directories +ynh_multimedia_addaccess $app + +#================================================= +# END OF SCRIPT +#================================================= + +ynh_script_progression --message="Execution completed" --last diff --git a/scripts/upgrade b/scripts/upgrade index 7800a53..b1accbe 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -401,20 +401,6 @@ exec_occ background:cron # Set system group in hooks ynh_replace_string --match_string="__GROUP__" --replace_string="$app" --target_file=../hooks/post_user_create -#================================================= -# YUNOHOST MULTIMEDIA INTEGRATION -#================================================= -ynh_script_progression --message="Updating multimedia directories..." --weight=6 - -# Build YunoHost multimedia directories -ynh_multimedia_build_main_dir -# Mount the user directory in Nextcloud -exec_occ app:enable files_external -create_external_storage "/home/yunohost.multimedia/\$user" "Multimedia" -create_external_storage "/home/yunohost.multimedia/share" "Shared multimedia" -# Allow nextcloud to write into these directories -ynh_multimedia_addaccess $app - #================================================= # GENERIC FINALIZATION #================================================= From 38b66a8530010f83a42cce22ce74066f5c693a63 Mon Sep 17 00:00:00 2001 From: Kay0u Date: Fri, 14 Aug 2020 13:11:14 +0200 Subject: [PATCH 07/17] fix action --- scripts/actions/add_multimedia_directories | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/actions/add_multimedia_directories b/scripts/actions/add_multimedia_directories index 2f34980..4dc7881 100755 --- a/scripts/actions/add_multimedia_directories +++ b/scripts/actions/add_multimedia_directories @@ -15,6 +15,8 @@ source /usr/share/yunohost/helpers app=$YNH_APP_INSTANCE_NAME +final_path=$(ynh_app_setting_get --app=$app --key=final_path) + #================================================= # CHECK IF ARGUMENTS ARE CORRECT #================================================= @@ -23,6 +25,12 @@ app=$YNH_APP_INSTANCE_NAME # DEFINE FUNCTION #================================================= +# Define a function to execute commands with `occ` +exec_occ() { + (cd "$final_path" && exec_as "$app" \ + php$YNH_PHP_VERSION occ --no-interaction --no-ansi "$@") +} + # Define a function to add an external storage # Create the external storage for the given folders and enable sharing create_external_storage() { From 74f3112feaa4ca0778d2532000d04f77eca9c455 Mon Sep 17 00:00:00 2001 From: Kay0u Date: Mon, 17 Aug 2020 17:07:34 +0200 Subject: [PATCH 08/17] fix upgrade --- scripts/install | 7 ++++++- scripts/upgrade | 27 ++++++++++++++++----------- scripts/upgrade.d/upgrade.last.sh | 9 --------- 3 files changed, 22 insertions(+), 21 deletions(-) diff --git a/scripts/install b/scripts/install index db96c16..6eb8471 100755 --- a/scripts/install +++ b/scripts/install @@ -273,7 +273,12 @@ exec_occ background:cron # POST-INSTALL MAINTENANCE #================================================= -(cd /tmp ; at now + 10 minutes <<< "(cd $final_path ; sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-indices ; sudo -u $app php${YNH_PHP_VERSION} occ db:convert-filecache-bigint -n) > /tmp/${app}_maintenance.log") +( + cd $final_path + sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-indices + sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-columns + sudo -u $app php${YNH_PHP_VERSION} occ db:convert-filecache-bigint -n +) #================================================= # CONFIGURE THE HOOK FILE FOR USER CREATE diff --git a/scripts/upgrade b/scripts/upgrade index a6a467b..b793386 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -229,6 +229,8 @@ then source upgrade.d/upgrade.last.sh last_version=$next_version + last_major_version=${last_version%%.*} + # Set write access for the following commands chown -R $app: "$final_path" "$datadir" @@ -240,23 +242,19 @@ then do # The major version is the first part of the version number - # major_version=${next_version%%.*} - major_version=${last_version%%.*} current_major_version=${current_version%%.*} - # Load the value for this version - source upgrade.d/upgrade.$current_major_version.sh - # If the current version has the same major version than the next one, # then it's the last upgrade to do - # We also cover the case where the last version is the first of the current major version series - # (e.g. 19.0.0 is the latest version) - if [[ ("$major_version" -eq "$current_major_version") || ( ("$major_version" -eq "$((current_major_version+1))") && ("$next_version" == "$last_version") ) ]]; then - current_major_version=last - # Execute the commands dedicated to the last upgrade - last_upgrade_operations + if [ "$last_major_version" -eq "$current_major_version" ]; then + current_major_version=last + # Enable YunoHost patches on Nextcloud sources + cp -a ../sources/patches_last_version/* ../sources/patches fi + # Load the value for this version + source upgrade.d/upgrade.$current_major_version.sh + ynh_print_info --message="Upgrade to nextcloud $next_version" # Create an app.src for this version of nextcloud @@ -311,6 +309,13 @@ then exec_occ -V done + ( + cd $final_path + sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-indices + sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-columns + sudo -u $app php${YNH_PHP_VERSION} occ db:convert-filecache-bigint -n + ) + #================================================= # CONFIGURE NEXTCLOUD #================================================= diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 312ae98..2e73d3d 100755 --- a/scripts/upgrade.d/upgrade.last.sh +++ b/scripts/upgrade.d/upgrade.last.sh @@ -5,12 +5,3 @@ next_version="19.0.1" # Nextcloud tarball checksum sha256 nextcloud_source_sha256="4ef311e00d939915d3a9714cd3a1ad436db9157e04620e4a88c2f427e5e65b2d" - -# This function will only be executed upon applying the last upgrade referenced above -last_upgrade_operations () { - # Patch nextcloud files only for the last version - cp -a ../sources/patches_last_version/* ../sources/patches - - # Execute post-upgrade operations later on - (cd /tmp ; at now + 10 minutes <<< "(cd $final_path ; sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-indices ; sudo -u $app php${YNH_PHP_VERSION} occ db:add-missing-columns ; sudo -u $app php${YNH_PHP_VERSION} occ db:convert-filecache-bigint -n) > /tmp/${app}_maintenance.log") -} From fa00d46c04f8d78a1af0de23a76650bbf39e4ad2 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 26 Aug 2020 23:24:09 +0200 Subject: [PATCH 09/17] upgrade to v.19.0.2 --- README.md | 2 +- README_fr.md | 2 +- manifest.json | 2 +- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 418b450..d4edc7b 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ own data. A personal cloud which runs on your own server. With Nextcloud you can synchronize your files over your devices. -**Shipped version:** 19.0.1 +**Shipped version:** 19.0.2 ## Screenshots diff --git a/README_fr.md b/README_fr.md index 4b76836..945d76c 100644 --- a/README_fr.md +++ b/README_fr.md @@ -14,7 +14,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour [Nextcloud](https://nextcloud.com) vous donne la liberté et le contrôle sur vos données. Un nuage personnel qui tourne sur votre serveur. Avec NextCloud vous pouvez synchroniser vos fichiers sur vos appareils. -**Version incluse :** 19.0.1 +**Version incluse :** 19.0.2 ## Captures d'écran diff --git a/manifest.json b/manifest.json index 7320cfd..d9f1c08 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "Access & share your files, calendars, contacts, mail & more from any device, on your terms", "fr": "Consultez et partagez vos fichiers, agendas, carnets d'adresses, emails et bien plus depuis les appareils de votre choix, sous vos conditions" }, - "version": "19.0.1~ynh1", + "version": "19.0.2~ynh1", "url": "https://nextcloud.com", "license": "AGPL-3.0", "maintainer": { diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 2e73d3d..cf10d7c 100755 --- a/scripts/upgrade.d/upgrade.last.sh +++ b/scripts/upgrade.d/upgrade.last.sh @@ -1,7 +1,7 @@ #!/bin/bash # Last available nextcloud version -next_version="19.0.1" +next_version="19.0.2" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="4ef311e00d939915d3a9714cd3a1ad436db9157e04620e4a88c2f427e5e65b2d" +nextcloud_source_sha256="e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" From 1591235c2e6e11ea28fa8bfae4b6f4c18ea633fc Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 26 Aug 2020 23:57:53 +0200 Subject: [PATCH 10/17] Update upgrade.last.sh --- scripts/upgrade.d/upgrade.last.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index cf10d7c..0d733b9 100755 --- a/scripts/upgrade.d/upgrade.last.sh +++ b/scripts/upgrade.d/upgrade.last.sh @@ -4,4 +4,4 @@ next_version="19.0.2" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" +nextcloud_source_sha256="8152f385fdb0645114e0043aaf07b0de046fbaf205fa6d6bf530d22db86c66a5" From caf092aa0c0d98da60b78317e879baf885f77cdf Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 2 Sep 2020 08:56:33 +0200 Subject: [PATCH 11/17] Update doc version URL --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d4edc7b..9a3dd85 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,7 @@ you can synchronize your files over your devices. ## Documentation - * Official documentation: https://docs.nextcloud.com/server/18/user_manual/ + * Official documentation: https://docs.nextcloud.com/server/19/user_manual/ * YunoHost documentation: https://github.com/YunoHost/doc/blob/master/app_nextcloud.md ## Configuration diff --git a/README_fr.md b/README_fr.md index 945d76c..9741bb9 100644 --- a/README_fr.md +++ b/README_fr.md @@ -27,7 +27,7 @@ Avec NextCloud vous pouvez synchroniser vos fichiers sur vos appareils. ## Documentation - * Documentation officielle : https://docs.nextcloud.com/server/18/user_manual/ + * Documentation officielle : https://docs.nextcloud.com/server/19/user_manual/ * Documentation YunoHost : https://github.com/YunoHost/doc/blob/master/app_nextcloud_fr.md ## Configuration From 895f9951b2ad8c7e17ea2d67ba572d0dca41443c Mon Sep 17 00:00:00 2001 From: Kay0u Date: Mon, 7 Sep 2020 17:52:07 +0200 Subject: [PATCH 12/17] fix nginx conf --- conf/nginx.conf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index af8ce3e..0cf3732 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -78,8 +78,8 @@ location ^~ __PATH__/ { deny all; } - location ~ ^__PATH__/(?:index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+|.+\/richdocumentscode\/proxy)\.php(\/.*|)$ { - fastcgi_split_path_info ^(.+?\.php)(/.*|)$; + location ~ ^__PATH__/(?:index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+|.+\/richdocumentscode\/proxy)\.php(?:$|\/) { + fastcgi_split_path_info ^(.+?\.php)(\/.*|)$; set $path_info $fastcgi_path_info; try_files $fastcgi_script_name =404; include fastcgi_params; @@ -139,7 +139,7 @@ location ^~ __PATH__/ { access_log off; } - location ~* \.(?:png|html|ttf|ico|jpg|jpeg|bcmap|mp4|webm)$ { + location ~ ^__PATH__/.+[^\/]\.(?:png|html|ttf|ico|jpg|jpeg|bcmap|mp4|webm)$ { try_files $uri __PATH__/index.php$request_uri; # Optional: Don't log access to other assets access_log off; From 70207544ab195121d041c63e24192082abc939c5 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 9 Sep 2020 22:28:49 +0200 Subject: [PATCH 13/17] Upgrade to 19.0.3 --- README.md | 2 +- README_fr.md | 2 +- manifest.json | 2 +- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 9a3dd85..b4b939b 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ own data. A personal cloud which runs on your own server. With Nextcloud you can synchronize your files over your devices. -**Shipped version:** 19.0.2 +**Shipped version:** 19.0.3 ## Screenshots diff --git a/README_fr.md b/README_fr.md index 9741bb9..404ef69 100644 --- a/README_fr.md +++ b/README_fr.md @@ -14,7 +14,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour [Nextcloud](https://nextcloud.com) vous donne la liberté et le contrôle sur vos données. Un nuage personnel qui tourne sur votre serveur. Avec NextCloud vous pouvez synchroniser vos fichiers sur vos appareils. -**Version incluse :** 19.0.2 +**Version incluse :** 19.0.3 ## Captures d'écran diff --git a/manifest.json b/manifest.json index d9f1c08..75aa560 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "Access & share your files, calendars, contacts, mail & more from any device, on your terms", "fr": "Consultez et partagez vos fichiers, agendas, carnets d'adresses, emails et bien plus depuis les appareils de votre choix, sous vos conditions" }, - "version": "19.0.2~ynh1", + "version": "19.0.3~ynh1", "url": "https://nextcloud.com", "license": "AGPL-3.0", "maintainer": { diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 0d733b9..569c56e 100755 --- a/scripts/upgrade.d/upgrade.last.sh +++ b/scripts/upgrade.d/upgrade.last.sh @@ -1,7 +1,7 @@ #!/bin/bash # Last available nextcloud version -next_version="19.0.2" +next_version="19.0.3" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="8152f385fdb0645114e0043aaf07b0de046fbaf205fa6d6bf530d22db86c66a5" +nextcloud_source_sha256="fc503985e8aa4ed795d882e35679e0e1b7670181768e7820307222d8b4658969" From 1ff40ff3d1b2ddc3dd9c5238a852d30c95fa98f7 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Wed, 9 Sep 2020 23:11:58 +0200 Subject: [PATCH 14/17] Update check_process --- check_process | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/check_process b/check_process index afc9dec..2d53163 100644 --- a/check_process +++ b/check_process @@ -12,7 +12,7 @@ setup_private=0 setup_public=0 upgrade=1 - upgrade=1 from_commit=9c57c2f78f3da979d587d708eb9379ffaa41bcfa + upgrade=1 from_commit=af36640ee5a5f1fab69651d638d23ebe47198152 backup_restore=1 multi_instance=1 incorrect_path=1 @@ -24,6 +24,6 @@ Email= Notification=none ;;; Upgrade options - ; commit=9c57c2f78f3da979d587d708eb9379ffaa41bcfa - name=Do not use too much process for php (#247) + ; commit=af36640ee5a5f1fab69651d638d23ebe47198152 + name=Merge pull request #320 enh-upgrade-18.0.7 manifest_arg=domain=DOMAIN&path=PATH&admin=USER&user_home=1& From 998215834e44fb0a4dc2ddd5e573c97dd10fb80e Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Thu, 10 Sep 2020 08:25:25 +0200 Subject: [PATCH 15/17] Update check_process --- check_process | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/check_process b/check_process index 2d53163..0ee0bab 100644 --- a/check_process +++ b/check_process @@ -12,7 +12,7 @@ setup_private=0 setup_public=0 upgrade=1 - upgrade=1 from_commit=af36640ee5a5f1fab69651d638d23ebe47198152 + upgrade=1 from_commit=c864e086625363d91dde6ba78a652011a991a027 backup_restore=1 multi_instance=1 incorrect_path=1 @@ -24,6 +24,6 @@ Email= Notification=none ;;; Upgrade options - ; commit=af36640ee5a5f1fab69651d638d23ebe47198152 - name=Merge pull request #320 enh-upgrade-18.0.7 + ; commit=c864e086625363d91dde6ba78a652011a991a027 + name=[fix] php7.2-mcrypt doesn't exist (#253) manifest_arg=domain=DOMAIN&path=PATH&admin=USER&user_home=1& From a31385b6b64920e1df6d2176da2898f02f1f88e2 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 13 Sep 2020 12:32:26 +0200 Subject: [PATCH 16/17] Update backup --- scripts/backup | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/scripts/backup b/scripts/backup index 68ae4ee..bb92dda 100755 --- a/scripts/backup +++ b/scripts/backup @@ -19,7 +19,7 @@ ynh_abort_if_errors #================================================= # LOAD SETTINGS #================================================= -ynh_script_progression --message="Loading installation settings..." +ynh_print_info --message="Loading installation settings..." app=$YNH_APP_INSTANCE_NAME @@ -28,32 +28,32 @@ domain=$(ynh_app_setting_get --app=$app --key=domain) db_name=$(ynh_app_setting_get --app=$app --key=db_name) #================================================= -# STANDARD BACKUP STEPS +# DECLARE DATA AND CONF FILES TO BACKUP +#================================================= +ynh_print_info --message="Declaring files to be backed up..." + #================================================= # BACKUP THE APP MAIN DIR #================================================= -ynh_script_progression --message="Backing up the main app directory..." ynh_backup --src_path="$final_path" #================================================= # BACKUP THE NGINX CONFIGURATION #================================================= -ynh_script_progression --message="Backing up nginx web server configuration..." ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf" #================================================= # BACKUP THE PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Backing up php-fpm configuration..." ynh_backup --src_path="/etc/php/$YNH_PHP_VERSION/fpm/pool.d/$app.conf" #================================================= # BACKUP THE MYSQL DATABASE #================================================= -ynh_script_progression --message="Backing up the MySQL database..." --weight=2 +ynh_print_info --message="Backing up the MySQL database..." ynh_mysql_dump_db --database="$db_name" > db.sql @@ -62,14 +62,12 @@ ynh_mysql_dump_db --database="$db_name" > db.sql #================================================= # BACKUP LOGROTATE #================================================= -ynh_script_progression --message="Backing up logrotate configuration..." ynh_backup "/etc/logrotate.d/$app" #================================================= # BACKUP FAIL2BAN CONFIGURATION #================================================= -ynh_script_progression --message="Backing up fail2ban configuration..." ynh_backup --src_path="/etc/fail2ban/jail.d/$app.conf" ynh_backup --src_path="/etc/fail2ban/filter.d/$app.conf" @@ -83,7 +81,7 @@ ynh_backup --src_path="/etc/cron.d/$app" #================================================= # BACKUP THE DATA DIRECTORY #================================================= -ynh_script_progression --message="Backing up data directory..." +ynh_print_info --message="Backing up data directory..." ynh_backup --src_path="/home/yunohost.app/${app}/data" --is_big @@ -91,4 +89,4 @@ ynh_backup --src_path="/home/yunohost.app/${app}/data" --is_big # END OF SCRIPT #================================================= -ynh_script_progression --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)." --last +ynh_print_info --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)." From 8f7fb69e839e5b948591823750ce5e81162bfeb8 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 13 Sep 2020 12:41:43 +0200 Subject: [PATCH 17/17] Minor typos --- scripts/change_url | 14 +++++++------- scripts/install | 18 +++++++++--------- scripts/remove | 12 ++++++------ scripts/restore | 6 +++--- scripts/upgrade | 22 +++++++++++----------- 5 files changed, 36 insertions(+), 36 deletions(-) diff --git a/scripts/change_url b/scripts/change_url index c9f7a9c..2aa5f36 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -50,23 +50,23 @@ fi #================================================= # MODIFY URL IN NGINX CONF #================================================= -ynh_script_progression --message="Updating nginx web server configuration..." --weight=2 +ynh_script_progression --message="Updating NGINX web server configuration..." --weight=2 nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf -# Change the path in the nginx config file +# Change the path in the NGINX config file if [ $change_path -eq 1 ] then - # Make a backup of the original nginx config file if modified + # Make a backup of the original NGINX config file if modified ynh_backup_if_checksum_is_different --file="$nginx_conf_path" - # Set global variables for nginx helper + # Set global variables for NGINX helper domain="$old_domain" path_url="$new_path" - # Create a dedicated nginx config + # Create a dedicated NGINX config ynh_add_nginx_config YNH_PHP_VERSION fi -# Change the domain for nginx +# Change the domain for NGINX if [ $change_domain -eq 1 ] then # Delete file checksum for the old conf file location @@ -114,7 +114,7 @@ fi #================================================= # RELOAD NGINX #================================================= -ynh_script_progression --message="Reloading nginx web server..." +ynh_script_progression --message="Reloading NGINX web server..." ynh_systemd_action --service_name=nginx --action=reload diff --git a/scripts/install b/scripts/install index 6eb8471..cfe9d5b 100755 --- a/scripts/install +++ b/scripts/install @@ -87,7 +87,7 @@ ynh_setup_source --dest_dir="$final_path" #================================================= # NGINX CONFIGURATION #================================================= -ynh_script_progression --message="Configuring nginx web server..." --weight=2 +ynh_script_progression --message="Configuring NGINX web server..." --weight=2 # Check if .well-known is available for this domain if is_url_handled --domain="$domain" --path="/.well-known/caldav" || is_url_handled --domain="$domain" --path="/.well-known/carddav" @@ -98,7 +98,7 @@ then sed --in-place --regexp-extended '/^location = \/\.well\-known\/(caldav|carddav) \{/,/\}/d' "../conf/nginx.conf" fi -# Create a dedicated nginx config +# Create a dedicated NGINX config ynh_add_nginx_config YNH_PHP_VERSION #================================================= @@ -112,7 +112,7 @@ ynh_system_user_create --username=$app #================================================= # PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Configuring php-fpm..." --weight=50 +ynh_script_progression --message="Configuring PHP-FPM..." --weight=50 # Create a dedicated php-fpm config ynh_add_fpm_config --usage=medium --footprint=high --phpversion=$YNH_PHP_VERSION --package="$extra_php_dependencies" @@ -131,7 +131,7 @@ mkdir -p "$datadir" #================================================= # INSTALL NEXTCLOUD #================================================= -ynh_script_progression --message="Installing nextcloud..." --weight=30 +ynh_script_progression --message="Installing Nextcloud..." --weight=30 # Define a function to execute commands with `occ` exec_occ() { @@ -153,7 +153,7 @@ exec_occ maintenance:install \ #================================================= # CONFIGURE NEXTCLOUD #================================================= -ynh_script_progression --message="Configuring nextcloud..." --weight=8 +ynh_script_progression --message="Configuring Nextcloud..." --weight=8 # Ensure that UpdateNotification app is disabled exec_occ app:disable updatenotification @@ -162,7 +162,7 @@ exec_occ app:disable updatenotification exec_occ app:enable user_ldap exec_occ ldap:create-empty-config -# Load the installation config file in nextcloud +# Load the installation config file in Nextcloud nc_conf="$final_path/config_install.json" cp ../conf/config_install.json "$nc_conf" @@ -327,9 +327,9 @@ ynh_use_logrotate --logfile="$datadir/nextcloud.log" #================================================= # SETUP FAIL2BAN #================================================= -ynh_script_progression --message="Configuring fail2ban..." --weight=8 +ynh_script_progression --message="Configuring Fail2ban..." --weight=8 -# Create a dedicated fail2ban config +# Create a dedicated Fail2ban config ynh_add_fail2ban_config --logpath="/home/yunohost.app/$app/data/nextcloud.log" --failregex="^.*Login failed: '.*' \(Remote IP: ''.*$" --max_retry=5 #================================================= @@ -344,7 +344,7 @@ ynh_app_setting_set --app=$app --key=skipped_regex \ #================================================= # RELOAD NGINX #================================================= -ynh_script_progression --message="Reloading nginx web server..." +ynh_script_progression --message="Reloading NGINX web server..." ynh_systemd_action --service_name=nginx --action=reload diff --git a/scripts/remove b/scripts/remove index 9ea5c15..ebf87d2 100755 --- a/scripts/remove +++ b/scripts/remove @@ -49,17 +49,17 @@ ynh_secure_remove --file="$final_path" #================================================= # REMOVE NGINX CONFIGURATION #================================================= -ynh_script_progression --message="Removing nginx web server configuration..." +ynh_script_progression --message="Removing NGINX web server configuration..." -# Remove the dedicated nginx config +# Remove the dedicated NGINX config ynh_remove_nginx_config #================================================= # REMOVE PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Removing php-fpm configuration..." --weight=2 +ynh_script_progression --message="Removing PHP-FPM configuration..." --weight=2 -# Remove the dedicated php-fpm config +# Remove the dedicated PHP-FPM config ynh_remove_fpm_config #================================================= @@ -73,9 +73,9 @@ ynh_remove_logrotate #================================================= # REMOVE FAIL2BAN CONFIGURATION #================================================= -ynh_script_progression --message="Removing fail2ban configuration..." --weight=8 +ynh_script_progression --message="Removing Fail2ban configuration..." --weight=8 -# Remove the dedicated fail2ban config +# Remove the dedicated Fail2ban config ynh_remove_fail2ban_config #================================================= diff --git a/scripts/restore b/scripts/restore index 8c49cad..daa51e9 100755 --- a/scripts/restore +++ b/scripts/restore @@ -95,7 +95,7 @@ ynh_install_app_dependencies $pkg_dependencies #================================================= # RESTORE THE PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Reconfiguring php-fpm..." --weight=50 +ynh_script_progression --message="Reconfiguring PHP-FPM..." --weight=50 # Restore the file first, so it can have a backup if different ynh_restore_file --origin_path="/etc/php/$YNH_PHP_VERSION/fpm/pool.d/$app.conf" @@ -156,7 +156,7 @@ ynh_multimedia_addaccess $app #================================================= # RESTORE THE FAIL2BAN CONFIGURATION #================================================= -ynh_script_progression --message="Restoring the fail2ban configuration..." --weight=7 +ynh_script_progression --message="Restoring the Fail2ban configuration..." --weight=7 ynh_restore_file --origin_path="/etc/fail2ban/jail.d/$app.conf" ynh_restore_file --origin_path="/etc/fail2ban/filter.d/$app.conf" @@ -175,7 +175,7 @@ ynh_systemd_action --action=restart --service_name=fail2ban #================================================= # RELOAD NGINX #================================================= -ynh_script_progression --message="Reloading nginx web server..." +ynh_script_progression --message="Reloading NGINX web server..." ynh_systemd_action --service_name=nginx --action=reload diff --git a/scripts/upgrade b/scripts/upgrade index b793386..6c76b8f 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -143,7 +143,7 @@ ynh_install_app_dependencies $pkg_dependencies #================================================= # NGINX CONFIGURATION #================================================= -ynh_script_progression --message="Upgrading nginx web server configuration..." --weight=2 +ynh_script_progression --message="Upgrading NGINX web server configuration..." --weight=2 ynh_backup_if_checksum_is_different --file="/etc/nginx/conf.d/$domain.d/$app.conf" @@ -177,7 +177,7 @@ ynh_system_user_create --username=$app #================================================= # PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Upgrading php-fpm configuration..." --weight=2 +ynh_script_progression --message="Upgrading PHP-FPM configuration..." --weight=2 # Recreate a dedicated php-fpm config ynh_add_fpm_config --phpversion="$YNH_PHP_VERSION" --usage=$fpm_usage --footprint=$fpm_footprint --package="$extra_php_dependencies" @@ -223,7 +223,7 @@ datadir="/home/yunohost.app/$app/data" if [ "$upgrade_type" == "UPGRADE_APP" ] then - ynh_script_progression --message="Upgrading nextcloud..." --weight=3 + ynh_script_progression --message="Upgrading Nextcloud..." --weight=3 # Load the last available version source upgrade.d/upgrade.last.sh @@ -234,7 +234,7 @@ then # Set write access for the following commands chown -R $app: "$final_path" "$datadir" - # Print the current version number of nextcloud + # Print the current version number of Nextcloud exec_occ -V # While the current version is not the last version, do an upgrade @@ -257,7 +257,7 @@ then ynh_print_info --message="Upgrade to nextcloud $next_version" - # Create an app.src for this version of nextcloud + # Create an app.src for this version of Nextcloud cp ../conf/app.src.default ../conf/app.src ynh_replace_string --match_string="__VERSION__" --replace_string="$next_version" --target_file="../conf/app.src" ynh_replace_string --match_string="__SHA256_SUM__" --replace_string="$nextcloud_source_sha256" --target_file="../conf/app.src" @@ -274,7 +274,7 @@ then # Backup the config file in the temp dir cp -a "$final_path/config/config.php" "$tmpdir/config/config.php" - # Backup 3rd party applications from the current nextcloud + # Backup 3rd party applications from the current Nextcloud # But do not overwrite if there is any upgrade # (apps directory already exists in Nextcloud archive) ( @@ -319,7 +319,7 @@ then #================================================= # CONFIGURE NEXTCLOUD #================================================= - ynh_script_progression --message="Reconfiguring nextcloud..." --weight=9 + ynh_script_progression --message="Reconfiguring Nextcloud..." --weight=9 # Verify the checksum and backup the file if it's different ynh_backup_if_checksum_is_different --file="$final_path/config/config.php" @@ -445,9 +445,9 @@ ynh_use_logrotate --non-append #================================================= # SETUP FAIL2BAN #================================================= -ynh_script_progression --message="Reconfiguring fail2ban..." --weight=7 +ynh_script_progression --message="Reconfiguring Fail2ban..." --weight=7 -# Create a dedicated fail2ban config +# Create a dedicated Fail2ban config ynh_add_fail2ban_config --logpath="/home/yunohost.app/$app/data/nextcloud.log" --failregex="^.*Login failed: '.*' \(Remote IP: ''.*$" --max_retry=5 #================================================= @@ -464,7 +464,7 @@ ynh_app_setting_set --app=$app --key=skipped_regex \ #================================================= # RELOAD NGINX #================================================= -ynh_script_progression --message="Reloading nginx web server..." +ynh_script_progression --message="Reloading NGINX web server..." ynh_systemd_action --service_name=nginx --action=reload @@ -474,7 +474,7 @@ ynh_systemd_action --service_name=nginx --action=reload if [ $migration_process -eq 1 ] then - ynh_print_info --message="ownCloud has been successfully migrated to Nextcloud! \ + ynh_print_info --message="OwnCloud has been successfully migrated to Nextcloud! \ A last scheduled operation will run in a couple of minutes to finish the \ migration in YunoHost side. Do not proceed any application operation while \ you don't see Nextcloud as installed."