From 66cdfff98fe9afe4c15eed1aa051c8c0d51fcb6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 10:14:05 +0200 Subject: [PATCH 001/127] Update backup --- scripts/backup | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/scripts/backup b/scripts/backup index fc09803..6a6f860 100755 --- a/scripts/backup +++ b/scripts/backup @@ -39,13 +39,6 @@ ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf" ynh_backup --src_path="/etc/php/$phpversion/fpm/pool.d/$app.conf" -#================================================= -# BACKUP THE MYSQL DATABASE -#================================================= -ynh_print_info --message="Backing up the MySQL database..." - -ynh_mysql_dump_db --database="$db_name" --default_character_set="utf8mb4" > db.sql - #================================================= # SPECIFIC BACKUP #================================================= @@ -68,11 +61,11 @@ ynh_backup --src_path="/etc/fail2ban/filter.d/$app.conf" ynh_backup --src_path="/etc/cron.d/$app" #================================================= -# BACKUP THE MYSQL DATABASE +# BACKUP THE POSTGRESQL DATABASE #================================================= -ynh_print_info --message="Backing up the MySQL database..." +ynh_print_info --message="Backing up the PostgreSQL database..." -ynh_mysql_dump_db --database="$db_name" > db.sql +ynh_psql_dump_db --database="$db_name" > db.sql #================================================= # END OF SCRIPT From 5d384066ec2ea666030811fc7e1a9716bfa59a25 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 10:25:12 +0200 Subject: [PATCH 002/127] fix --- manifest.toml | 4 ++-- scripts/_ynh_mysql_dump_db.sh | 37 ----------------------------------- scripts/backup | 1 - scripts/install | 20 ++++++------------- scripts/restore | 6 +++--- scripts/upgrade | 2 +- 6 files changed, 12 insertions(+), 58 deletions(-) delete mode 100644 scripts/_ynh_mysql_dump_db.sh diff --git a/manifest.toml b/manifest.toml index dafd7e5..32b295b 100644 --- a/manifest.toml +++ b/manifest.toml @@ -69,8 +69,8 @@ ram.runtime = "512M" api.allowed = ["visitors", "all_users"] [resources.apt] - packages = "mariadb-server, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.2-fpm, php8.2-bz2, php8.2-imap, php8.2-gmp, php8.2-gd, php8.2-intl, php8.2-curl, php8.2-apcu, php8.2-redis, php8.2-ldap, php8.2-imagick, php8.2-zip, php8.2-mbstring, php8.2-xml, php8.2-mysql, php8.2-igbinary, php8.2-bcmath" + packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.2-pgsql, php8.2-fpm, php8.2-bz2, php8.2-imap, php8.2-gmp, php8.2-gd, php8.2-intl, php8.2-curl, php8.2-apcu, php8.2-redis, php8.2-ldap, php8.2-imagick, php8.2-zip, php8.2-mbstring, php8.2-xml, php8.2-mysql, php8.2-igbinary, php8.2-bcmath" [resources.database] - type = "mysql" + type = "postgresql" \ No newline at end of file diff --git a/scripts/_ynh_mysql_dump_db.sh b/scripts/_ynh_mysql_dump_db.sh deleted file mode 100644 index 3b922bb..0000000 --- a/scripts/_ynh_mysql_dump_db.sh +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/bash - -# Dump a database -# -# example: ynh_mysql_dump_db --database=roundcube --default_character_set="utf8mb4" > ./dump.sql -# -# usage: ynh_mysql_dump_db --database=database -# | arg: -d, --database= - the database name to dump -# | arg: -c, --default_character_set= - the charset to use -# | ret: the mysqldump output -# -# Requires YunoHost version 2.2.4 or higher. -ynh_mysql_dump_db() { - # Declare an array to define the options of this helper. - local legacy_args=dc - local -A args_array=( [d]=database= [c]=default_character_set= ) - local database - local default_character_set - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - default_character_set="${default_character_set:-}" - MYSQL_ROOT_PWD_FILE=/etc/yunohost/mysql - - if [ -n "$default_character_set" ] - then - default_character_set="--default-character-set=$default_character_set" - else - # By default, default character set is "latin1" - default_character_set="--default-character-set=latin1" - fi - - if [ -f "$MYSQL_ROOT_PWD_FILE" ]; then - mysqldump --user="root" --password="$(cat $MYSQL_ROOT_PWD_FILE)" --single-transaction --skip-dump-date "$default_character_set" "$database" - else - mysqldump --single-transaction --skip-dump-date "$default_character_set" "$database" - fi -} \ No newline at end of file diff --git a/scripts/backup b/scripts/backup index 6a6f860..db1050b 100755 --- a/scripts/backup +++ b/scripts/backup @@ -8,7 +8,6 @@ source ../settings/scripts/_common.sh source /usr/share/yunohost/helpers -source ../settings/scripts/_ynh_mysql_dump_db.sh #================================================= # DECLARE DATA AND CONF FILES TO BACKUP diff --git a/scripts/install b/scripts/install index ccfde36..b453dd0 100755 --- a/scripts/install +++ b/scripts/install @@ -28,14 +28,6 @@ ynh_app_setting_set --app=$app --key=fpm_footprint --value=$fpm_footprint ynh_app_setting_set --app=$app --key=fpm_free_footprint --value=$fpm_free_footprint ynh_app_setting_set --app=$app --key=fpm_usage --value=$fpm_usage -#================================================= -# CREATE A MYSQL DATABASE -#================================================= -ynh_script_progression --message="Migrate MySQL database to utf8..." --weight=2 - -ynh_mysql_connect_as --user=$db_user --password="$db_pwd" --database=$db_name \ - <<< "ALTER DATABASE $db_name CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;" - #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE #================================================= @@ -99,12 +91,12 @@ chown -R $app: "$install_dir" "$data_dir" # Define password in an intermediate var # The fact that it's called _password allows it to be -# picked up by Yunohost's auto-redact mecanism +# picked up by YunoHost's auto-redact mecanism admin_password="$(ynh_string_random --length=6)" # Install Nextcloud using a temporary admin user exec_occ maintenance:install \ - --database "mysql" --database-name $db_name \ + --database "pgsql" --database-name $db_name \ --database-user $db_user --database-pass "$db_pwd" \ --admin-user "admin" --admin-pass "$admin_password" \ --data-dir "$data_dir/data" \ @@ -115,9 +107,6 @@ exec_occ maintenance:install \ #================================================= ynh_script_progression --message="Configuring $app..." --weight=8 -# Set the mysql.utf8mb4 config to true in config.php -exec_occ config:system:set mysql.utf8mb4 --type boolean --value="true" - # Ensure that UpdateNotification app is disabled exec_occ app:disable updatenotification @@ -203,8 +192,9 @@ exec_occ config:system:set overwrite.cli.url --value="https://${domain}" #================================================= # Set the user as admin -ynh_mysql_connect_as --user=$db_name --password="$db_pwd" --database=$db_name --default_character_set="utf8mb4" \ +ynh_psql_connect_as --user=$db_user --password="$db_pwd" --database=$db_name \ <<< "INSERT INTO oc_group_user VALUES ('admin','$admin');" + # And delete admin user exec_occ user:delete admin @@ -241,10 +231,12 @@ ynh_script_progression --message="Adding 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 diff --git a/scripts/restore b/scripts/restore index 3dde00f..915dd14 100755 --- a/scripts/restore +++ b/scripts/restore @@ -20,11 +20,11 @@ ynh_script_progression --message="Restoring the app main directory..." ynh_restore_file --origin_path="$install_dir" #================================================= -# RESTORE THE MYSQL DATABASE +# RESTORE THE POSTGRESQL DATABASE #================================================= -ynh_script_progression --message="Restoring the MySQL database..." --weight=9 +ynh_script_progression --message="Restoring the PostgreSQL database..." --weight=9 -ynh_mysql_connect_as --user=$db_name --password=$db_pwd --database=$db_name --default_character_set="utf8mb4" < ./db.sql +ynh_pgsql_connect_as --user=$db_user --password=$db_pwd --database=$db_name --default_character_set="utf8mb4" < ./db.sql #================================================= # RESTORE THE PHP-FPM CONFIGURATION diff --git a/scripts/upgrade b/scripts/upgrade index df854d0..9bc603e 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -118,7 +118,7 @@ create_external_storage() { local data_dir="$1" local mount_name="$2" local mount_id=$(exec_occ files_external:create --output=json \ - "$mount_name" 'local' 'null::null' -c "data_dir=$data_dir" || true) + "$mount_name" 'local' 'null::null' -c "data_dir=$data_dir/data" || true) ! [[ $mount_id =~ ^[0-9]+$ ]] \ && ynh_print_warn --message="Unable to create external storage" \ || exec_occ files_external:option "$mount_id" enable_sharing true From 5a114fddf658dd979fb9bf1b7aa31c66ac52511f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 10:32:15 +0200 Subject: [PATCH 003/127] cleaning --- scripts/_ynh_mysql_connect_as.sh | 36 ------------------------------- scripts/install | 1 - scripts/upgrade | 37 +++++++++++++++++++++----------- 3 files changed, 24 insertions(+), 50 deletions(-) delete mode 100644 scripts/_ynh_mysql_connect_as.sh diff --git a/scripts/_ynh_mysql_connect_as.sh b/scripts/_ynh_mysql_connect_as.sh deleted file mode 100644 index a22963e..0000000 --- a/scripts/_ynh_mysql_connect_as.sh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/bash - -# Open a connection as a user -# -# example: ynh_mysql_connect_as --user="user" --password="pass" <<< "UPDATE ...;" -# example: ynh_mysql_connect_as --user="user" --password="pass" --default_character_set="utf8mb4" < /path/to/file.sql -# -# usage: ynh_mysql_connect_as --user=user --password=password [--database=database] [--default_character_set=character-set] -# | arg: -u, --user= - the user name to connect as -# | arg: -p, --password= - the user password -# | arg: -d, --database= - the database to connect to -# | arg: -c, --default_character_set= - the charset to use -# -# Requires YunoHost version 2.2.4 or higher. -ynh_mysql_connect_as() { - # Declare an array to define the options of this helper. - local legacy_args=updc - local -A args_array=( [u]=user= [p]=password= [d]=database= [c]=default_character_set= ) - local user - local password - local database - local default_character_set - # Manage arguments with getopts - ynh_handle_getopts_args "$@" - database="${database:-}" - default_character_set="${default_character_set:-}" - - if [ -n "$default_character_set" ] - then - default_character_set="--default-character-set=$default_character_set" - else - default_character_set="--default-character-set=latin1" - fi - - mysql --user="$user" --password="$password" "$default_character_set" --batch "$database" -} \ No newline at end of file diff --git a/scripts/install b/scripts/install index b453dd0..c9d9feb 100755 --- a/scripts/install +++ b/scripts/install @@ -8,7 +8,6 @@ source _common.sh source /usr/share/yunohost/helpers -source _ynh_mysql_connect_as.sh #================================================= # STORE SETTINGS FROM MANIFEST diff --git a/scripts/upgrade b/scripts/upgrade index 9bc603e..306519c 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -123,8 +123,28 @@ local mount_id=$(exec_occ files_external:create --output=json \ && ynh_print_warn --message="Unable to create external storage" \ || exec_occ files_external:option "$mount_id" enable_sharing true } -# Define app's data directory -#data_dir="/home/yunohost.app/$app/data" + +#================================================= +# HANDLE DATABASE MIGRATION +#================================================= + +mysql_db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd) +if [ -n "$mysql_db_pwd" ] +then + ynh_script_progression --message="Migrate Database..." + + ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" + + ynh_psql_test_if_first_run + ynh_psql_setup_db --db_user=$db_name --db_name=$db_name + + exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n + + ynh_mysql_remove_db --db_user=$db_name --db_name=$db_name + ynh_app_setting_delete --app=$app --key=mysqlpwd + + ynh_store_file_checksum --file="${install_dir}/config/config.php" +fi if [ "$upgrade_type" == "UPGRADE_APP" ] then @@ -142,15 +162,6 @@ then # Print the current version number of Nextcloud exec_occ -V - if [ "$(exec_occ config:system:get mysql.utf8mb4)" != "true" ]; then - db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd) - # Change your databases character set and collation - ynh_mysql_connect_as --user=$db_user --password="$db_pwd" --database=$db_name \ - <<< "ALTER DATABASE $db_name CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;" - # Set the mysql.utf8mb4 config to true in config.php - exec_occ config:system:set mysql.utf8mb4 --type boolean --value="true" - exec_occ maintenance:repair - fi # Upgrade may fail if this app is enabled # Take all apps enabled, and check if mail is one of them @@ -188,7 +199,7 @@ then # Load the value for this version source upgrade.d/upgrade.$current_major_version.sh - ynh_print_info --message="Upgrade to nextcloud $next_version" + ynh_print_info --message="Upgrade to Nextcloud $next_version" # Create an app.src for this version of Nextcloud cat > ../conf/app.src << EOF @@ -242,7 +253,7 @@ EOF current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) current_major_version=${current_version%%.*} - # Print the current version number of nextcloud + # Print the current version number of Nextcloud exec_occ -V done From 0844be6a5255c52c49507aa70f67df757f4fdcb2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 10:51:48 +0200 Subject: [PATCH 004/127] Update restore --- scripts/restore | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/restore b/scripts/restore index 915dd14..ad0c443 100755 --- a/scripts/restore +++ b/scripts/restore @@ -8,7 +8,6 @@ source ../settings/scripts/_common.sh source /usr/share/yunohost/helpers -source ../settings/scripts/_ynh_mysql_connect_as.sh #================================================= # STANDARD RESTORATION STEPS From 9bf02287384c101901548bd55df704a18697b045 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 11:24:28 +0200 Subject: [PATCH 005/127] Update _common.sh --- scripts/_common.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/scripts/_common.sh b/scripts/_common.sh index 19e6a36..8e445c1 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -8,6 +8,19 @@ # EXPERIMENTAL HELPERS #================================================= +# 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/data" || true` +! [[ $mount_id =~ ^[0-9]+$ ]] \ + && ynh_print_warn --message="Unable to create external storage" \ + || exec_occ files_external:option "$mount_id" enable_sharing true +} + + # Check if an URL is already handled # usage: is_url_handled --domain=DOMAIN --path=PATH_URI is_url_handled() { From 6eb29b1d715cca36da5a8e9f3067551fb2746841 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 11:26:47 +0200 Subject: [PATCH 006/127] Update _common.sh --- scripts/_common.sh | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 8e445c1..19e6a36 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -8,19 +8,6 @@ # EXPERIMENTAL HELPERS #================================================= -# 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/data" || true` -! [[ $mount_id =~ ^[0-9]+$ ]] \ - && ynh_print_warn --message="Unable to create external storage" \ - || exec_occ files_external:option "$mount_id" enable_sharing true -} - - # Check if an URL is already handled # usage: is_url_handled --domain=DOMAIN --path=PATH_URI is_url_handled() { From 81e1eaeb970a2c435dca54a36352871ac417819a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 11:39:31 +0200 Subject: [PATCH 007/127] Fix --- scripts/_common.sh | 14 ++++++++++++++ scripts/install | 12 ------------ scripts/upgrade | 12 ------------ 3 files changed, 14 insertions(+), 24 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 19e6a36..eb8de61 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -8,6 +8,20 @@ # EXPERIMENTAL HELPERS #================================================= +# 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/data" || true) +! [[ $mount_id =~ ^[0-9]+$ ]] \ + && ynh_print_warn --message="Unable to create external storage" \ + || exec_occ files_external:option "$mount_id" enable_sharing true +} + +#================================================= + # Check if an URL is already handled # usage: is_url_handled --domain=DOMAIN --path=PATH_URI is_url_handled() { diff --git a/scripts/install b/scripts/install index c9d9feb..f0673b1 100755 --- a/scripts/install +++ b/scripts/install @@ -143,18 +143,6 @@ exec_occ ldap:test-config '' \ # MOUNT HOME FOLDERS AS EXTERNAL STORAGE #================================================= -# Define a function to add an external storage -# Create the external storage for the given folders and enable sharing -create_external_storage() { - local data_dir="$1" - local mount_name="$2" - local mount_id=`exec_occ files_external:create --output=json \ - "$mount_name" 'local' 'null::null' -c "data_dir=$data_dir/data" || true` - ! [[ $mount_id =~ ^[0-9]+$ ]] \ - && ynh_print_warn --message="Unable to create external storage" \ - || exec_occ files_external:option "$mount_id" enable_sharing true -} - # Enable External Storage and create local mount to home folder if [ $user_home -eq 1 ] then diff --git a/scripts/upgrade b/scripts/upgrade index 306519c..6c23616 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -112,18 +112,6 @@ exec_occ() { php$NEXTCLOUD_PHP_VERSION --define apc.enable_cli=1 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() { -local data_dir="$1" -local mount_name="$2" -local mount_id=$(exec_occ files_external:create --output=json \ - "$mount_name" 'local' 'null::null' -c "data_dir=$data_dir/data" || true) -! [[ $mount_id =~ ^[0-9]+$ ]] \ - && ynh_print_warn --message="Unable to create external storage" \ - || exec_occ files_external:option "$mount_id" enable_sharing true -} - #================================================= # HANDLE DATABASE MIGRATION #================================================= From 09480477f594ab70fef0c31ff6cbcfb6b218e43d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 12:19:24 +0200 Subject: [PATCH 008/127] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 32b295b..8e341ab 100644 --- a/manifest.toml +++ b/manifest.toml @@ -25,7 +25,7 @@ multi_instance = true ldap = true sso = true disk = "50M" -ram.build = "300M" +ram.build = "500M" ram.runtime = "512M" [install] From e942be496119152cea7aa5cf16da871af3f15403 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 12:20:09 +0200 Subject: [PATCH 009/127] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 8e341ab..9e987cd 100644 --- a/manifest.toml +++ b/manifest.toml @@ -69,7 +69,7 @@ ram.runtime = "512M" api.allowed = ["visitors", "all_users"] [resources.apt] - packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.2-pgsql, php8.2-fpm, php8.2-bz2, php8.2-imap, php8.2-gmp, php8.2-gd, php8.2-intl, php8.2-curl, php8.2-apcu, php8.2-redis, php8.2-ldap, php8.2-imagick, php8.2-zip, php8.2-mbstring, php8.2-xml, php8.2-mysql, php8.2-igbinary, php8.2-bcmath" + packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.2-pgsql, php8.2-fpm, php8.2-bz2, php8.2-imap, php8.2-gmp, php8.2-gd, php8.2-intl, php8.2-curl, php8.2-apcu, php8.2-redis, php8.2-ldap, php8.2-imagick, php8.2-zip, php8.2-mbstring, php8.2-xml, php8.2-igbinary, php8.2-bcmath" [resources.database] type = "postgresql" From ee2b79ac13eb0b77e50262c3f5f617567ec1757e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 12:28:12 +0200 Subject: [PATCH 010/127] Move exec_occ to common.sh --- scripts/_common.sh | 12 +++++++++--- scripts/install | 6 ------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index eb8de61..6366b74 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -1,11 +1,15 @@ #!/bin/bash #================================================= -# COMMON VARIABLES +# COMMON FUCTIONS #================================================= -#================================================= -# EXPERIMENTAL HELPERS +# Define a function to execute commands with `occ` +exec_occ() { + (cd "$install_dir" && ynh_exec_as "$app" \ + php${phpversion} --define apc.enable_cli=1 occ --no-interaction --no-ansi "$@") +} + #================================================= # Define a function to add an external storage @@ -20,6 +24,8 @@ local mount_id=$(exec_occ files_external:create --output=json \ || exec_occ files_external:option "$mount_id" enable_sharing true } +#================================================= +# EXPERIMENTAL HELPERS #================================================= # Check if an URL is already handled diff --git a/scripts/install b/scripts/install index f0673b1..82d8345 100755 --- a/scripts/install +++ b/scripts/install @@ -79,12 +79,6 @@ ynh_add_nginx_config #================================================= ynh_script_progression --message="Installing $app..." --weight=30 -# Define a function to execute commands with `occ` -exec_occ() { - (cd "$install_dir" && ynh_exec_as "$app" \ - php${phpversion} --define apc.enable_cli=1 occ --no-interaction --no-ansi "$@") -} - # Set write access for the following commands chown -R $app: "$install_dir" "$data_dir" From b6091c4f70ebe06a9d26fd6104431ab8e74f02ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 12:35:31 +0200 Subject: [PATCH 011/127] cleaning --- scripts/_common.sh | 8 -------- scripts/install | 6 ++++++ scripts/upgrade | 19 +++++++++++++++++++ 3 files changed, 25 insertions(+), 8 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 6366b74..5591139 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -4,14 +4,6 @@ # COMMON FUCTIONS #================================================= -# Define a function to execute commands with `occ` -exec_occ() { - (cd "$install_dir" && ynh_exec_as "$app" \ - php${phpversion} --define apc.enable_cli=1 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() { diff --git a/scripts/install b/scripts/install index 82d8345..f0673b1 100755 --- a/scripts/install +++ b/scripts/install @@ -79,6 +79,12 @@ ynh_add_nginx_config #================================================= ynh_script_progression --message="Installing $app..." --weight=30 +# Define a function to execute commands with `occ` +exec_occ() { + (cd "$install_dir" && ynh_exec_as "$app" \ + php${phpversion} --define apc.enable_cli=1 occ --no-interaction --no-ansi "$@") +} + # Set write access for the following commands chown -R $app: "$install_dir" "$data_dir" diff --git a/scripts/upgrade b/scripts/upgrade index 6c23616..49e5a73 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -112,6 +112,25 @@ exec_occ() { php$NEXTCLOUD_PHP_VERSION --define apc.enable_cli=1 occ --no-interaction --no-ansi "$@") } +# Define a function to execute commands with `occ` +exec_occ() { + # Backward compatibility to upgrade from older versions + if [ $current_major_version = "last" ] + then + NEXTCLOUD_PHP_VERSION=$phpversion + elif [ $current_major_version -ge 24 ] + then + NEXTCLOUD_PHP_VERSION="8.0" + elif [ $current_major_version -ge 15 ] + then + NEXTCLOUD_PHP_VERSION="7.4" + else + NEXTCLOUD_PHP_VERSION="7.0" + fi +(cd "$install_dir" && ynh_exec_as "$app" \ + php$NEXTCLOUD_PHP_VERSION --define apc.enable_cli=1 occ --no-interaction --no-ansi "$@") +} + #================================================= # HANDLE DATABASE MIGRATION #================================================= From 028d6ebbbee736b477838b7428b510b0bddab5e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 13:13:58 +0200 Subject: [PATCH 012/127] Update restore --- scripts/restore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/restore b/scripts/restore index ad0c443..72ea7ee 100755 --- a/scripts/restore +++ b/scripts/restore @@ -23,7 +23,7 @@ ynh_restore_file --origin_path="$install_dir" #================================================= ynh_script_progression --message="Restoring the PostgreSQL database..." --weight=9 -ynh_pgsql_connect_as --user=$db_user --password=$db_pwd --database=$db_name --default_character_set="utf8mb4" < ./db.sql +ynh_psql_connect_as --user=$db_user --password=$db_pwd --database=$db_name --default_character_set="utf8mb4" < ./db.sql #================================================= # RESTORE THE PHP-FPM CONFIGURATION From e0b04bb379d2bedf444e540963ae2e40aea79183 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 13:21:13 +0200 Subject: [PATCH 013/127] Update upgrade --- scripts/upgrade | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 49e5a73..1037b25 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -96,22 +96,6 @@ ynh_add_nginx_config current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) current_major_version=${current_version%%.*} -# Define a function to execute commands with `occ` -exec_occ() { - # Backward compatibility to upgrade from older versions - if [ $current_major_version = "last" ] || [ $current_major_version -ge 24 ] - then - NEXTCLOUD_PHP_VERSION=$phpversion - elif [ $current_major_version -ge 15 ] - then - NEXTCLOUD_PHP_VERSION="7.4" - else - NEXTCLOUD_PHP_VERSION="7.0" - fi -(cd "$install_dir" && ynh_exec_as "$app" \ - php$NEXTCLOUD_PHP_VERSION --define apc.enable_cli=1 occ --no-interaction --no-ansi "$@") -} - # Define a function to execute commands with `occ` exec_occ() { # Backward compatibility to upgrade from older versions From a7118fac002ff46c8df7031e23c2db8a3e082338 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 13:50:39 +0200 Subject: [PATCH 014/127] Update upgrade --- scripts/upgrade | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 1037b25..6c23616 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -99,12 +99,9 @@ current_major_version=${current_version%%.*} # Define a function to execute commands with `occ` exec_occ() { # Backward compatibility to upgrade from older versions - if [ $current_major_version = "last" ] + if [ $current_major_version = "last" ] || [ $current_major_version -ge 24 ] then NEXTCLOUD_PHP_VERSION=$phpversion - elif [ $current_major_version -ge 24 ] - then - NEXTCLOUD_PHP_VERSION="8.0" elif [ $current_major_version -ge 15 ] then NEXTCLOUD_PHP_VERSION="7.4" From 4719e0f3951b80f3b7262da2a3a403a017120847 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 14:29:01 +0200 Subject: [PATCH 015/127] #584 --- scripts/install | 8 ++++---- scripts/restore | 8 ++++---- scripts/upgrade | 8 ++++---- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/scripts/install b/scripts/install index f0673b1..8e93f06 100755 --- a/scripts/install +++ b/scripts/install @@ -236,10 +236,10 @@ ynh_multimedia_addaccess $app # Fix app ownerships & permissions chown -R $app:www-data "$install_dir" chown -R $app: "$data_dir" -find $install_dir/ -type f -print0 | xargs -0 chmod 0644 -find $install_dir/ -type d -print0 | xargs -0 chmod 0755 -find $data_dir/data/ -type f -print0 | xargs -0 chmod 0640 -find $data_dir/data/ -type d -print0 | xargs -0 chmod 0750 +find $install_dir/ -type f -print0 | xargs -r0 chmod 0644 +find $install_dir/ -type d -print0 | xargs -r0 chmod 0755 +find $data_dir/data/ -type f -print0 | xargs -r0 chmod 0640 +find $data_dir/data/ -type d -print0 | xargs -r0 chmod 0750 chmod 640 "$install_dir/config/config.php" chmod 755 /home/yunohost.app chmod 750 $install_dir diff --git a/scripts/restore b/scripts/restore index 72ea7ee..f2d522a 100755 --- a/scripts/restore +++ b/scripts/restore @@ -80,10 +80,10 @@ ynh_restore_file --origin_path="$data_dir" --not_mandatory # Fix app ownerships & permissions chown -R $app:www-data "$install_dir" chown -R $app: "$data_dir" -find $install_dir/ -type f -print0 | xargs -0 chmod 0644 -find $install_dir/ -type d -print0 | xargs -0 chmod 0755 -find $data_dir/data/ -type f -print0 | xargs -0 chmod 0640 -find $data_dir/data/ -type d -print0 | xargs -0 chmod 0750 +find $install_dir/ -type f -print0 | xargs -r0 chmod 0644 +find $install_dir/ -type d -print0 | xargs -r0 chmod 0755 +find $data_dir/data/ -type f -print0 | xargs -r0 chmod 0640 +find $data_dir/data/ -type d -print0 | xargs -r0 chmod 0750 chmod 640 "$install_dir/config/config.php" chmod 755 /home/yunohost.app chmod 750 $install_dir diff --git a/scripts/upgrade b/scripts/upgrade index 6c23616..e945414 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -342,10 +342,10 @@ exec_occ background:cron # Fix app ownerships & permissions chown -R $app:www-data "$install_dir" chown -R $app: "$data_dir" -find $install_dir/ -type f -print0 | xargs -0 chmod 0644 -find $install_dir/ -type d -print0 | xargs -0 chmod 0755 -find $data_dir/data/ -type f -print0 | xargs -0 chmod 0640 -find $data_dir/data/ -type d -print0 | xargs -0 chmod 0750 +find $install_dir/ -type f -print0 | xargs -r0 chmod 0644 +find $install_dir/ -type d -print0 | xargs -r0 chmod 0755 +find $data_dir/data/ -type f -print0 | xargs -r0 chmod 0640 +find $data_dir/data/ -type d -print0 | xargs -r0 chmod 0750 chmod 640 "$install_dir/config/config.php" chmod 755 /home/yunohost.app chmod 750 $install_dir From 2ff88b00418c91914cd30fff00f3d4a32b3d9c1a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 11 Jun 2023 14:47:58 +0200 Subject: [PATCH 016/127] Update change_url --- scripts/change_url | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/change_url b/scripts/change_url index 156db53..0d8a142 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -41,7 +41,7 @@ then # Check if .well-known is available for this domain if is_url_handled --domain="$new_domain" --path="/.well-known/caldav" || is_url_handled --domain="$new_domain" --path="/.well-known/carddav" then - ynh_print_warn --message="Another app already uses the domain $new_domain to serve a caldav/carddav feature. You may encounter issues when dealing with your calendar or address book." + ynh_print_warn --message="Another app already uses the domain $new_domain to serve a CalDAV/CardDAV feature. You may encounter issues when dealing with your calendar or address book." # Remove lines about .well-known/carddav and caldav with sed. sed --in-place --regexp-extended '/location = \/\.well\-known\/(caldav|carddav)/d' "/etc/nginx/conf.d/$new_domain.d/$app.conf" From 9902ad326e853537d350a877e02399c52a5c41bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 11:13:31 +0200 Subject: [PATCH 017/127] Update restore --- scripts/restore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/restore b/scripts/restore index f2d522a..eb6a985 100755 --- a/scripts/restore +++ b/scripts/restore @@ -23,7 +23,7 @@ ynh_restore_file --origin_path="$install_dir" #================================================= ynh_script_progression --message="Restoring the PostgreSQL database..." --weight=9 -ynh_psql_connect_as --user=$db_user --password=$db_pwd --database=$db_name --default_character_set="utf8mb4" < ./db.sql +ynh_psql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./db.sql #================================================= # RESTORE THE PHP-FPM CONFIGURATION From 59f4d751efc1fb4ff6cefd1ce2811dc3280c5436 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 11:28:58 +0200 Subject: [PATCH 018/127] cleaning --- scripts/restore | 2 +- scripts/upgrade | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/restore b/scripts/restore index eb6a985..27f6844 100755 --- a/scripts/restore +++ b/scripts/restore @@ -28,7 +28,7 @@ ynh_psql_connect_as --user=$db_user --password=$db_pwd --database=$db_name < ./d #================================================= # RESTORE THE PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Reconfiguring PHP-FPM..." --weight=50 +ynh_script_progression --message="Reconfiguring PHP-FPM..." --weight=5 # Restore the file first, so it can have a backup if different ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf" diff --git a/scripts/upgrade b/scripts/upgrade index e945414..3d43349 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -119,16 +119,16 @@ exec_occ() { mysql_db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd) if [ -n "$mysql_db_pwd" ] then - ynh_script_progression --message="Migrate Database..." + ynh_script_progression --message="Migrating to PostgreSQL database..." ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" ynh_psql_test_if_first_run - ynh_psql_setup_db --db_user=$db_name --db_name=$db_name + ynh_psql_setup_db --db_user=$db_user --db_name=$db_name exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n - ynh_mysql_remove_db --db_user=$db_name --db_name=$db_name + ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name ynh_app_setting_delete --app=$app --key=mysqlpwd ynh_store_file_checksum --file="${install_dir}/config/config.php" From 931a3bc507609f24113d7d955dba655ea91aae78 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 11:32:55 +0200 Subject: [PATCH 019/127] Update _common.sh --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 5591139..2a7085a 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -10,7 +10,7 @@ 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/data" || true) + "$mount_name" 'local' 'null::null' -c "datadir=$data_dir/data" || true) ! [[ $mount_id =~ ^[0-9]+$ ]] \ && ynh_print_warn --message="Unable to create external storage" \ || exec_occ files_external:option "$mount_id" enable_sharing true From 0addb2ad955ef70363e47e1f36aab88196b1e297 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Mon, 12 Jun 2023 09:36:07 +0000 Subject: [PATCH 020/127] Auto-update README --- README.md | 2 +- README_fr.md | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 05a118e..43281fc 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ this package: * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 26.0.2~ynh3 +**Shipped version:** 26.0.2~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index b231091..173f9a5 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,8 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 26.0.2~ynh3 - +**Version incluse :** 26.0.2~ynh1 **Démo :** https://demo.nextcloud.com/ From 77fd54fc4b7ab00f8353143dff91a4401ebf396a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 11:39:33 +0200 Subject: [PATCH 021/127] Update upgrade --- scripts/upgrade | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/upgrade b/scripts/upgrade index 3d43349..c586dc3 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -112,6 +112,10 @@ exec_occ() { php$NEXTCLOUD_PHP_VERSION --define apc.enable_cli=1 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 + #================================================= # HANDLE DATABASE MIGRATION #================================================= From 03f52ae739c355cd009dd47598a8da6463db74dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 11:40:30 +0200 Subject: [PATCH 022/127] Update install --- scripts/install | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/install b/scripts/install index 8e93f06..d3e9eec 100755 --- a/scripts/install +++ b/scripts/install @@ -143,6 +143,10 @@ exec_occ ldap:test-config '' \ # MOUNT HOME FOLDERS AS EXTERNAL STORAGE #================================================= +# Define a function to add an external storage +# Create the external storage for the given folders and enable sharing +create_external_storage + # Enable External Storage and create local mount to home folder if [ $user_home -eq 1 ] then From 33d901ce3a740847dfeb5cb0d429b3cd358bb918 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 12 Jun 2023 11:52:03 +0200 Subject: [PATCH 023/127] fix --- scripts/install | 4 ---- scripts/upgrade | 4 ---- 2 files changed, 8 deletions(-) diff --git a/scripts/install b/scripts/install index d3e9eec..8e93f06 100755 --- a/scripts/install +++ b/scripts/install @@ -143,10 +143,6 @@ exec_occ ldap:test-config '' \ # MOUNT HOME FOLDERS AS EXTERNAL STORAGE #================================================= -# Define a function to add an external storage -# Create the external storage for the given folders and enable sharing -create_external_storage - # Enable External Storage and create local mount to home folder if [ $user_home -eq 1 ] then diff --git a/scripts/upgrade b/scripts/upgrade index c586dc3..3d43349 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -112,10 +112,6 @@ exec_occ() { php$NEXTCLOUD_PHP_VERSION --define apc.enable_cli=1 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 - #================================================= # HANDLE DATABASE MIGRATION #================================================= From c0c13e9d3c17a3fb0b9c67a0d4657289b4b1e939 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 13 Jun 2023 13:34:47 +0200 Subject: [PATCH 024/127] 27.0.0 --- manifest.toml | 2 +- scripts/upgrade.d/upgrade.26.sh | 7 +++++++ scripts/upgrade.d/upgrade.last.sh | 4 ++-- 3 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 scripts/upgrade.d/upgrade.26.sh diff --git a/manifest.toml b/manifest.toml index 9e987cd..cea0aca 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "26.0.2~ynh1" +version = "27.0.0~ynh1" maintainers = ["kay0u"] diff --git a/scripts/upgrade.d/upgrade.26.sh b/scripts/upgrade.d/upgrade.26.sh new file mode 100644 index 0000000..59b4622 --- /dev/null +++ b/scripts/upgrade.d/upgrade.26.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +# Last available Nextcloud version +next_version="27.0.0" + +# Nextcloud tarball checksum sha256 +nextcloud_source_sha256="3d312a09b9345ac058758dd7b4059bf3cf0b1f0f1d747251b6fac3585ba6533f" diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index ba24f4f..59b4622 100644 --- 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="26.0.2" +next_version="27.0.0" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="f3db0ec5e0aaff7c088eb34f752d77d79913bc6784e0fc47a84cdaa28e567a33" +nextcloud_source_sha256="3d312a09b9345ac058758dd7b4059bf3cf0b1f0f1d747251b6fac3585ba6533f" From be67693c22cb91657f9e46bb98f2f1295a24fcd6 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 13 Jun 2023 11:34:52 +0000 Subject: [PATCH 025/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 43281fc..719d640 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ this package: * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 26.0.2~ynh1 +**Shipped version:** 27.0.0~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 173f9a5..c443752 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 26.0.2~ynh1 +**Version incluse :** 27.0.0~ynh1 **Démo :** https://demo.nextcloud.com/ From c70f9102d9b67f4e9cabb59e8794aa1b9e3ba1ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 13 Jun 2023 16:40:59 +0200 Subject: [PATCH 026/127] cleaning --- doc/ADMIN.md | 6 +++++- doc/ADMIN_fr.md | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/doc/ADMIN.md b/doc/ADMIN.md index 2feddbb..e682db7 100644 --- a/doc/ADMIN.md +++ b/doc/ADMIN.md @@ -1,3 +1,7 @@ +### Comment utiliser la commande CLI + +`sudo -u __APP__ php__YNH_PHP_VERSION__ --define apc.enable_cli=1 __INSTALL_DIR__/occ ...` + ### Configure ONLYOFFICE integration #### With Nextcloud App (no ARM support, lower performance) @@ -6,7 +10,7 @@ Starting from Nextcloud 18, it features a direct integration of ONLYOFFICE (an o To install and configure it: - Install *Community Document Server* application in your Nextcloud. That's the part that runs ONLYOFFICE server. - Install *ONLYOFFICE* application. That's the client part that will connect to an ONLYOFFICE server. -- Then in Settings -> ONLYOFFICE (`https://__DOMAIN__/__PATH__/settings/admin/onlyoffice`), if you want to configure which file formats should be opened by ONLYOFFICE. +- Then in Settings -> ONLYOFFICE (`https://__DOMAIN____PATH__/settings/admin/onlyoffice`), if you want to configure which file formats should be opened by ONLYOFFICE. - Here you go :) You should be able to create new type of documents and open them. *NB: ONLYOFFICE Nextcloud App is only available for x86 architecture - for **ARM** architecture (Raspberry Pi, OLinuXino...), consider the YunoHost App below* diff --git a/doc/ADMIN_fr.md b/doc/ADMIN_fr.md index 4977f09..f0b4de1 100644 --- a/doc/ADMIN_fr.md +++ b/doc/ADMIN_fr.md @@ -1,3 +1,7 @@ +### How to use CLI commande + +`sudo -u __APP__ php__YNH_PHP_VERSION__ --define apc.enable_cli=1 __INSTALL_DIR__/occ ...` + ### Configurer l'intégration d'ONLYOFFICE #### Avec l'application Nextcloud (pas de support ARM, performances limitées) @@ -6,7 +10,7 @@ Pour l'installer et la configurer : - Installez l'application *Community Document Server* dans votre Nextcloud. C'est la partie qui fait tourner un serveur ONLYOFFICE. - Installez l'application *ONLYOFFICE*. C'est la partie cliente qui va se connecter au serveur ONLYOFFICE. -- Ensuite dans les Paramètres -> ONLYOFFICE (`https://__DOMAIN__/__PATH__/settings/admin/onlyoffice`), si vous voulez configurer quels formats de fichier s'ouvrent avec ONLYOFFICE. +- Ensuite dans les Paramètres -> ONLYOFFICE (`https://__DOMAIN____PATH__/settings/admin/onlyoffice`), si vous voulez configurer quels formats de fichier s'ouvrent avec ONLYOFFICE. - Et voilà :) Vous devriez pouvoir créer de nouveaux types de documents, et les ouvrir. *NB : l'app Nextcloud ONLYOFFICE Community Document Server n'est disponible que sous architecture x86 - Pour un support de l'architecture **ARM** (Raspberry Pi, OLinuXino...), installez plutôt l'App YunoHost, voir ci-dessous* From 351fa40615a6088c38e2f38ff33e0bd2eb321fea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 20 Jul 2023 17:18:47 +0200 Subject: [PATCH 027/127] 27.0.1 --- manifest.toml | 4 ++-- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/manifest.toml b/manifest.toml index cea0aca..49d4e89 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "27.0.0~ynh1" +version = "27.0.1~ynh1" maintainers = ["kay0u"] @@ -19,7 +19,7 @@ code = "https://github.com/nextcloud/server" cpe = "cpe:2.3:a:nextcloud:nextcloud" [integration] -yunohost = ">= 11.1.20" +yunohost = ">= 11.1.21" architectures = ["amd64", "arm64"] multi_instance = true ldap = true diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 59b4622..32b7722 100644 --- 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="27.0.0" +next_version="27.0.1" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="3d312a09b9345ac058758dd7b4059bf3cf0b1f0f1d747251b6fac3585ba6533f" +nextcloud_source_sha256="3976b5e8f58f934ddbeb7cc49ac33b11ad3adbd7f6d5d0908a0fc36a160c27bd" From 73183c464e91fd74d2f4aca546ea4feedfe77e3e Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 20 Jul 2023 15:18:52 +0000 Subject: [PATCH 028/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 719d640..de84a49 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ this package: * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.0.0~ynh1 +**Shipped version:** 27.0.1~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index c443752..539a463 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.0.0~ynh1 +**Version incluse :** 27.0.1~ynh1 **Démo :** https://demo.nextcloud.com/ From 0c5216a66119897a7c94e1bcb18b001613c33fc8 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 30 Jul 2023 08:35:44 +0100 Subject: [PATCH 029/127] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 49d4e89..e80c181 100644 --- a/manifest.toml +++ b/manifest.toml @@ -19,7 +19,7 @@ code = "https://github.com/nextcloud/server" cpe = "cpe:2.3:a:nextcloud:nextcloud" [integration] -yunohost = ">= 11.1.21" +yunohost = ">= 11.2" architectures = ["amd64", "arm64"] multi_instance = true ldap = true From 43096591c94cd9b6114c9bc63ff4d39ec9f06c3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 11 Aug 2023 11:41:42 +0200 Subject: [PATCH 030/127] 27.0.2 --- manifest.toml | 2 +- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index e80c181..0f4fba0 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "27.0.1~ynh1" +version = "27.0.2~ynh1" maintainers = ["kay0u"] diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 32b7722..99a4829 100644 --- 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="27.0.1" +next_version="27.0.2" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="3976b5e8f58f934ddbeb7cc49ac33b11ad3adbd7f6d5d0908a0fc36a160c27bd" +nextcloud_source_sha256="7a2dcea43aa3b8fb303347efda4c6f37733cca113c8ee16dd9f0e5fb68c7212f" From 6c50ba9fd2b6ed4283a348cdf627daafb95e4333 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Fri, 11 Aug 2023 09:41:47 +0000 Subject: [PATCH 031/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index de84a49..465375d 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ this package: * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.0.1~ynh1 +**Shipped version:** 27.0.2~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 539a463..f3c768b 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.0.1~ynh1 +**Version incluse :** 27.0.2~ynh1 **Démo :** https://demo.nextcloud.com/ From fc90a3b280446103801c4e536d78f862cb91cd42 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Thu, 24 Aug 2023 23:26:09 +0200 Subject: [PATCH 032/127] Update nginx.conf --- conf/nginx.conf | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/conf/nginx.conf b/conf/nginx.conf index 395a5c5..1a5fc18 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -105,6 +105,14 @@ location ^~ __PATH__/ { fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock; fastcgi_intercept_errors on; fastcgi_request_buffering off; + + fastcgi_read_timeout 600; + fastcgi_send_timeout 600; + fastcgi_connect_timeout 600; + proxy_connect_timeout 600; + proxy_send_timeout 600; + proxy_read_timeout 600; + send_timeout 600; } location ~ ^__PATH__/(?:updater|oc[ms]-provider)(?:$|/) { From 920d2d74c1ca788bc9c89c633530ffe81f3ad9b9 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sat, 9 Sep 2023 07:48:41 +0200 Subject: [PATCH 033/127] Update install --- scripts/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/install b/scripts/install index 8e93f06..f96ff2d 100755 --- a/scripts/install +++ b/scripts/install @@ -52,7 +52,7 @@ ynh_setup_source --dest_dir="$install_dir" #================================================= # PHP-FPM CONFIGURATION #================================================= -ynh_script_progression --message="Configuring PHP-FPM..." --weight=50 +ynh_script_progression --message="Configuring PHP-FPM..." --weight=5 # Create a dedicated PHP-FPM config ynh_add_fpm_config --usage=$fpm_usage --footprint=$fpm_footprint From 4762aa856c7fa99adb0c3003448c095749b70f01 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 15 Sep 2023 21:31:36 +0200 Subject: [PATCH 034/127] 27.1.0 --- manifest.toml | 4 ++-- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/manifest.toml b/manifest.toml index 0f4fba0..b0c05cd 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "27.0.2~ynh1" +version = "27.1.0~ynh1" maintainers = ["kay0u"] @@ -20,7 +20,7 @@ cpe = "cpe:2.3:a:nextcloud:nextcloud" [integration] yunohost = ">= 11.2" -architectures = ["amd64", "arm64"] +architectures = ["amd64", "arm64", "armhf"] multi_instance = true ldap = true sso = true diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 99a4829..f79ae9f 100644 --- 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="27.0.2" +next_version="27.1.0" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="7a2dcea43aa3b8fb303347efda4c6f37733cca113c8ee16dd9f0e5fb68c7212f" +nextcloud_source_sha256="da665584507020a071d41c6fef5f3996254854e13700059d6e9ca18c3f29211e" From f6a8076246f786c7dbeb1f2f711d34e048d100b9 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Fri, 15 Sep 2023 19:31:42 +0000 Subject: [PATCH 035/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 465375d..25d9998 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ this package: * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.0.2~ynh1 +**Shipped version:** 27.1.0~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index f3c768b..4929825 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.0.2~ynh1 +**Version incluse :** 27.1.0~ynh1 **Démo :** https://demo.nextcloud.com/ From df883068ad8012511ca5e4753b9a8ed5f766ccfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 15 Sep 2023 22:04:52 +0200 Subject: [PATCH 036/127] 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 f79ae9f..1040e22 100644 --- a/scripts/upgrade.d/upgrade.last.sh +++ b/scripts/upgrade.d/upgrade.last.sh @@ -4,4 +4,4 @@ next_version="27.1.0" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="da665584507020a071d41c6fef5f3996254854e13700059d6e9ca18c3f29211e" +nextcloud_source_sha256="c3167059e69c517b7ae07f3bb0b832433d324675859081fe953ea41bc7df1242" From 3812b23fd8627ac446a15726c21aa2c522604407 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 21 Sep 2023 10:53:32 +0200 Subject: [PATCH 037/127] Update tests.toml --- tests.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests.toml b/tests.toml index 44dd598..7f7a558 100644 --- a/tests.toml +++ b/tests.toml @@ -7,6 +7,8 @@ test_format = 1.0 # ------------------------------- test_upgrade_from.c5cf91ad.name = "Upgrade from 25.0.2" + test_upgrade_from.d02166a5.name = "Upgrade from 26.0.1" + test_upgrade_from.0f16f720.name = "Upgrade from 27.0.2" From a87205bb211b066d34e31f3136774521807faa04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 21 Sep 2023 13:21:29 +0200 Subject: [PATCH 038/127] 27.1.1 --- manifest.toml | 2 +- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index b0c05cd..f9fe3a9 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "27.1.0~ynh1" +version = "27.1.1~ynh1" maintainers = ["kay0u"] diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 1040e22..9e6becf 100644 --- 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="27.1.0" +next_version="27.1.1" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="c3167059e69c517b7ae07f3bb0b832433d324675859081fe953ea41bc7df1242" +nextcloud_source_sha256="3a91500566874675676fa3b5bfae2587a839cde41dfac5318043b162c1311fab" From afc3084ae465ad8cac304ac4dfbceab0cbb5a11d Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 21 Sep 2023 11:21:33 +0000 Subject: [PATCH 039/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 25d9998..655d87d 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ this package: * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.1.0~ynh1 +**Shipped version:** 27.1.1~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 4929825..1ffd833 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.1.0~ynh1 +**Version incluse :** 27.1.1~ynh1 **Démo :** https://demo.nextcloud.com/ From e7bfe5f7fce0becc63fdb1590d14b6d587712330 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 6 Oct 2023 08:20:19 +0200 Subject: [PATCH 040/127] 27.1.2 --- manifest.toml | 2 +- scripts/upgrade.d/upgrade.last.sh | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index f9fe3a9..cf786ea 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "27.1.1~ynh1" +version = "27.1.2~ynh1" maintainers = ["kay0u"] diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index 9e6becf..09a19f6 100644 --- 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="27.1.1" +next_version="27.1.2" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="3a91500566874675676fa3b5bfae2587a839cde41dfac5318043b162c1311fab" +nextcloud_source_sha256="0742b247aaee0b7044db0062f0a914aa77338c7a7d8fe7da0917147d76689721" From 0937844bde6768b98726c2727655f2c666795ea7 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Fri, 6 Oct 2023 06:20:24 +0000 Subject: [PATCH 041/127] Auto-update README --- README.md | 3 +-- README_fr.md | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 655d87d..36f664c 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ this package: * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.1.1~ynh1 +**Shipped version:** 27.1.2~ynh1 **Demo:** https://demo.nextcloud.com/ @@ -44,7 +44,6 @@ this package: * Official user documentation: * Official admin documentation: * Upstream app code repository: -* YunoHost documentation for this app: * Report a bug: ## Developer info diff --git a/README_fr.md b/README_fr.md index 1ffd833..c198a08 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.1.1~ynh1 +**Version incluse :** 27.1.2~ynh1 **Démo :** https://demo.nextcloud.com/ @@ -43,7 +43,6 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Documentation officielle utilisateur : * Documentation officielle de l’admin : * Dépôt de code officiel de l’app : -* Documentation YunoHost pour cette app : * Signaler un bug : ## Informations pour les développeurs From fd22e2271552ba9c66da3ce6e75b920866d9737d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 8 Oct 2023 21:10:15 +0200 Subject: [PATCH 042/127] Update nginx.conf --- conf/nginx.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 99168f0..1803b99 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -92,7 +92,7 @@ location ^~ __PATH__/ { # Required for legacy support # https://github.com/nextcloud/documentation/pull/2197#issuecomment-721432337 # This line fix the ldap admin page - rewrite ^__PATH__/(?!index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|oc[ms]-provider\/.+|.+\/richdocumentscode\/proxy) __PATH__/index.php$request_uri; + rewrite ^__PATH__/(?!index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|ocm-provider\/.+|.+\/richdocumentscode\/proxy) __PATH__/index.php$request_uri; fastcgi_split_path_info ^(.+?\.php)(/.*)$; set $path_info $fastcgi_path_info; @@ -120,7 +120,7 @@ location ^~ __PATH__/ { send_timeout 600; } - location ~ ^__PATH__/(?:updater|oc[ms]-provider)(?:$|/) { + location ~ ^__PATH__/(?:updater|ocm-provider)(?:$|/) { try_files $uri/ =404; index index.php; } From a7aaf2d82e5601781415691ddf41751d911ffab4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 8 Oct 2023 21:16:40 +0200 Subject: [PATCH 043/127] Update nginx.conf --- conf/nginx.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 1803b99..f2a5a47 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -92,7 +92,7 @@ location ^~ __PATH__/ { # Required for legacy support # https://github.com/nextcloud/documentation/pull/2197#issuecomment-721432337 # This line fix the ldap admin page - rewrite ^__PATH__/(?!index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|ocm-provider\/.+|.+\/richdocumentscode\/proxy) __PATH__/index.php$request_uri; + rewrite ^__PATH__/(?!index|remote|public|cron|core\/ajax\/update|status|ocs\/v[12]|updater\/.+|ocs-provider\/.+|.+\/richdocumentscode\/proxy) __PATH__/index.php$request_uri; fastcgi_split_path_info ^(.+?\.php)(/.*)$; set $path_info $fastcgi_path_info; @@ -120,7 +120,7 @@ location ^~ __PATH__/ { send_timeout 600; } - location ~ ^__PATH__/(?:updater|ocm-provider)(?:$|/) { + location ~ ^__PATH__/(?:updater|ocs-provider)(?:$|/) { try_files $uri/ =404; index index.php; } From f3d4b149c995c37340fe27ab9e9ba4c077359ea3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 8 Oct 2023 21:22:15 +0200 Subject: [PATCH 044/127] Update nginx.conf --- conf/nginx.conf | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index f2a5a47..b3d3525 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -21,18 +21,9 @@ location ^~ __PATH__/ { # Path to source alias __INSTALL_DIR__/; - # Add headers to serve security related headers - more_set_headers "Strict-Transport-Security: max-age=15768000; includeSubDomains; preload;"; - more_set_headers "Referrer-Policy: no-referrer"; - more_set_headers "X-Content-Type-Options: nosniff"; - more_set_headers "X-Download-Options: noopen"; - more_set_headers "X-Frame-Options: SAMEORIGIN"; - more_set_headers "X-Permitted-Cross-Domain-Policies: none"; - more_set_headers "X-Robots-Tag: noindex, nofollow"; - more_set_headers "X-XSS-Protection: 1; mode=block"; - # Set max upload size client_max_body_size 10G; + client_body_timeout 300s; fastcgi_buffers 64 4K; # Enable gzip but do not remove ETag headers @@ -52,6 +43,16 @@ location ^~ __PATH__/ { # for tunning hints client_body_buffer_size 512k; + # Add headers to serve security related headers + more_set_headers "Strict-Transport-Security: max-age=15768000; includeSubDomains; preload;"; + more_set_headers "Referrer-Policy: no-referrer"; + more_set_headers "X-Content-Type-Options: nosniff"; + more_set_headers "X-Download-Options: noopen"; + more_set_headers "X-Frame-Options: SAMEORIGIN"; + more_set_headers "X-Permitted-Cross-Domain-Policies: none"; + more_set_headers "X-Robots-Tag: noindex, nofollow"; + more_set_headers "X-XSS-Protection: 1; mode=block"; + # Remove X-Powered-By, which is an information leak fastcgi_hide_header X-Powered-By; From c12c87ebb0348a584a4122c07a4eff40f39e88e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 8 Oct 2023 21:23:44 +0200 Subject: [PATCH 045/127] Update nginx.conf --- conf/nginx.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index b3d3525..bdbf14f 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -12,7 +12,9 @@ location ^~ /.well-known { location = /.well-known/webfinger { return 301 __PATH__/index.php$uri; } location = /.well-known/nodeinfo { return 301 __PATH__/index.php$uri; } - try_files $uri $uri/ =404; + # Let Nextcloud's API for `/.well-known` URIs handle all other + # requests by passing them to the front-end controller. + return 301 __PATH__/index.php$request_uri; } #sub_path_only rewrite ^__PATH__$ __PATH__/ permanent; From ba9845a0a7bc6d4e7215cffce93cc0bd592178f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 10 Oct 2023 18:17:31 +0200 Subject: [PATCH 046/127] Update DESCRIPTION.md --- doc/DESCRIPTION.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/doc/DESCRIPTION.md b/doc/DESCRIPTION.md index 4a3dbc8..3d35dc4 100644 --- a/doc/DESCRIPTION.md +++ b/doc/DESCRIPTION.md @@ -2,8 +2,7 @@ Nextcloud Hub is a fully open-source on-premises content collaboration platform. ### YunoHost-specific features -In addition to Nextcloud core features, the following are made available with -this package: +In addition to Nextcloud core features, the following are made available with this package: * Integrate with YunoHost users and SSO - i.e. logout button * Allow one user to be the administrator (set at the installation) From 942cd87cbf7b0197993a9ec2ac3c652e1b200270 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 10 Oct 2023 16:17:39 +0000 Subject: [PATCH 047/127] Auto-update README --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index 36f664c..7762b18 100644 --- a/README.md +++ b/README.md @@ -20,8 +20,7 @@ Nextcloud Hub is a fully open-source on-premises content collaboration platform. ### YunoHost-specific features -In addition to Nextcloud core features, the following are made available with -this package: +In addition to Nextcloud core features, the following are made available with this package: * Integrate with YunoHost users and SSO - i.e. logout button * Allow one user to be the administrator (set at the installation) From 81e1511ed0a8ab1c8fbd54355b2c32301fe8a786 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 10 Oct 2023 23:12:49 +0200 Subject: [PATCH 048/127] add mail config --- conf/config.json | 21 ++++++++++++++++++++- manifest.toml | 1 + 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/conf/config.json b/conf/config.json index 9e1c8f0..f8253ee 100644 --- a/conf/config.json +++ b/conf/config.json @@ -13,7 +13,26 @@ }, "hashing_default_password": true, "localstorage.allowsymlinks": true, - "simpleSignUpLink.shown": false + "simpleSignUpLink.shown": false, + "hashing_default_password": true, + "localstorage.allowsymlinks": true, + "simpleSignUpLink.shown": false, + "mail_smtpmode": "smtp", + "mail_smtpport": "25", + "mail_smtpauth": 1, + "mail_smtpname": "__APP__", + "mail_smtppassword": "__MAIL_PWD__", + "mail_sendmailmode": "smtp", + "mail_from_address": "__APP__", + "mail_domain": "__DOMAIN__", + "mail_smtphost": "localhost", + "mail_smtpstreamoptions": { + "ssl": { + "allow_self_signed": true, + "verify_peer": false, + "verify_peer_name": false + } + } }, "apps": { "user_ldap": { diff --git a/manifest.toml b/manifest.toml index cf786ea..2e5d99e 100644 --- a/manifest.toml +++ b/manifest.toml @@ -53,6 +53,7 @@ ram.runtime = "512M" [resources] [resources.system_user] + allow_email = true [resources.install_dir] From 998993fdfed8be1de43a9704ff16bdebc368dcaa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 12 Oct 2023 08:25:24 +0200 Subject: [PATCH 049/127] Update restore --- scripts/restore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/restore b/scripts/restore index 27f6844..7d06588 100755 --- a/scripts/restore +++ b/scripts/restore @@ -34,7 +34,7 @@ ynh_script_progression --message="Reconfiguring PHP-FPM..." --weight=5 ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf" # Recreate a dedicated php-fpm config -ynh_add_fpm_config --usage=$fpm_usage --footprint=$fpm_footprint --phpversion=$phpversion +#ynh_add_fpm_config --usage=$fpm_usage --footprint=$fpm_footprint --phpversion=$phpversion #================================================= # RESTORE THE NGINX CONFIGURATION From b1025a7a8ac303e6e130613ff21e695aa20f31ea Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 12 Oct 2023 06:29:33 +0000 Subject: [PATCH 050/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 42ebfd6..7762b18 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.1.2~ynh2 +**Shipped version:** 27.1.2~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 3c89b6d..c198a08 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.1.2~ynh2 +**Version incluse :** 27.1.2~ynh1 **Démo :** https://demo.nextcloud.com/ From 28cc359e86652e52fee4dbc6b9000212bf4b4140 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 12 Oct 2023 18:04:27 +0200 Subject: [PATCH 051/127] Update extra_php-fpm.conf --- conf/extra_php-fpm.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/extra_php-fpm.conf b/conf/extra_php-fpm.conf index 4e9d349..feee90b 100644 --- a/conf/extra_php-fpm.conf +++ b/conf/extra_php-fpm.conf @@ -8,7 +8,7 @@ php_value[default_charset] = UTF-8 ; OPcache is already activated by default ; php_value[opcache.enable]=1 ; The following parameters are nevertheless recommended for Nextcloud -; see here: https://docs.nextcloud.com/server/15/admin_manual/installation/server_tuning.html#enable-php-opcache +; see here: https://docs.nextcloud.com/server/20/admin_manual/installation/server_tuning.html#enable-php-opcache php_value[opcache.enable_cli]=1 php_value[opcache.interned_strings_buffer]=32 php_value[opcache.max_accelerated_files]=10000 From e305738c069214afddbf4ed5fe04cdb930982752 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 12 Oct 2023 18:17:59 +0200 Subject: [PATCH 052/127] Update config.json --- conf/config.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/conf/config.json b/conf/config.json index f8253ee..0ccf288 100644 --- a/conf/config.json +++ b/conf/config.json @@ -17,6 +17,8 @@ "hashing_default_password": true, "localstorage.allowsymlinks": true, "simpleSignUpLink.shown": false, + "trashbin_retention_obligation": "auto, 30", + "versions_retention_obligation": "auto, 30", "mail_smtpmode": "smtp", "mail_smtpport": "25", "mail_smtpauth": 1, From 6b6699d09da88a7327ffca27cbfabe1d3ea4e6e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 12 Oct 2023 18:19:00 +0200 Subject: [PATCH 053/127] bump opcache.memory_consumption to 256 --- conf/extra_php-fpm.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/extra_php-fpm.conf b/conf/extra_php-fpm.conf index feee90b..5ee6f92 100644 --- a/conf/extra_php-fpm.conf +++ b/conf/extra_php-fpm.conf @@ -12,7 +12,7 @@ php_value[default_charset] = UTF-8 php_value[opcache.enable_cli]=1 php_value[opcache.interned_strings_buffer]=32 php_value[opcache.max_accelerated_files]=10000 -php_value[opcache.memory_consumption]=128 +php_value[opcache.memory_consumption]=256 php_value[opcache.save_comments]=1 php_value[opcache.revalidate_freq]=1 ; https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/caching_configuration.html#id1 From e440ab98c69cff05707c31e58f6582e46b357531 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 12 Oct 2023 19:21:38 +0200 Subject: [PATCH 054/127] Update extra_php-fpm.conf --- conf/extra_php-fpm.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/extra_php-fpm.conf b/conf/extra_php-fpm.conf index 5ee6f92..fbaff56 100644 --- a/conf/extra_php-fpm.conf +++ b/conf/extra_php-fpm.conf @@ -10,7 +10,7 @@ php_value[default_charset] = UTF-8 ; The following parameters are nevertheless recommended for Nextcloud ; see here: https://docs.nextcloud.com/server/20/admin_manual/installation/server_tuning.html#enable-php-opcache php_value[opcache.enable_cli]=1 -php_value[opcache.interned_strings_buffer]=32 +php_value[opcache.interned_strings_buffer]=64 php_value[opcache.max_accelerated_files]=10000 php_value[opcache.memory_consumption]=256 php_value[opcache.save_comments]=1 From 5fb5480446257841f4c41ee3324d11a52fe241da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 12 Oct 2023 20:04:58 +0200 Subject: [PATCH 055/127] Update nginx.conf --- conf/nginx.conf | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/conf/nginx.conf b/conf/nginx.conf index bdbf14f..4d01938 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -58,6 +58,15 @@ location ^~ __PATH__/ { # Remove X-Powered-By, which is an information leak fastcgi_hide_header X-Powered-By; + # Add .mjs as a file extension for javascript + # Either include it in the default mime.types list + # or include you can include that list explicitly and add the file extension + # only for Nextcloud like below: + include mime.types; + types { + text/javascript js mjs; + } + # Specify how to handle directories -- specifying `/nextcloud/index.php$request_uri` # here as the fallback means that Nginx always exhibits the desired behaviour # when a client requests a path that corresponds to a directory that exists From fc8ea623f46b994d8ac671f8a63632dff4139ac9 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Sat, 21 Oct 2023 19:33:14 +0000 Subject: [PATCH 056/127] Auto-update README --- README.md | 3 +-- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 17ebf97..7762b18 100644 --- a/README.md +++ b/README.md @@ -29,8 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.1.2~ynh3 - +**Shipped version:** 27.1.2~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 7da37de..c198a08 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.1.2~ynh +**Version incluse :** 27.1.2~ynh1 **Démo :** https://demo.nextcloud.com/ From fdacb1b2e7ca92cccbe6bf4a013c65e74c2cd03b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 21 Oct 2023 21:51:49 +0200 Subject: [PATCH 057/127] Update nginx.conf --- conf/nginx.conf | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 0948834..ab6f474 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -74,7 +74,7 @@ location ^~ __PATH__/ { # that file is correctly served; if it doesn't, then the request is passed to # the front-end controller. This consistent behaviour means that we don't need # to specify custom rules for certain paths (e.g. images and other assets, - # `/updater`, `/ocm-provider`, `/ocs-provider`), and thus + # `/updater`, `/ocs-provider`), and thus # `try_files $uri $uri/ /nextcloud/index.php$request_uri` # always provides the desired behaviour. index index.php index.html __PATH__/index.php$request_uri; @@ -112,13 +112,13 @@ location ^~ __PATH__/ { try_files $fastcgi_script_name =404; include fastcgi_params; - fastcgi_param SCRIPT_FILENAME $request_filename; + fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; #fastcgi_param SCRIPT_FILENAME $request_filename; fastcgi_param PATH_INFO $path_info; fastcgi_param HTTPS on; fastcgi_param modHeadersAvailable true; # Avoid sending the security headers twice fastcgi_param front_controller_active true; # Enable pretty urls - fastcgi_param HTTP_ACCEPT_ENCODING ""; # Disable encoding of nextcloud response to inject ynh scripts + fastcgi_param HTTP_ACCEPT_ENCODING ""; # Disable encoding of Nextcloud response to inject ynh scripts fastcgi_pass unix:/var/run/php/php__PHPVERSION__-fpm-__NAME__.sock; fastcgi_intercept_errors on; fastcgi_request_buffering off; @@ -137,9 +137,10 @@ location ^~ __PATH__/ { index index.php; } + # Serve static files location ~ \.(?:css|js|mjs|svg|gif|png|jpg|ico|wasm|tflite|map)$ { try_files $uri / __PATH__/index.php$request_uri; - expires 6M; # Cache-Control policy borrowed from `.htaccess` + more_set_headers "Cache-Control: public, max-age=15778463, $asset_immutable"; access_log off; # Optional: Don't log access to assets location ~ \.wasm$ { From dd4f97e44d7aba90e3c4f4920542b873f6cf28f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 21 Oct 2023 22:08:07 +0200 Subject: [PATCH 058/127] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 3d43349..afae52a 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -375,7 +375,7 @@ ynh_use_logrotate --non-append ynh_script_progression --message="Reconfiguring Fail2Ban..." --weight=7 # 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 +ynh_add_fail2ban_config --logpath="$data_dir/data/nextcloud.log" --failregex="^.*Login failed: '.*' \(Remote IP: ''.*$" --max_retry=5 #================================================= # GENERIC FINALIZATION From 8b8671d8d773a3cbb1b9cbfc1a26d5fa344fd598 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 21 Oct 2023 22:12:41 +0200 Subject: [PATCH 059/127] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index afae52a..709b3c1 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -253,7 +253,7 @@ EOF #================================================= # CONFIGURE NEXTCLOUD #================================================= - ynh_script_progression --message="Reconfiguring Nextcloud..." --weight=9 + ynh_script_progression --message="Reconfiguring $app..." --weight=9 # Verify the checksum and backup the file if it's different ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" From 5383c04b714e887324a720c46860cd1f59b7fe18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 24 Oct 2023 17:22:42 +0200 Subject: [PATCH 060/127] Update nginx.conf --- conf/nginx.conf | 9 --------- 1 file changed, 9 deletions(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index ab6f474..1bdfb42 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -58,15 +58,6 @@ location ^~ __PATH__/ { # Remove X-Powered-By, which is an information leak fastcgi_hide_header X-Powered-By; - # Add .mjs as a file extension for javascript - # Either include it in the default mime.types list - # or include you can include that list explicitly and add the file extension - # only for Nextcloud like below: - include mime.types; - types { - text/javascript js mjs; - } - # Specify how to handle directories -- specifying `/nextcloud/index.php$request_uri` # here as the fallback means that Nginx always exhibits the desired behaviour # when a client requests a path that corresponds to a directory that exists From a0864f25b0d7a35dca9244e319d6c22562b2e27c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 29 Oct 2023 18:33:02 +0100 Subject: [PATCH 061/127] Update nginx.conf --- conf/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index f1a487a..5b6db99 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -130,7 +130,7 @@ location ^~ __PATH__/ { # Serve static files location ~ \.(?:css|js|mjs|svg|gif|png|jpg|ico|wasm|tflite|map)$ { try_files $uri / __PATH__/index.php$request_uri; - more_set_headers "Cache-Control: public, max-age=15778463, $asset_immutable"; + expires 6M; # Cache-Control policy borrowed from `.htaccess` access_log off; # Optional: Don't log access to assets location ~ \.wasm$ { From 374819cb1266de62d69c824200c8aec6e47cad9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 29 Oct 2023 18:39:45 +0100 Subject: [PATCH 062/127] Update _common.sh --- scripts/_common.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 7c28468..19e6a36 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -1,7 +1,7 @@ #!/bin/bash #================================================= -# COMMON FUCTIONS +# COMMON VARIABLES #================================================= #================================================= From 1413ddf49287f8d7a3961be79846fd162e89d152 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sun, 29 Oct 2023 19:46:55 +0100 Subject: [PATCH 063/127] Update nginx.conf --- conf/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 5b6db99..6682370 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -101,7 +101,7 @@ location ^~ __PATH__/ { try_files $fastcgi_script_name =404; include fastcgi_params; - fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; #fastcgi_param SCRIPT_FILENAME $request_filename; + fastcgi_param SCRIPT_FILENAME $request_filename; fastcgi_param PATH_INFO $path_info; fastcgi_param HTTPS on; From e47de152eb18b3c8ac9fa9087fc9ded2036bd06e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 23 Nov 2023 18:12:00 +0100 Subject: [PATCH 064/127] cleaning --- scripts/install | 6 +++--- scripts/upgrade | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/scripts/install b/scripts/install index cadb410..9e4f3a2 100755 --- a/scripts/install +++ b/scripts/install @@ -117,7 +117,7 @@ exec_occ ldap:create-empty-config # Load the installation config file in Nextcloud nc_conf="$install_dir/config_install.json" -ynh_add_config --template="../conf/config_install.json" --destination="$nc_conf" +ynh_add_config --template="config_install.json" --destination="$nc_conf" exec_occ config:import "$nc_conf" @@ -126,7 +126,7 @@ ynh_secure_remove --file="$nc_conf" # Load the additional config file (used also for upgrade) nc_conf="$install_dir/config.json" -ynh_add_config --template="../conf/config.json" --destination="$nc_conf" +ynh_add_config --template="config.json" --destination="$nc_conf" exec_occ config:import "$nc_conf" @@ -211,7 +211,7 @@ ynh_store_file_checksum --file="$install_dir/config/config.php" #================================================= cron_path="/etc/cron.d/$app" -ynh_add_config --template="../conf/nextcloud.cron" --destination="$cron_path" +ynh_add_config --template="nextcloud.cron" --destination="$cron_path" chown root: "$cron_path" chmod 644 "$cron_path" diff --git a/scripts/upgrade b/scripts/upgrade index 049e719..1b41350 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -281,7 +281,7 @@ EOF ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" nc_conf="${install_dir}/config.json" - ynh_add_config --template="../conf/config.json" --destination="$nc_conf" + ynh_add_config --template="config.json" --destination="$nc_conf" # Reneable the mail app if [ $mail_app_must_be_reactived -eq 1 ]; then @@ -352,7 +352,7 @@ fi #================================================= cron_path="/etc/cron.d/$app" -ynh_add_config --template="../conf/nextcloud.cron" --destination="$cron_path" +ynh_add_config --template="nextcloud.cron" --destination="$cron_path" chown root: "$cron_path" chmod 644 "$cron_path" From 4d975cc3e2a6982bd1828d78b3c4f9cc1410b166 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Nov 2023 08:59:10 +0100 Subject: [PATCH 065/127] Update restore --- scripts/restore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/restore b/scripts/restore index 7d06588..27f6844 100755 --- a/scripts/restore +++ b/scripts/restore @@ -34,7 +34,7 @@ ynh_script_progression --message="Reconfiguring PHP-FPM..." --weight=5 ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf" # Recreate a dedicated php-fpm config -#ynh_add_fpm_config --usage=$fpm_usage --footprint=$fpm_footprint --phpversion=$phpversion +ynh_add_fpm_config --usage=$fpm_usage --footprint=$fpm_footprint --phpversion=$phpversion #================================================= # RESTORE THE NGINX CONFIGURATION From d687230c664ae9da86b6f93bf636e3cdcbdcf53e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 24 Nov 2023 08:59:59 +0100 Subject: [PATCH 066/127] Update extra_php-fpm.conf --- conf/extra_php-fpm.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conf/extra_php-fpm.conf b/conf/extra_php-fpm.conf index fbaff56..feee90b 100644 --- a/conf/extra_php-fpm.conf +++ b/conf/extra_php-fpm.conf @@ -10,9 +10,9 @@ php_value[default_charset] = UTF-8 ; The following parameters are nevertheless recommended for Nextcloud ; see here: https://docs.nextcloud.com/server/20/admin_manual/installation/server_tuning.html#enable-php-opcache php_value[opcache.enable_cli]=1 -php_value[opcache.interned_strings_buffer]=64 +php_value[opcache.interned_strings_buffer]=32 php_value[opcache.max_accelerated_files]=10000 -php_value[opcache.memory_consumption]=256 +php_value[opcache.memory_consumption]=128 php_value[opcache.save_comments]=1 php_value[opcache.revalidate_freq]=1 ; https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/caching_configuration.html#id1 From 79e4cdf4012d663f77e0d99bd58755600f61ef52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 30 Nov 2023 12:54:22 +0100 Subject: [PATCH 067/127] fix --- scripts/install | 2 +- scripts/upgrade | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/install b/scripts/install index 9e4f3a2..745d4e0 100755 --- a/scripts/install +++ b/scripts/install @@ -186,7 +186,7 @@ exec_occ config:system:get logout_url >/dev/null 2>&1 \ # CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS #================================================= -exec_occ config:system:set overwrite.cli.url --value="https://${domain}" +exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" #================================================= # REMOVE THE TEMPORARY ADMIN AND SET THE TRUE ONE diff --git a/scripts/upgrade b/scripts/upgrade index 6a14bcc..e6fb9ab 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -326,7 +326,7 @@ EOF # CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS #================================================= - exec_occ config:system:set overwrite.cli.url --value="https://${domain}" + exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" #================================================= # MOUNT HOME FOLDERS AS EXTERNAL STORAGE From 03d7960b7c064a9fa6fd7469c0937b99d9629de9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 12 Dec 2023 23:44:39 +0100 Subject: [PATCH 068/127] fix --- manifest.toml | 2 +- scripts/upgrade.d/upgrade.27.sh | 7 +++++++ scripts/upgrade.d/upgrade.last.sh | 4 ++-- 3 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 scripts/upgrade.d/upgrade.27.sh diff --git a/manifest.toml b/manifest.toml index 4110e9f..c06bb93 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "27.1.4~ynh1" +version = "28.0.0~ynh1" maintainers = ["kay0u"] diff --git a/scripts/upgrade.d/upgrade.27.sh b/scripts/upgrade.d/upgrade.27.sh new file mode 100644 index 0000000..3716a7f --- /dev/null +++ b/scripts/upgrade.d/upgrade.27.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +# Last available Nextcloud version +next_version="28.0.0" + +# Nextcloud tarball checksum sha256 +nextcloud_source_sha256="4e8b0b74b40221e85f92ab869d0873c69a52d7e43889d9259c6259428a6a36f2" diff --git a/scripts/upgrade.d/upgrade.last.sh b/scripts/upgrade.d/upgrade.last.sh index b31e5b5..3716a7f 100644 --- 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="27.1.4" +next_version="28.0.0" # Nextcloud tarball checksum sha256 -nextcloud_source_sha256="bec65f2166b82c9303baf476c1e424f71aa196dad010ffe4c0c39d03990d594c" +nextcloud_source_sha256="4e8b0b74b40221e85f92ab869d0873c69a52d7e43889d9259c6259428a6a36f2" From 1ab867a7b4dec671095172bedc7f70b791bfbbdb Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 12 Dec 2023 22:44:44 +0000 Subject: [PATCH 069/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index abbfd57..73b3afe 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 27.1.4~ynh1 +**Shipped version:** 28.0.0~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index f4fdfaa..dc3c8b6 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 27.1.4~ynh1 +**Version incluse :** 28.0.0~ynh1 **Démo :** https://demo.nextcloud.com/ From 98d24a9930c2b9297b72ffde8587afc14c630f9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 10 Jan 2024 14:00:09 +0100 Subject: [PATCH 070/127] add psql pwd --- scripts/upgrade | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 86f5951..9f8ab84 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -74,7 +74,8 @@ then ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" ynh_psql_test_if_first_run - ynh_psql_setup_db --db_user=$db_user --db_name=$db_name + ynh_psql_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$(ynh_string_random) + ynh_app_setting_set --app=$app --key=psqlpwd --value=$db_pwd exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n From 92ca88779ab8c102603090c1cce18f9cff77bf98 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 10 Jan 2024 14:08:31 +0100 Subject: [PATCH 071/127] cleaning --- scripts/restore | 2 +- scripts/upgrade | 34 ++++++++++++++++++++-------------- 2 files changed, 21 insertions(+), 15 deletions(-) diff --git a/scripts/restore b/scripts/restore index f4ce619..ae15393 100755 --- a/scripts/restore +++ b/scripts/restore @@ -27,7 +27,7 @@ ynh_script_progression --message="Reconfiguring PHP-FPM..." --weight=5 # Restore the file first, so it can have a backup if different ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf" -# Recreate a dedicated php-fpm config +# Recreate a dedicated PHP-FPM config ynh_add_fpm_config #================================================= diff --git a/scripts/upgrade b/scripts/upgrade index 9f8ab84..3b285da 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -63,13 +63,14 @@ exec_occ() { } #================================================= -# HANDLE DATABASE MIGRATION +# HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= mysql_db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd) + if [ -n "$mysql_db_pwd" ] then - ynh_script_progression --message="Migrating to PostgreSQL database..." + ynh_script_progression --message="Migrating to PostgreSQL database..." --weight=3 ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" @@ -85,6 +86,10 @@ then ynh_store_file_checksum --file="${install_dir}/config/config.php" fi +#================================================= +# DOWNLOAD, CHECK AND UNPACK SOURCE +#================================================= + # Define a function to add an external storage # Create the external storage for the given folders and enable sharing create_external_storage() { @@ -97,7 +102,6 @@ local mount_id=$(exec_occ files_external:create --output=json \ || exec_occ files_external:option "$mount_id" enable_sharing true } - if [ "$upgrade_type" == "UPGRADE_APP" ] then ynh_script_progression --message="Upgrading Nextcloud..." --weight=3 @@ -290,7 +294,7 @@ EOF fi #================================================= -# REGEN SYSTEM CONFIGURATIONS +# REGEN PERMISSIONS #================================================= ynh_script_progression --message="Reapplying file permissions..." --weight=2 @@ -310,15 +314,15 @@ chmod 750 $install_dir #================================================= ynh_script_progression --message="Regenerating system configurations for $app..." --weight=2 -# ------- +#------------------------------------------------- # PHP-FPM -# ------- +#------------------------------------------------- ynh_add_fpm_config -# ------- +#------------------------------------------------- # NGINX -# ------- +#------------------------------------------------- # Delete current NGINX configuration to be able to check if .well-known is already served. ynh_backup_if_checksum_is_different --file="/etc/nginx/conf.d/$domain.d/$app.conf" @@ -340,9 +344,10 @@ fi # Create a dedicated NGINX config ynh_add_nginx_config -# ------- +#------------------------------------------------- # CRON JOB -# ------- +#------------------------------------------------- + cron_path="/etc/cron.d/$app" ynh_add_config --template="../conf/nextcloud.cron" --destination="$cron_path" chown root: "$cron_path" @@ -350,14 +355,15 @@ chmod 644 "$cron_path" exec_occ background:cron -# ------- +#------------------------------------------------- # LOGROTATE -# ------- +#------------------------------------------------- + ynh_use_logrotate --non-append -# ------- +#------------------------------------------------- # FAIL2BAN -# ------- +#------------------------------------------------- # Create a dedicated Fail2Ban config ynh_add_fail2ban_config --logpath="$data_dir/data/nextcloud.log" --failregex="^.*Login failed: '.*' \(Remote IP: ''.*$" --max_retry=5 From cb57f51e104d932143585dda6e032297f2e26286 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 10 Jan 2024 14:47:57 +0100 Subject: [PATCH 072/127] Update config.json --- conf/config.json | 1 + 1 file changed, 1 insertion(+) diff --git a/conf/config.json b/conf/config.json index 1cd7f95..bbe9eed 100644 --- a/conf/config.json +++ b/conf/config.json @@ -14,6 +14,7 @@ "hashing_default_password": true, "localstorage.allowsymlinks": true, "simpleSignUpLink.shown": false, + "default_phone_region": "", "mail_smtpmode": "smtp", "mail_smtpport": "25", "mail_smtpauth": 1, From 5c1f0576372257f403d7f4ed463da5f440691051 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 10 Jan 2024 15:09:53 +0100 Subject: [PATCH 073/127] Update upgrade --- scripts/upgrade | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 3b285da..f3f8742 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -72,18 +72,18 @@ if [ -n "$mysql_db_pwd" ] then ynh_script_progression --message="Migrating to PostgreSQL database..." --weight=3 - ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" + #ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" ynh_psql_test_if_first_run - ynh_psql_setup_db --db_user=$db_user --db_name=$db_name --db_pwd=$(ynh_string_random) - ynh_app_setting_set --app=$app --key=psqlpwd --value=$db_pwd + ynh_psql_setup_db --db_user=$db_user --db_name=$db_name #--db_pwd=$(ynh_string_random) + #ynh_app_setting_set --app=$app --key=psqlpwd --value=$db_pwd exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name ynh_app_setting_delete --app=$app --key=mysqlpwd - ynh_store_file_checksum --file="${install_dir}/config/config.php" + #ynh_store_file_checksum --file="${install_dir}/config/config.php" fi #================================================= From e32aaf6ce9c1e6216d252201aed802349c5e26d5 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Wed, 10 Jan 2024 19:02:36 +0100 Subject: [PATCH 074/127] Update manifest.toml: bump version to have a version reference corresponding to the mysql->postgresql transition --- manifest.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index ce1c889..e21272d 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "28.0.1~ynh1" +version = "28.0.1~ynh2" maintainers = ["kay0u"] @@ -77,4 +77,4 @@ ram.runtime = "512M" [resources.database] type = "postgresql" - \ No newline at end of file + From ce61682761e25227b99f2306a64f8bd200767ece Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Wed, 10 Jan 2024 18:02:41 +0000 Subject: [PATCH 075/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 5b8a14b..b463ddc 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 28.0.1~ynh1 +**Shipped version:** 28.0.1~ynh2 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 8b6334c..01f21b0 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 28.0.1~ynh1 +**Version incluse :** 28.0.1~ynh2 **Démo :** https://demo.nextcloud.com/ From e724e9820702a09130b77c7cead584909372ed8f Mon Sep 17 00:00:00 2001 From: eric_G <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 10 Jan 2024 19:33:45 +0100 Subject: [PATCH 076/127] Update scripts/upgrade Co-authored-by: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> --- scripts/upgrade | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index f3f8742..79a1fb1 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -66,24 +66,25 @@ exec_occ() { # HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= -mysql_db_pwd=$(ynh_app_setting_get --app=$app --key=mysqlpwd) - -if [ -n "$mysql_db_pwd" ] +# If we're moving through version 28.0.1~ynh2 (in which the switch to psql is made) +if ynh_compare_current_package_version --comparison lt --version 28.0.1~ynh2 then - ynh_script_progression --message="Migrating to PostgreSQL database..." --weight=3 - - #ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" - - ynh_psql_test_if_first_run - ynh_psql_setup_db --db_user=$db_user --db_name=$db_name #--db_pwd=$(ynh_string_random) - #ynh_app_setting_set --app=$app --key=psqlpwd --value=$db_pwd - - exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n - - ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name - ynh_app_setting_delete --app=$app --key=mysqlpwd - - #ynh_store_file_checksum --file="${install_dir}/config/config.php" + # Double-check the mysql DB is here + if ! mysql -e "USE $db_name" 2>/dev/null + then + ynh_warn "Uhoh? The Nextcloud mysql DB doesn't exist ? We are supposed to move it to postgresql ... Maybe it was already migrated ?" + # Double check the psql is not empty, otherwise big whoops ? + if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] + then + ynh_warn "Apparently the postgresql DB is not empty, so this is probably OK?" + else + ynh_die "Apparently the postgresql DB is also empty, this is kind of worrying, what happened?!" + fi + else + ynh_script_info --message="Migrating to PostgreSQL database..." --weight=3 + exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n + ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name + fi fi #================================================= From 5149bcbee4918e6335a7103b7d0f9a5c02d80a9e Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Wed, 10 Jan 2024 20:46:38 +0100 Subject: [PATCH 077/127] Update upgrade: grompf --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 79a1fb1..43b9753 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -81,7 +81,7 @@ then ynh_die "Apparently the postgresql DB is also empty, this is kind of worrying, what happened?!" fi else - ynh_script_info --message="Migrating to PostgreSQL database..." --weight=3 + ynh_print_info --message="Migrating to PostgreSQL database..." --weight=3 exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name fi From 1827a8584a276e8756e8819562c5cd35937661e1 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Wed, 10 Jan 2024 21:49:10 +0100 Subject: [PATCH 078/127] Update upgrade: aaaaaa --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 43b9753..2df173b 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -81,7 +81,7 @@ then ynh_die "Apparently the postgresql DB is also empty, this is kind of worrying, what happened?!" fi else - ynh_print_info --message="Migrating to PostgreSQL database..." --weight=3 + ynh_print_info --message="Migrating to PostgreSQL database..." exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name fi From 6ebebe88a60ff84ee5f0ae65e84841bf836cb9ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 11 Jan 2024 18:59:45 +0100 Subject: [PATCH 079/127] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index e21272d..19bc532 100644 --- a/manifest.toml +++ b/manifest.toml @@ -73,7 +73,7 @@ ram.runtime = "512M" api.allowed = ["visitors", "all_users"] [resources.apt] - packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.2-pgsql, php8.2-fpm, php8.2-bz2, php8.2-imap, php8.2-gmp, php8.2-gd, php8.2-intl, php8.2-curl, php8.2-apcu, php8.2-redis, php8.2-ldap, php8.2-imagick, php8.2-zip, php8.2-mbstring, php8.2-xml, php8.2-igbinary, php8.2-bcmath" + packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.2-pgsql, php8.2-mysql, php8.2-fpm, php8.2-bz2, php8.2-imap, php8.2-gmp, php8.2-gd, php8.2-intl, php8.2-curl, php8.2-apcu, php8.2-redis, php8.2-ldap, php8.2-imagick, php8.2-zip, php8.2-mbstring, php8.2-xml, php8.2-igbinary, php8.2-bcmath" [resources.database] type = "postgresql" From ab68a3a2eb7dc5272415c6ca3178832ee5cd7656 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 11 Jan 2024 20:26:10 +0100 Subject: [PATCH 080/127] Update upgrade --- scripts/upgrade | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 2df173b..90047ff 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -69,20 +69,20 @@ exec_occ() { # If we're moving through version 28.0.1~ynh2 (in which the switch to psql is made) if ynh_compare_current_package_version --comparison lt --version 28.0.1~ynh2 then - # Double-check the mysql DB is here + # Double-check the MySQL DB is here if ! mysql -e "USE $db_name" 2>/dev/null then - ynh_warn "Uhoh? The Nextcloud mysql DB doesn't exist ? We are supposed to move it to postgresql ... Maybe it was already migrated ?" - # Double check the psql is not empty, otherwise big whoops ? + ynh_warn "Uhoh? The Nextcloud MySQL DB doesn't exist? We are supposed to move it to PostgreSQL... Maybe it was already migrated?" + # Double check the psql is not empty, otherwise big whoops? if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] then - ynh_warn "Apparently the postgresql DB is not empty, so this is probably OK?" + ynh_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" else - ynh_die "Apparently the postgresql DB is also empty, this is kind of worrying, what happened?!" + ynh_die "Apparently the PostgreSQL DB is also empty, this is kind of worrying, what happened?!" fi else ynh_print_info --message="Migrating to PostgreSQL database..." - exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n + ynh_exec_warn_less exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name fi fi From d7568ca230cf4109ad00e9e66d9ab779159b66d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 11 Jan 2024 21:49:47 +0100 Subject: [PATCH 081/127] cleaning --- scripts/change_url | 2 +- scripts/install | 2 +- scripts/remove | 2 +- scripts/restore | 2 +- scripts/upgrade | 7 +++---- tests.toml | 1 + 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/scripts/change_url b/scripts/change_url index 4ba48b3..dbcbc60 100644 --- a/scripts/change_url +++ b/scripts/change_url @@ -52,7 +52,7 @@ fi #================================================= # SETUP SSOWAT #================================================= -ynh_script_progression --message="Configuring permissions..." +ynh_script_progression --message="Configuring permissions..." --weight=1 # Temporary fix for the API permission ynh_permission_url --permission="api" --url="re:$new_domain\/.well-known\/.*" --auth_header="false" --clear_urls diff --git a/scripts/install b/scripts/install index e662aa2..39ca4a2 100755 --- a/scripts/install +++ b/scripts/install @@ -80,7 +80,7 @@ exec_occ maintenance:install \ --database-user $db_user --database-pass "$db_pwd" \ --admin-user "admin" --admin-pass "$admin_password" \ --data-dir "$data_dir/data" \ - || ynh_die --message="Unable to install Nextcloud" + || ynh_die --message="Unable to install $app" #================================================= # CONFIGURE NEXTCLOUD diff --git a/scripts/remove b/scripts/remove index c39ac68..a0f4ba6 100755 --- a/scripts/remove +++ b/scripts/remove @@ -8,7 +8,7 @@ source /usr/share/yunohost/helpers #================================================= # REMOVE SYSTEMD SERVICE #================================================= -ynh_script_progression --message="Removing system configurations related to $app..." --weight=5 +ynh_script_progression --message="Removing system configurations related to $app..." --weight=10 # Remove the dedicated NGINX config ynh_remove_nginx_config diff --git a/scripts/restore b/scripts/restore index ae15393..13d2fe6 100755 --- a/scripts/restore +++ b/scripts/restore @@ -121,7 +121,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..." --weight=3 ynh_systemd_action --service_name=nginx --action=reload diff --git a/scripts/upgrade b/scripts/upgrade index 90047ff..c401281 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -105,7 +105,7 @@ local mount_id=$(exec_occ files_external:create --output=json \ if [ "$upgrade_type" == "UPGRADE_APP" ] then - ynh_script_progression --message="Upgrading Nextcloud..." --weight=3 + ynh_script_progression --message="Upgrading $app..." --weight=3 # Load the last available version source upgrade.d/upgrade.last.sh @@ -146,7 +146,6 @@ then # 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. 20.0.0 is the latest version) if [[ ("$last_major_version" -eq "$current_major_version") || ( ("$last_major_version" -eq "$((current_major_version+1))") && ("$next_version" == "$last_version") ) ]]; then current_major_version=last # Enable YunoHost patches on Nextcloud sources @@ -156,7 +155,7 @@ then # Load the value for this version source upgrade.d/upgrade.$current_major_version.sh - ynh_print_info --message="Upgrade to Nextcloud $next_version" + ynh_print_info --message="Upgrade to $app $next_version" # Create an app.src for this version of Nextcloud cat > ../conf/app.src << EOF @@ -204,7 +203,7 @@ EOF # Upgrade Nextcloud (SUCCESS = 0, UP_TO_DATE = 3) exec_occ maintenance:mode --off exec_occ upgrade \ - || [ $? -eq 3 ] || ynh_die --message="Unable to upgrade Nextcloud" + || [ $? -eq 3 ] || ynh_die --message="Unable to upgrade $app" # Get the new current version number current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) diff --git a/tests.toml b/tests.toml index 10c825b..bc75dbb 100644 --- a/tests.toml +++ b/tests.toml @@ -9,3 +9,4 @@ test_format = 1.0 test_upgrade_from.c5cf91ad.name = "Upgrade from 25.0.2" test_upgrade_from.caf917f3.name = "Upgrade from 26.0.2" test_upgrade_from.9c6d1eea.name = "Upgrade from 27.1.4" + test_upgrade_from.3e60bacf.name = "Upgrade from 28.0.1" From 4e9a1aa1a8217c5b7494cad6e7ec26ca93d453e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 11 Jan 2024 22:26:46 +0100 Subject: [PATCH 082/127] Create PRE_UPGRADE.md --- doc/PRE_UPGRADE.md | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 doc/PRE_UPGRADE.md diff --git a/doc/PRE_UPGRADE.md b/doc/PRE_UPGRADE.md new file mode 100644 index 0000000..6b46d5b --- /dev/null +++ b/doc/PRE_UPGRADE.md @@ -0,0 +1,2 @@ +#FIX this pre_upgrade notification/migration/warning +Starting in Nextcloud 28.0.1~ynh2, we are deprecating support for MariaDB. We are moving from MariaDB to PostgreSQL database. \ No newline at end of file From 7394835d4c0528974714ef86bc3531fa787d550e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 11 Jan 2024 22:27:13 +0100 Subject: [PATCH 083/127] Update PRE_UPGRADE.md --- doc/PRE_UPGRADE.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/PRE_UPGRADE.md b/doc/PRE_UPGRADE.md index 6b46d5b..dd91f95 100644 --- a/doc/PRE_UPGRADE.md +++ b/doc/PRE_UPGRADE.md @@ -1,2 +1,2 @@ #FIX this pre_upgrade notification/migration/warning -Starting in Nextcloud 28.0.1~ynh2, we are deprecating support for MariaDB. We are moving from MariaDB to PostgreSQL database. \ No newline at end of file +Starting in Nextcloud 28.0.1~ynh2, we are deprecating support for MariaDB. We are moving from MariaDB to PostgreSQL database. From c39600e756f190ab734876871e804900e14096c8 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Fri, 12 Jan 2024 07:15:43 +0100 Subject: [PATCH 084/127] Update upgrade --- scripts/upgrade | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index c401281..97b2a23 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -72,11 +72,11 @@ then # Double-check the MySQL DB is here if ! mysql -e "USE $db_name" 2>/dev/null then - ynh_warn "Uhoh? The Nextcloud MySQL DB doesn't exist? We are supposed to move it to PostgreSQL... Maybe it was already migrated?" + ynh_print_warn "Uhoh? The Nextcloud MySQL DB doesn't exist? We are supposed to move it to PostgreSQL... Maybe it was already migrated?" # Double check the psql is not empty, otherwise big whoops? if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] then - ynh_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" + ynh_print_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" else ynh_die "Apparently the PostgreSQL DB is also empty, this is kind of worrying, what happened?!" fi From 06eefbab6ffb0a35f5eb57610e9d14bb026fabfd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 12 Jan 2024 17:25:32 +0100 Subject: [PATCH 085/127] fix --- doc/ADMIN.md | 2 +- doc/ADMIN_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/ADMIN.md b/doc/ADMIN.md index e9b7da8..8d401d2 100644 --- a/doc/ADMIN.md +++ b/doc/ADMIN.md @@ -3,7 +3,7 @@ You can run Nextcloud commands from the command line using: ``` -sudo -u __APP__ php__YNH_PHP_VERSION__ --define apc.enable_cli=1 __INSTALL_DIR__/occ ... +sudo -u __APP__ php__PHPVERSION__ --define apc.enable_cli=1 __INSTALL_DIR__/occ ... ``` Alternatively, you may open a 'Nextcloud shell' with `sudo yunohost app shell __APP__`, then run `php occ ...` diff --git a/doc/ADMIN_fr.md b/doc/ADMIN_fr.md index 85445bd..06b76b1 100644 --- a/doc/ADMIN_fr.md +++ b/doc/ADMIN_fr.md @@ -3,7 +3,7 @@ Vous pouvez lancer des commandes Nextcloud depuis la ligne de commande avec: ``` -sudo -u __APP__ php__YNH_PHP_VERSION__ --define apc.enable_cli=1 __INSTALL_DIR__/occ ... +sudo -u __APP__ php__PHPVERSION__ --define apc.enable_cli=1 __INSTALL_DIR__/occ ... ``` Ou bien, vous pouvez ouvrir un "shell Nextcloud" avec `sudo yunohost app shell __APP__`, puis lancer `php occ ...` From 5d991034de7bf4267dfb7eda8869e6bc217faed8 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin <4533074+alexAubin@users.noreply.github.com> Date: Tue, 16 Jan 2024 02:09:32 +0100 Subject: [PATCH 086/127] Update upgrade: fix check that postgresql is empty during mysql->psql migration --- scripts/upgrade | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index b008d8d..b86b4a6 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -76,9 +76,9 @@ then # Double check the psql is not empty, otherwise big whoops? if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] then - ynh_print_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" - else ynh_die "Apparently the PostgreSQL DB is also empty, this is kind of worrying, what happened?!" + else + ynh_print_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" fi else ynh_print_info --message="Migrating to PostgreSQL database..." From dc77d76d26ed54d7faa21b1bfa4b53868ac9bc64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 26 Jan 2024 20:36:33 +0100 Subject: [PATCH 087/127] Update upgrade --- scripts/upgrade | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 26764e6..2a98cca 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -24,7 +24,6 @@ then ynh_die --message="Upgrading from Nextcloud < 22.2 is not supported anymore. You should first upgrade to 22.2 using: yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/41f5f902e7c7cd3c30a6793020562ba98b9bf3e9" fi - #================================================= # SPECIFIC UPGRADE #================================================= From 61bc1ff066bba7c7d97ad36a08e1a952f91ee8dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 26 Jan 2024 20:39:36 +0100 Subject: [PATCH 088/127] Update upgrade --- scripts/upgrade | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 2a98cca..d1e37fa 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -39,6 +39,9 @@ filter_boring_occ_warnings() { sed -E 's@\s*([0-9]+\/[0-9]+\s+\[(-|>|=)+\]\s+[0-9]+%|\s*Starting ...|Nextcloud or one of the apps require upgrade - only a limited number of commands are available|You may use your browser or the occ upgrade command to do the upgrade)@@g' } +current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) +current_major_version=${current_version%%.*} + # Define a function to execute commands with `occ` exec_occ() { # Backward compatibility to upgrade from older versions @@ -133,9 +136,6 @@ function list_installed_apps_not_compatible_with_future_version() } -current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) -current_major_version=${current_version%%.*} - last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9]') last_major_version=${last_version%%.*} From 4a83c2b8480ee68ed2b367a669ea6502ab30225e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 1 Feb 2024 12:09:27 +0100 Subject: [PATCH 089/127] Update manifest.toml --- manifest.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index 75221be..a875c86 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "28.0.1~ynh2" +version = "28.0.2~ynh1" maintainers = ["kay0u"] @@ -59,8 +59,8 @@ ram.runtime = "512M" [resources.sources] [resources.sources.main] - url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.1.tar.bz2' - sha256 = '2f80735b443082272fe6a3b5e32137957f1fc448c75342b94b5200b29725f3a4' + url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.2.tar.bz2' + sha256 = 'de34d6baf3ecceacfdd138e85520cd85e1d2ce6798d9ffa478ac17eb1efa1d08' [resources.sources.27] url = 'https://download.nextcloud.com/server/releases/nextcloud-27.0.0.tar.bz2' From c67899f5ea6ada1bc72048d72947a4603171b31e Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 1 Feb 2024 11:09:33 +0000 Subject: [PATCH 090/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index b463ddc..8d429f4 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 28.0.1~ynh2 +**Shipped version:** 28.0.2~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 01f21b0..daedd3d 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 28.0.1~ynh2 +**Version incluse :** 28.0.2~ynh1 **Démo :** https://demo.nextcloud.com/ From 37fe56f6afbcb6f01b41370c3e417da2a465edfc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 1 Feb 2024 12:25:06 +0100 Subject: [PATCH 091/127] Update config.json --- conf/config.json | 1 + 1 file changed, 1 insertion(+) diff --git a/conf/config.json b/conf/config.json index bbe9eed..a316b24 100644 --- a/conf/config.json +++ b/conf/config.json @@ -15,6 +15,7 @@ "localstorage.allowsymlinks": true, "simpleSignUpLink.shown": false, "default_phone_region": "", + "maintenance_window_start": 1, "mail_smtpmode": "smtp", "mail_smtpport": "25", "mail_smtpauth": 1, From 8aab6f76c2fd838e2940919518652b4b3039c7de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 1 Feb 2024 13:35:32 +0100 Subject: [PATCH 092/127] Update upgrade --- scripts/upgrade | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index d1e37fa..93d146c 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -75,8 +75,8 @@ exec_occ() { # HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= -# If we're moving through version 28.0.1~ynh2 (in which the switch to psql is made) -if ynh_compare_current_package_version --comparison lt --version 28.0.1~ynh2 +# If we're moving through version 28.0.2~ynh1 (in which the switch to psql is made) +if ynh_compare_current_package_version --comparison lt --version 28.0.2~ynh1 then # Double-check the MySQL DB is here if ! mysql -e "USE $db_name" 2>/dev/null From 29fc438f1868ca9cf81f4603a37b785922f2c8ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 1 Feb 2024 13:40:52 +0100 Subject: [PATCH 093/127] Update upgrade --- scripts/upgrade | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 93d146c..9022751 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -75,8 +75,8 @@ exec_occ() { # HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= -# If we're moving through version 28.0.2~ynh1 (in which the switch to psql is made) -if ynh_compare_current_package_version --comparison lt --version 28.0.2~ynh1 +# If we're moving through version 28.0.1~ynh1 (in which the switch to psql is made) +if ynh_compare_current_package_version --comparison lt --version 28.0.1~ynh1 then # Double-check the MySQL DB is here if ! mysql -e "USE $db_name" 2>/dev/null From 8912fbef1fafb5e4c0bc19e53c288d1e3cf40f41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 1 Feb 2024 13:42:55 +0100 Subject: [PATCH 094/127] Update upgrade --- scripts/upgrade | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 9022751..cc4a197 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -75,8 +75,8 @@ exec_occ() { # HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= -# If we're moving through version 28.0.1~ynh1 (in which the switch to psql is made) -if ynh_compare_current_package_version --comparison lt --version 28.0.1~ynh1 +# If we're moving through version 28.0.2~ynh1 (in which the switch to psql is made) +if ynh_compare_current_package_version --comparison lt --version 28.0.2~ynh2 then # Double-check the MySQL DB is here if ! mysql -e "USE $db_name" 2>/dev/null From e9d9b28238166c6ba6c31ba9e9afac38cb1e03f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 3 Feb 2024 17:14:57 +0100 Subject: [PATCH 095/127] Update nginx.conf --- conf/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 9487ac2..7a9340e 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -55,7 +55,7 @@ location ^~ __PATH__/ { client_body_buffer_size 512k; # HTTP response headers borrowed from Nextcloud `.htaccess` - more_set_headers "Strict-Transport-Security: max-age=15768000; includeSubDomains; preload;"; + #more_set_headers "Strict-Transport-Security: max-age=15768000; includeSubDomains; preload;"; more_set_headers "Referrer-Policy: no-referrer"; more_set_headers "X-Content-Type-Options: nosniff"; more_set_headers "X-Download-Options: noopen"; From 98c13e0db81a47e9fdd0b1de0cb0ac99cff51df3 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Wed, 21 Feb 2024 12:20:10 +0000 Subject: [PATCH 096/127] Auto-update README --- README.md | 4 ++-- README_fr.md | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 318910a..df111f2 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ @@ -58,4 +58,4 @@ or sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug ``` -**More info regarding app packaging:** +**More info regarding app packaging:** \ No newline at end of file diff --git a/README_fr.md b/README_fr.md index 1f9ad1d..3a99357 100644 --- a/README_fr.md +++ b/README_fr.md @@ -1,5 +1,5 @@ From ef5b058676e971d256eab606cc354ba8f1d0ba1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 29 Feb 2024 16:44:15 +0100 Subject: [PATCH 097/127] Update manifest.toml --- manifest.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index 3db25ed..72c4f90 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "28.0.2~ynh2" +version = "28.0.3~ynh1" maintainers = ["kay0u"] @@ -59,8 +59,8 @@ ram.runtime = "512M" [resources.sources] [resources.sources.main] - url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.2.tar.bz2' - sha256 = 'de34d6baf3ecceacfdd138e85520cd85e1d2ce6798d9ffa478ac17eb1efa1d08' + url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.3.tar.bz2' + sha256 = '9ed413c0de16f5b033ceeffcca99c0d61fc698dbeb8db851ac9adf9eef951906' [resources.sources.27] url = 'https://download.nextcloud.com/server/releases/nextcloud-27.0.0.tar.bz2' From 91b1e7f7c487e67c52e3bbcea56bb7ae70386bf4 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 29 Feb 2024 15:44:20 +0000 Subject: [PATCH 098/127] Auto-update README --- README.md | 2 +- README_fr.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index df111f2..8d063f1 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 28.0.2~ynh2 +**Shipped version:** 28.0.3~ynh1 **Demo:** https://demo.nextcloud.com/ diff --git a/README_fr.md b/README_fr.md index 3a99357..f2e1700 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 28.0.2~ynh2 +**Version incluse :** 28.0.3~ynh1 **Démo :** https://demo.nextcloud.com/ From d0645b93a7d3655d89b8dd9110bffd147c433e57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 28 Mar 2024 11:32:55 +0100 Subject: [PATCH 099/127] Update manifest.toml --- manifest.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index f97ec22..dd40b4d 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "28.0.3~ynh3" +version = "28.0.4~ynh1" maintainers = ["kay0u"] @@ -59,8 +59,8 @@ ram.runtime = "512M" [resources.sources] [resources.sources.main] - url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.3.tar.bz2' - sha256 = '9ed413c0de16f5b033ceeffcca99c0d61fc698dbeb8db851ac9adf9eef951906' + url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.4.tar.bz2' + sha256 = '9bfecee1e12fba48c49e9a71caa81c4ba10b2884787fab75d64ccfd122a13019' [resources.sources.27] url = 'https://download.nextcloud.com/server/releases/nextcloud-27.0.0.tar.bz2' From b40d07987c7fb8ea0a1b0048ed3acfb55981ba6d Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 28 Mar 2024 10:33:02 +0000 Subject: [PATCH 100/127] Auto-update READMEs --- ALL_README.md | 6 +++++ README.md | 17 +++++++------- README_fr.md | 35 +++++++++++++++-------------- README_gl.md | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++ README_it.md | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 155 insertions(+), 25 deletions(-) create mode 100644 ALL_README.md create mode 100644 README_gl.md create mode 100644 README_it.md diff --git a/ALL_README.md b/ALL_README.md new file mode 100644 index 0000000..3d6c579 --- /dev/null +++ b/ALL_README.md @@ -0,0 +1,6 @@ +# All available README files by language + +- [Read the README in English](README.md) +- [Lire le README en français](README_fr.md) +- [Le o README en galego](README_gl.md) +- [Leggi il “README” in italiano](README_it.md) diff --git a/README.md b/README.md index 7b12d86..933eeb7 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ @@ -9,10 +9,10 @@ It shall NOT be edited by hand. [![Install Nextcloud with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) -*[Lire ce readme en français.](./README_fr.md)* +*[Read this README is other languages.](./ALL_README.md)* -> *This package allows you to install Nextcloud quickly and simply on a YunoHost server. -If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/install) to learn how to install it.* +> *This package allows you to install Nextcloud quickly and simply on a YunoHost server.* +> *If you don't have YunoHost, please consult [the guide](https://yunohost.org/install) to learn how to install it.* ## Overview @@ -28,7 +28,8 @@ In addition to Nextcloud core features, the following are made available with th * Optionally access the user home folder from Nextcloud files (set at the installation, the sharing is enabled by default) * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 28.0.3~ynh2 + +**Shipped version:** 28.0.4~ynh1 **Demo:** @@ -47,11 +48,11 @@ In addition to Nextcloud core features, the following are made available with th ## Developer info -Please send your pull request to the [testing branch](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). +Please send your pull request to the [`testing` branch](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). -To try the testing branch, please proceed like that. +To try the `testing` branch, please proceed like that: -``` bash +```bash sudo yunohost app install https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug or sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug diff --git a/README_fr.md b/README_fr.md index 1457f98..a89996e 100644 --- a/README_fr.md +++ b/README_fr.md @@ -1,6 +1,6 @@ # Nextcloud pour YunoHost @@ -9,10 +9,10 @@ It shall NOT be edited by hand. [![Installer Nextcloud avec YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) -*[Read this readme in english.](./README.md)* +*[Lire le README dans d'autres langues.](./ALL_README.md)* -> *Ce package vous permet d’installer Nextcloud rapidement et simplement sur un serveur YunoHost. -Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour savoir comment l’installer et en profiter.* +> *Ce package vous permet d’installer Nextcloud rapidement et simplement sur un serveur YunoHost.* +> *Si vous n’avez pas YunoHost, consultez [ce guide](https://yunohost.org/install) pour savoir comment l’installer et en profiter.* ## Vue d’ensemble @@ -28,9 +28,10 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Accès optionnel au répertoire home depuis les fichiers Nextcloud (à activer à l'installation, le partage étant activé par défaut) * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 28.0.3~ynh2 -**Démo :** +**Version incluse :** 28.0.4~ynh1 + +**Démo :** ## Captures d’écran @@ -38,23 +39,23 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv ## Documentations et ressources -- Site officiel de l’app : -- Documentation officielle utilisateur : -- Documentation officielle de l’admin : -- Dépôt de code officiel de l’app : -- YunoHost Store : -- Signaler un bug : +- Site officiel de l’app : +- Documentation officielle utilisateur : +- Documentation officielle de l’admin : +- Dépôt de code officiel de l’app : +- YunoHost Store : +- Signaler un bug : ## Informations pour les développeurs -Merci de faire vos pull request sur la [branche testing](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). +Merci de faire vos pull request sur la [branche `testing`](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). -Pour essayer la branche testing, procédez comme suit. +Pour essayer la branche `testing`, procédez comme suit : -``` bash +```bash sudo yunohost app install https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug ou sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug ``` -**Plus d’infos sur le packaging d’applications :** +**Plus d’infos sur le packaging d’applications :** diff --git a/README_gl.md b/README_gl.md new file mode 100644 index 0000000..aad0610 --- /dev/null +++ b/README_gl.md @@ -0,0 +1,61 @@ + + +# Nextcloud para YunoHost + +[![Nivel de integración](https://dash.yunohost.org/integration/nextcloud.svg)](https://dash.yunohost.org/appci/app/nextcloud) ![Estado de funcionamento](https://ci-apps.yunohost.org/ci/badges/nextcloud.status.svg) ![Estado de mantemento](https://ci-apps.yunohost.org/ci/badges/nextcloud.maintain.svg) + +[![Instalar Nextcloud con YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) + +*[Le este README en outros idiomas.](./ALL_README.md)* + +> *Este paquete permíteche instalar Nextcloud de xeito rápido e doado nun servidor YunoHost.* +> *Se non usas YunoHost, le a [documentación](https://yunohost.org/install) para saber como instalalo.* + +## Vista xeral + +Nextcloud Hub is a fully open-source on-premises content collaboration platform. Teams access, share and edit their documents, chat and participate in video calls and manage their mail and calendar and projects across mobile, desktop and web interfaces. + +### YunoHost-specific features + +In addition to Nextcloud core features, the following are made available with this package: + + * Integrate with YunoHost users and SSO - i.e. logout button + * Allow one user to be the administrator (set at the installation) + * Allow multiple instances of this application + * Optionally access the user home folder from Nextcloud files (set at the installation, the sharing is enabled by default) + * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal + + +**Versión proporcionada:** 28.0.4~ynh1 + +**Demo:** + +## Capturas de pantalla + +![Captura de pantalla de Nextcloud](./doc/screenshots/screenshot.png) + +## Documentación e recursos + +- Web oficial da app: +- Documentación oficial para usuarias: +- Documentación oficial para admin: +- Repositorio de orixe do código: +- Tenda YunoHost: +- Informar dun problema: + +## Info de desenvolvemento + +Envía a túa colaboración á [rama `testing`](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). + +Para probar a rama `testing`, procede deste xeito: + +```bash +sudo yunohost app install https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +ou +sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +``` + +**Máis info sobre o empaquetado da app:** diff --git a/README_it.md b/README_it.md new file mode 100644 index 0000000..d3fa654 --- /dev/null +++ b/README_it.md @@ -0,0 +1,61 @@ + + +# Nextcloud per YunoHost + +[![Livello di integrazione](https://dash.yunohost.org/integration/nextcloud.svg)](https://dash.yunohost.org/appci/app/nextcloud) ![Stato di funzionamento](https://ci-apps.yunohost.org/ci/badges/nextcloud.status.svg) ![Stato di manutenzione](https://ci-apps.yunohost.org/ci/badges/nextcloud.maintain.svg) + +[![Installa Nextcloud con YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) + +*[Leggi questo README in altre lingue.](./ALL_README.md)* + +> *Questo pacchetto ti permette di installare Nextcloud su un server YunoHost in modo semplice e veloce.* +> *Se non hai YunoHost, consulta [la guida](https://yunohost.org/install) per imparare a installarlo.* + +## Panoramica + +Nextcloud Hub is a fully open-source on-premises content collaboration platform. Teams access, share and edit their documents, chat and participate in video calls and manage their mail and calendar and projects across mobile, desktop and web interfaces. + +### YunoHost-specific features + +In addition to Nextcloud core features, the following are made available with this package: + + * Integrate with YunoHost users and SSO - i.e. logout button + * Allow one user to be the administrator (set at the installation) + * Allow multiple instances of this application + * Optionally access the user home folder from Nextcloud files (set at the installation, the sharing is enabled by default) + * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal + + +**Versione pubblicata:** 28.0.4~ynh1 + +**Prova:** + +## Screenshot + +![Screenshot di Nextcloud](./doc/screenshots/screenshot.png) + +## Documentazione e risorse + +- Sito web ufficiale dell’app: +- Documentazione ufficiale per gli utenti: +- Documentazione ufficiale per gli amministratori: +- Repository upstream del codice dell’app: +- Store di YunoHost: +- Segnala un problema: + +## Informazioni per sviluppatori + +Si prega di inviare la tua pull request alla [branch di `testing`](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). + +Per provare la branch di `testing`, si prega di procedere in questo modo: + +```bash +sudo yunohost app install https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +o +sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +``` + +**Maggiori informazioni riguardo il pacchetto di quest’app:** From cbfc4bdc4b267a5071b650886171cf990b8510b6 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Wed, 3 Apr 2024 09:57:57 +0000 Subject: [PATCH 101/127] Auto-update READMEs --- ALL_README.md | 2 +- README.md | 2 +- README_eu.md | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 63 insertions(+), 2 deletions(-) create mode 100644 README_eu.md diff --git a/ALL_README.md b/ALL_README.md index 3d6c579..77b7509 100644 --- a/ALL_README.md +++ b/ALL_README.md @@ -1,6 +1,6 @@ # All available README files by language - [Read the README in English](README.md) +- [Irakurri README euskaraz](README_eu.md) - [Lire le README en français](README_fr.md) - [Le o README en galego](README_gl.md) -- [Leggi il “README” in italiano](README_it.md) diff --git a/README.md b/README.md index 933eeb7..23bacd8 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ It shall NOT be edited by hand. [![Install Nextcloud with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) -*[Read this README is other languages.](./ALL_README.md)* +*[Read this README in other languages.](./ALL_README.md)* > *This package allows you to install Nextcloud quickly and simply on a YunoHost server.* > *If you don't have YunoHost, please consult [the guide](https://yunohost.org/install) to learn how to install it.* diff --git a/README_eu.md b/README_eu.md new file mode 100644 index 0000000..0a5fa09 --- /dev/null +++ b/README_eu.md @@ -0,0 +1,61 @@ + + +# Nextcloud YunoHost-erako + +[![Integrazio maila](https://dash.yunohost.org/integration/nextcloud.svg)](https://dash.yunohost.org/appci/app/nextcloud) ![Funtzionamendu egoera](https://ci-apps.yunohost.org/ci/badges/nextcloud.status.svg) ![Mantentze egoera](https://ci-apps.yunohost.org/ci/badges/nextcloud.maintain.svg) + +[![Instalatu Nextcloud YunoHost-ekin](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) + +*[Irakurri README hau beste hizkuntzatan.](./ALL_README.md)* + +> *Pakete honek Nextcloud YunoHost zerbitzari batean azkar eta zailtasunik gabe instalatzea ahalbidetzen dizu.* +> *YunoHost ez baduzu, kontsultatu [gida](https://yunohost.org/install) nola instalatu ikasteko.* + +## Aurreikuspena + +Nextcloud Hub is a fully open-source on-premises content collaboration platform. Teams access, share and edit their documents, chat and participate in video calls and manage their mail and calendar and projects across mobile, desktop and web interfaces. + +### YunoHost-specific features + +In addition to Nextcloud core features, the following are made available with this package: + + * Integrate with YunoHost users and SSO - i.e. logout button + * Allow one user to be the administrator (set at the installation) + * Allow multiple instances of this application + * Optionally access the user home folder from Nextcloud files (set at the installation, the sharing is enabled by default) + * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal + + +**Paketatutako bertsioa:** 28.0.4~ynh1 + +**Demoa:** + +## Pantaila-argazkiak + +![Nextcloud(r)en pantaila-argazkia](./doc/screenshots/screenshot.png) + +## Dokumentazioa eta baliabideak + +- Aplikazioaren webgune ofiziala: +- Erabiltzaileen dokumentazio ofiziala: +- Administratzaileen dokumentazio ofiziala: +- Jatorrizko aplikazioaren kode-gordailua: +- YunoHost Denda: +- Eman errore baten berri: + +## Garatzaileentzako informazioa + +Bidali `pull request`a [`testing` abarrera](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). + +`testing` abarra probatzeko, ondorengoa egin: + +```bash +sudo yunohost app install https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +edo +sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +``` + +**Informazio gehiago aplikazioaren paketatzeari buruz:** From 09219ab72d1473e655f26752c698d6654eaee0c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 18 Apr 2024 16:26:41 +0200 Subject: [PATCH 102/127] remove upgrade_type --- scripts/upgrade | 314 ++++++++++++++++++++++++------------------------ 1 file changed, 154 insertions(+), 160 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 75de335..d99c247 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -3,8 +3,6 @@ source _common.sh source /usr/share/yunohost/helpers -upgrade_type=$(ynh_check_app_version_changed) - #================================================= # ENSURE DOWNWARD COMPATIBILITY #================================================= @@ -148,177 +146,173 @@ then fi fi -if [ "$upgrade_type" == "UPGRADE_APP" ] -then - ynh_script_progression --message="Upgrading $app..." --weight=3 +ynh_script_progression --message="Upgrading $app..." --weight=3 + +# Set write access for the following commands +chown -R $app: "$install_dir" "$data_dir" + +# Print the current version number of Nextcloud +exec_occ -V + + +# Upgrade may fail if this app is enabled +# Take all apps enabled, and check if mail is one of them +# Then temporary disable the mail app +mail_app_must_be_reactived=0 + +if exec_occ app:list | awk '/Enabled/{f=1;next} /Disabled/{f=0} f' | grep -q -w mail; then + exec_occ app:disable mail + mail_app_must_be_reactived=1 +fi + +# While the current version is not the last version, do an upgrade +while [ "$last_version" != "$current_version" ] +do + next_major_version="$(( $current_major_version + 1 ))" + if [[ "$next_major_version" -ge "$last_major_version" ]]; then + ynh_print_info --message="Upgrading to Nextcloud $last_version" + cp -a ../sources/patches_last_version/* ../sources/patches + source_id="main" + else + ynh_print_info --message="Upgrading to Nextcloud $next_major_version" + source_id="$next_major_version" + fi + + # Create a temporary directory + tmpdir="${install_dir}__tmp_upgrade" + + ynh_setup_source --dest_dir="$tmpdir" --source_id="$source_id" + + # Backup the config file in the temp dir + cp -a "$install_dir/config/config.php" "$tmpdir/config/config.php" + + # Enable maintenance mode + exec_occ maintenance:mode --on + + # Backup 3rd party applications from the current Nextcloud + # But do not overwrite if there is any upgrade + # (apps directory already exists in Nextcloud archive) + ( + cd $install_dir/apps + for nc_app_dir in */ + do + if [ ! -d "$tmpdir/apps/$nc_app_dir" ] + then + cp -a "$nc_app_dir" "$tmpdir/apps/$nc_app_dir" + fi + done + ) + + # Replace the old Nextcloud by the new one + ynh_secure_remove --file="$install_dir" + mv "$tmpdir" "$install_dir" # Set write access for the following commands chown -R $app: "$install_dir" "$data_dir" + # Upgrade Nextcloud (SUCCESS = 0, UP_TO_DATE = 3) + exec_occ maintenance:mode --off + exec_occ upgrade \ + || [ $? -eq 3 ] || ynh_die --message="Unable to upgrade $app" + + # Get the new current version number + current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) + current_major_version=${current_version%%.*} + # Print the current version number of Nextcloud exec_occ -V +done +exec_occ db:add-missing-indices -n +exec_occ db:add-missing-columns -n +exec_occ db:add-missing-primary-keys -n +exec_occ db:convert-filecache-bigint -n - # Upgrade may fail if this app is enabled - # Take all apps enabled, and check if mail is one of them - # Then temporary disable the mail app - mail_app_must_be_reactived=0 +#================================================= +# CONFIGURE NEXTCLOUD +#================================================= +ynh_script_progression --message="Reconfiguring $app..." --weight=9 - if exec_occ app:list | awk '/Enabled/{f=1;next} /Disabled/{f=0} f' | grep -q -w mail; then - exec_occ app:disable mail - mail_app_must_be_reactived=1 - fi +# Verify the checksum and backup the file if it's different +ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" - # While the current version is not the last version, do an upgrade - while [ "$last_version" != "$current_version" ] - do +nc_conf="${install_dir}/config.json" +ynh_add_config --template="config.json" --destination="$nc_conf" - next_major_version="$(( $current_major_version + 1 ))" - if [[ "$next_major_version" -ge "$last_major_version" ]]; then - ynh_print_info --message="Upgrading to Nextcloud $last_version" - cp -a ../sources/patches_last_version/* ../sources/patches - source_id="main" - else - ynh_print_info --message="Upgrading to Nextcloud $next_major_version" - source_id="$next_major_version" - fi - - # Create a temporary directory - tmpdir="${install_dir}__tmp_upgrade" - - ynh_setup_source --dest_dir="$tmpdir" --source_id="$source_id" - - # Backup the config file in the temp dir - cp -a "$install_dir/config/config.php" "$tmpdir/config/config.php" - - # Enable maintenance mode - exec_occ maintenance:mode --on - - # Backup 3rd party applications from the current Nextcloud - # But do not overwrite if there is any upgrade - # (apps directory already exists in Nextcloud archive) - ( - cd $install_dir/apps - for nc_app_dir in */ - do - if [ ! -d "$tmpdir/apps/$nc_app_dir" ] - then - cp -a "$nc_app_dir" "$tmpdir/apps/$nc_app_dir" - fi - done - ) - - # Replace the old Nextcloud by the new one - ynh_secure_remove --file="$install_dir" - mv "$tmpdir" "$install_dir" - - # Set write access for the following commands - chown -R $app: "$install_dir" "$data_dir" - - # Upgrade Nextcloud (SUCCESS = 0, UP_TO_DATE = 3) - exec_occ maintenance:mode --off - exec_occ upgrade \ - || [ $? -eq 3 ] || ynh_die --message="Unable to upgrade $app" - - # Get the new current version number - current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) - current_major_version=${current_version%%.*} - - # Print the current version number of Nextcloud - exec_occ -V - done - - exec_occ db:add-missing-indices -n - exec_occ db:add-missing-columns -n - exec_occ db:add-missing-primary-keys -n - exec_occ db:convert-filecache-bigint -n - - #================================================= - # CONFIGURE NEXTCLOUD - #================================================= - ynh_script_progression --message="Reconfiguring $app..." --weight=9 - - # Verify the checksum and backup the file if it's different - ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" - - nc_conf="${install_dir}/config.json" - ynh_add_config --template="config.json" --destination="$nc_conf" - - # Reneable the mail app - if [ $mail_app_must_be_reactived -eq 1 ]; then - exec_occ app:enable mail - fi - - # Ensure that UpdateNotification app is disabled - exec_occ app:disable updatenotification - - # Enable LDAP plugin - exec_occ app:enable user_ldap - - # Update all installed apps - exec_occ app:update --all - - # move the logs from the data_dir to the standard /var/log - # it would be better in the ENSURE DOWNWARD COMPATIBILITY section - # but it must be after the exec_occ() definition, so it's here - if [ -f "$data_dir/data/nextcloud.log" ]; then - mkdir -p "/var/log/$app" - chmod 750 "/var/log/$app" - mv "$data_dir"/data/nextcloud.log* "/var/log/$app" - # adapt the nextcloud config - exec_occ config:system:set logfile --value="/var/log/$app/nextcloud.log" - fi - - # Load the config file in nextcloud - exec_occ config:import "$nc_conf" - - # Then remove the config file - ynh_secure_remove --file="$nc_conf" - - #================================================= - # ALLOW USERS TO DISCONNECT FROM NEXTCLOUD - #================================================= - - # Add dynamic logout URL to the config - exec_occ config:system:get logout_url >/dev/null 2>&1 \ - || echo " - //-YunoHost- - // set logout_url according to main domain - \$main_domain = exec('cat /etc/yunohost/current_host'); - \$CONFIG['logout_url'] = 'https://'.\$main_domain.'/yunohost/sso/?action=logout'; - //-YunoHost- - " >> "$install_dir/config/config.php" - - #================================================= - # CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS - #================================================= - - exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" - - #================================================= - # MOUNT HOME FOLDERS AS EXTERNAL STORAGE - #================================================= - - # Enable External Storage and create local mount to home folder as needed - if [ $user_home -eq 1 ]; then - exec_occ app:enable files_external - exec_occ files_external:list --output=json \ - | grep -q '"storage":"\\\\OC\\\\Files\\\\Storage\\\\Local"' \ - || create_external_storage "/home/\$user" "Home" - # Iterate over users to extend their home folder permissions - for u in $(ynh_user_list); do - setfacl --modify g:$app:rwx "/home/$u" || true - done - fi - - #================================================= - # STORE THE CHECKSUM OF THE CONFIG FILE - #================================================= - - # Calculate and store the config file checksum into the app settings - ynh_store_file_checksum --file="${install_dir}/config/config.php" +# Reneable the mail app +if [ $mail_app_must_be_reactived -eq 1 ]; then + exec_occ app:enable mail fi +# Ensure that UpdateNotification app is disabled +exec_occ app:disable updatenotification + +# Enable LDAP plugin +exec_occ app:enable user_ldap + +# Update all installed apps +exec_occ app:update --all + +# move the logs from the data_dir to the standard /var/log +# it would be better in the ENSURE DOWNWARD COMPATIBILITY section +# but it must be after the exec_occ() definition, so it's here +if [ -f "$data_dir/data/nextcloud.log" ]; then + mkdir -p "/var/log/$app" + chmod 750 "/var/log/$app" + mv "$data_dir"/data/nextcloud.log* "/var/log/$app" + # adapt the nextcloud config + exec_occ config:system:set logfile --value="/var/log/$app/nextcloud.log" +fi + +# Load the config file in nextcloud +exec_occ config:import "$nc_conf" + +# Then remove the config file +ynh_secure_remove --file="$nc_conf" + +#================================================= +# ALLOW USERS TO DISCONNECT FROM NEXTCLOUD +#================================================= + +# Add dynamic logout URL to the config +exec_occ config:system:get logout_url >/dev/null 2>&1 \ +|| echo " +//-YunoHost- +// set logout_url according to main domain +\$main_domain = exec('cat /etc/yunohost/current_host'); +\$CONFIG['logout_url'] = 'https://'.\$main_domain.'/yunohost/sso/?action=logout'; +//-YunoHost- +" >> "$install_dir/config/config.php" + +#================================================= +# CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS +#================================================= + +exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" + +#================================================= +# MOUNT HOME FOLDERS AS EXTERNAL STORAGE +#================================================= + +# Enable External Storage and create local mount to home folder as needed +if [ $user_home -eq 1 ]; then + exec_occ app:enable files_external + exec_occ files_external:list --output=json \ + | grep -q '"storage":"\\\\OC\\\\Files\\\\Storage\\\\Local"' \ + || create_external_storage "/home/\$user" "Home" + # Iterate over users to extend their home folder permissions + for u in $(ynh_user_list); do + setfacl --modify g:$app:rwx "/home/$u" || true + done +fi + +#================================================= +# STORE THE CHECKSUM OF THE CONFIG FILE +#================================================= + +# Calculate and store the config file checksum into the app settings +ynh_store_file_checksum --file="${install_dir}/config/config.php" + #================================================= # REGEN PERMISSIONS #================================================= From e509d3766dde1907ada8f381f482346a59b6881a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 19 Apr 2024 12:20:29 +0200 Subject: [PATCH 103/127] Revert "remove upgrade_type" This reverts commit 09219ab72d1473e655f26752c698d6654eaee0c7. --- scripts/upgrade | 292 ++++++++++++++++++++++++------------------------ 1 file changed, 149 insertions(+), 143 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index d99c247..75de335 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -3,6 +3,8 @@ source _common.sh source /usr/share/yunohost/helpers +upgrade_type=$(ynh_check_app_version_changed) + #================================================= # ENSURE DOWNWARD COMPATIBILITY #================================================= @@ -146,173 +148,177 @@ then fi fi -ynh_script_progression --message="Upgrading $app..." --weight=3 - -# Set write access for the following commands -chown -R $app: "$install_dir" "$data_dir" - -# Print the current version number of Nextcloud -exec_occ -V - - -# Upgrade may fail if this app is enabled -# Take all apps enabled, and check if mail is one of them -# Then temporary disable the mail app -mail_app_must_be_reactived=0 - -if exec_occ app:list | awk '/Enabled/{f=1;next} /Disabled/{f=0} f' | grep -q -w mail; then - exec_occ app:disable mail - mail_app_must_be_reactived=1 -fi - -# While the current version is not the last version, do an upgrade -while [ "$last_version" != "$current_version" ] -do - next_major_version="$(( $current_major_version + 1 ))" - if [[ "$next_major_version" -ge "$last_major_version" ]]; then - ynh_print_info --message="Upgrading to Nextcloud $last_version" - cp -a ../sources/patches_last_version/* ../sources/patches - source_id="main" - else - ynh_print_info --message="Upgrading to Nextcloud $next_major_version" - source_id="$next_major_version" - fi - - # Create a temporary directory - tmpdir="${install_dir}__tmp_upgrade" - - ynh_setup_source --dest_dir="$tmpdir" --source_id="$source_id" - - # Backup the config file in the temp dir - cp -a "$install_dir/config/config.php" "$tmpdir/config/config.php" - - # Enable maintenance mode - exec_occ maintenance:mode --on - - # Backup 3rd party applications from the current Nextcloud - # But do not overwrite if there is any upgrade - # (apps directory already exists in Nextcloud archive) - ( - cd $install_dir/apps - for nc_app_dir in */ - do - if [ ! -d "$tmpdir/apps/$nc_app_dir" ] - then - cp -a "$nc_app_dir" "$tmpdir/apps/$nc_app_dir" - fi - done - ) - - # Replace the old Nextcloud by the new one - ynh_secure_remove --file="$install_dir" - mv "$tmpdir" "$install_dir" +if [ "$upgrade_type" == "UPGRADE_APP" ] +then + ynh_script_progression --message="Upgrading $app..." --weight=3 # Set write access for the following commands chown -R $app: "$install_dir" "$data_dir" - # Upgrade Nextcloud (SUCCESS = 0, UP_TO_DATE = 3) - exec_occ maintenance:mode --off - exec_occ upgrade \ - || [ $? -eq 3 ] || ynh_die --message="Unable to upgrade $app" - - # Get the new current version number - current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) - current_major_version=${current_version%%.*} - # Print the current version number of Nextcloud exec_occ -V -done -exec_occ db:add-missing-indices -n -exec_occ db:add-missing-columns -n -exec_occ db:add-missing-primary-keys -n -exec_occ db:convert-filecache-bigint -n -#================================================= -# CONFIGURE NEXTCLOUD -#================================================= -ynh_script_progression --message="Reconfiguring $app..." --weight=9 + # Upgrade may fail if this app is enabled + # Take all apps enabled, and check if mail is one of them + # Then temporary disable the mail app + mail_app_must_be_reactived=0 -# Verify the checksum and backup the file if it's different -ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" + if exec_occ app:list | awk '/Enabled/{f=1;next} /Disabled/{f=0} f' | grep -q -w mail; then + exec_occ app:disable mail + mail_app_must_be_reactived=1 + fi -nc_conf="${install_dir}/config.json" -ynh_add_config --template="config.json" --destination="$nc_conf" + # While the current version is not the last version, do an upgrade + while [ "$last_version" != "$current_version" ] + do -# Reneable the mail app -if [ $mail_app_must_be_reactived -eq 1 ]; then - exec_occ app:enable mail -fi + next_major_version="$(( $current_major_version + 1 ))" + if [[ "$next_major_version" -ge "$last_major_version" ]]; then + ynh_print_info --message="Upgrading to Nextcloud $last_version" + cp -a ../sources/patches_last_version/* ../sources/patches + source_id="main" + else + ynh_print_info --message="Upgrading to Nextcloud $next_major_version" + source_id="$next_major_version" + fi -# Ensure that UpdateNotification app is disabled -exec_occ app:disable updatenotification + # Create a temporary directory + tmpdir="${install_dir}__tmp_upgrade" -# Enable LDAP plugin -exec_occ app:enable user_ldap + ynh_setup_source --dest_dir="$tmpdir" --source_id="$source_id" -# Update all installed apps -exec_occ app:update --all + # Backup the config file in the temp dir + cp -a "$install_dir/config/config.php" "$tmpdir/config/config.php" -# move the logs from the data_dir to the standard /var/log -# it would be better in the ENSURE DOWNWARD COMPATIBILITY section -# but it must be after the exec_occ() definition, so it's here -if [ -f "$data_dir/data/nextcloud.log" ]; then - mkdir -p "/var/log/$app" - chmod 750 "/var/log/$app" - mv "$data_dir"/data/nextcloud.log* "/var/log/$app" - # adapt the nextcloud config - exec_occ config:system:set logfile --value="/var/log/$app/nextcloud.log" -fi + # Enable maintenance mode + exec_occ maintenance:mode --on -# Load the config file in nextcloud -exec_occ config:import "$nc_conf" + # Backup 3rd party applications from the current Nextcloud + # But do not overwrite if there is any upgrade + # (apps directory already exists in Nextcloud archive) + ( + cd $install_dir/apps + for nc_app_dir in */ + do + if [ ! -d "$tmpdir/apps/$nc_app_dir" ] + then + cp -a "$nc_app_dir" "$tmpdir/apps/$nc_app_dir" + fi + done + ) -# Then remove the config file -ynh_secure_remove --file="$nc_conf" + # Replace the old Nextcloud by the new one + ynh_secure_remove --file="$install_dir" + mv "$tmpdir" "$install_dir" -#================================================= -# ALLOW USERS TO DISCONNECT FROM NEXTCLOUD -#================================================= + # Set write access for the following commands + chown -R $app: "$install_dir" "$data_dir" -# Add dynamic logout URL to the config -exec_occ config:system:get logout_url >/dev/null 2>&1 \ -|| echo " -//-YunoHost- -// set logout_url according to main domain -\$main_domain = exec('cat /etc/yunohost/current_host'); -\$CONFIG['logout_url'] = 'https://'.\$main_domain.'/yunohost/sso/?action=logout'; -//-YunoHost- -" >> "$install_dir/config/config.php" + # Upgrade Nextcloud (SUCCESS = 0, UP_TO_DATE = 3) + exec_occ maintenance:mode --off + exec_occ upgrade \ + || [ $? -eq 3 ] || ynh_die --message="Unable to upgrade $app" -#================================================= -# CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS -#================================================= + # Get the new current version number + current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) + current_major_version=${current_version%%.*} -exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" - -#================================================= -# MOUNT HOME FOLDERS AS EXTERNAL STORAGE -#================================================= - -# Enable External Storage and create local mount to home folder as needed -if [ $user_home -eq 1 ]; then - exec_occ app:enable files_external - exec_occ files_external:list --output=json \ - | grep -q '"storage":"\\\\OC\\\\Files\\\\Storage\\\\Local"' \ - || create_external_storage "/home/\$user" "Home" - # Iterate over users to extend their home folder permissions - for u in $(ynh_user_list); do - setfacl --modify g:$app:rwx "/home/$u" || true + # Print the current version number of Nextcloud + exec_occ -V done + + exec_occ db:add-missing-indices -n + exec_occ db:add-missing-columns -n + exec_occ db:add-missing-primary-keys -n + exec_occ db:convert-filecache-bigint -n + + #================================================= + # CONFIGURE NEXTCLOUD + #================================================= + ynh_script_progression --message="Reconfiguring $app..." --weight=9 + + # Verify the checksum and backup the file if it's different + ynh_backup_if_checksum_is_different --file="$install_dir/config/config.php" + + nc_conf="${install_dir}/config.json" + ynh_add_config --template="config.json" --destination="$nc_conf" + + # Reneable the mail app + if [ $mail_app_must_be_reactived -eq 1 ]; then + exec_occ app:enable mail + fi + + # Ensure that UpdateNotification app is disabled + exec_occ app:disable updatenotification + + # Enable LDAP plugin + exec_occ app:enable user_ldap + + # Update all installed apps + exec_occ app:update --all + + # move the logs from the data_dir to the standard /var/log + # it would be better in the ENSURE DOWNWARD COMPATIBILITY section + # but it must be after the exec_occ() definition, so it's here + if [ -f "$data_dir/data/nextcloud.log" ]; then + mkdir -p "/var/log/$app" + chmod 750 "/var/log/$app" + mv "$data_dir"/data/nextcloud.log* "/var/log/$app" + # adapt the nextcloud config + exec_occ config:system:set logfile --value="/var/log/$app/nextcloud.log" + fi + + # Load the config file in nextcloud + exec_occ config:import "$nc_conf" + + # Then remove the config file + ynh_secure_remove --file="$nc_conf" + + #================================================= + # ALLOW USERS TO DISCONNECT FROM NEXTCLOUD + #================================================= + + # Add dynamic logout URL to the config + exec_occ config:system:get logout_url >/dev/null 2>&1 \ + || echo " + //-YunoHost- + // set logout_url according to main domain + \$main_domain = exec('cat /etc/yunohost/current_host'); + \$CONFIG['logout_url'] = 'https://'.\$main_domain.'/yunohost/sso/?action=logout'; + //-YunoHost- + " >> "$install_dir/config/config.php" + + #================================================= + # CHANGE HOSTNAME FOR ACTIVITY NOTIFICATIONS + #================================================= + + exec_occ config:system:set overwrite.cli.url --value="https://${domain}${path}" + + #================================================= + # MOUNT HOME FOLDERS AS EXTERNAL STORAGE + #================================================= + + # Enable External Storage and create local mount to home folder as needed + if [ $user_home -eq 1 ]; then + exec_occ app:enable files_external + exec_occ files_external:list --output=json \ + | grep -q '"storage":"\\\\OC\\\\Files\\\\Storage\\\\Local"' \ + || create_external_storage "/home/\$user" "Home" + # Iterate over users to extend their home folder permissions + for u in $(ynh_user_list); do + setfacl --modify g:$app:rwx "/home/$u" || true + done + fi + + #================================================= + # STORE THE CHECKSUM OF THE CONFIG FILE + #================================================= + + # Calculate and store the config file checksum into the app settings + ynh_store_file_checksum --file="${install_dir}/config/config.php" fi -#================================================= -# STORE THE CHECKSUM OF THE CONFIG FILE -#================================================= - -# Calculate and store the config file checksum into the app settings -ynh_store_file_checksum --file="${install_dir}/config/config.php" - #================================================= # REGEN PERMISSIONS #================================================= From a423112999c419544175bae6d6c75c624934a9d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 23 Apr 2024 18:48:11 +0200 Subject: [PATCH 104/127] 29 --- manifest.toml | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/manifest.toml b/manifest.toml index 6f99626..4c4c859 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "28.0.4~ynh2" +version = "29.0.0~ynh1" maintainers = ["kay0u"] @@ -66,8 +66,12 @@ ram.runtime = "512M" [resources.sources] [resources.sources.main] - url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.4.tar.bz2' - sha256 = '9bfecee1e12fba48c49e9a71caa81c4ba10b2884787fab75d64ccfd122a13019' + url = 'https://download.nextcloud.com/server/releases/nextcloud-29.0.0.tar.bz2' + sha256 = 'e9b53f6432b6f664487d3869645fa121a64cf0ed6aee83aa560903daf86b52bd' + + [resources.sources.28] + url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.0.tar.bz2' + sha256 = '4e8b0b74b40221e85f92ab869d0873c69a52d7e43889d9259c6259428a6a36f2' [resources.sources.27] url = 'https://download.nextcloud.com/server/releases/nextcloud-27.0.0.tar.bz2' From cca94605192e9016b00b4f5352b8ceb45e196322 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 23 Apr 2024 16:48:17 +0000 Subject: [PATCH 105/127] Auto-update READMEs --- README.md | 2 +- README_eu.md | 2 +- README_fr.md | 2 +- README_gl.md | 2 +- README_zh_Hans.md | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 7a0a267..7a9e303 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 28.0.4~ynh2 +**Shipped version:** 29.0.0~ynh1 **Demo:** diff --git a/README_eu.md b/README_eu.md index 0676394..1802216 100644 --- a/README_eu.md +++ b/README_eu.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Paketatutako bertsioa:** 28.0.4~ynh2 +**Paketatutako bertsioa:** 29.0.0~ynh1 **Demoa:** diff --git a/README_fr.md b/README_fr.md index 91334c2..a6a50e4 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 28.0.4~ynh2 +**Version incluse :** 29.0.0~ynh1 **Démo :** diff --git a/README_gl.md b/README_gl.md index e0c3070..dd5d840 100644 --- a/README_gl.md +++ b/README_gl.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Versión proporcionada:** 28.0.4~ynh2 +**Versión proporcionada:** 29.0.0~ynh1 **Demo:** diff --git a/README_zh_Hans.md b/README_zh_Hans.md index be0c591..5161b30 100644 --- a/README_zh_Hans.md +++ b/README_zh_Hans.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**分发版本:** 28.0.4~ynh2 +**分发版本:** 29.0.0~ynh1 **演示:** From 1d0d3f159fd284669e435f486c2b37c231ff672d Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Fri, 17 May 2024 13:07:18 +0000 Subject: [PATCH 106/127] Auto-update READMEs --- ALL_README.md | 1 + README_es.md | 61 +++++++++++++++++++++++++++++++++++++++++++++++ README_zh_Hans.md | 2 +- 3 files changed, 63 insertions(+), 1 deletion(-) create mode 100644 README_es.md diff --git a/ALL_README.md b/ALL_README.md index a01b345..8938aae 100644 --- a/ALL_README.md +++ b/ALL_README.md @@ -1,6 +1,7 @@ # All available README files by language - [Read the README in English](README.md) +- [Lee el README en español](README_es.md) - [Irakurri README euskaraz](README_eu.md) - [Lire le README en français](README_fr.md) - [Le o README en galego](README_gl.md) diff --git a/README_es.md b/README_es.md new file mode 100644 index 0000000..5d0f6b0 --- /dev/null +++ b/README_es.md @@ -0,0 +1,61 @@ + + +# Nextcloud para Yunohost + +[![Nivel de integración](https://dash.yunohost.org/integration/nextcloud.svg)](https://dash.yunohost.org/appci/app/nextcloud) ![Estado funcional](https://ci-apps.yunohost.org/ci/badges/nextcloud.status.svg) ![Estado En Mantención](https://ci-apps.yunohost.org/ci/badges/nextcloud.maintain.svg) + +[![Instalar Nextcloud con Yunhost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) + +*[Leer este README en otros idiomas.](./ALL_README.md)* + +> *Este paquete le permite instalarNextcloud rapidamente y simplement en un servidor YunoHost.* +> *Si no tiene YunoHost, visita [the guide](https://yunohost.org/install) para aprender como instalarla.* + +## Descripción general + +Nextcloud Hub is a fully open-source on-premises content collaboration platform. Teams access, share and edit their documents, chat and participate in video calls and manage their mail and calendar and projects across mobile, desktop and web interfaces. + +### YunoHost-specific features + +In addition to Nextcloud core features, the following are made available with this package: + + * Integrate with YunoHost users and SSO - i.e. logout button + * Allow one user to be the administrator (set at the installation) + * Allow multiple instances of this application + * Optionally access the user home folder from Nextcloud files (set at the installation, the sharing is enabled by default) + * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal + + +**Versión actual:** 29.0.0~ynh1 + +**Demo:** + +## Capturas + +![Captura de Nextcloud](./doc/screenshots/screenshot.png) + +## Documentaciones y recursos + +- Sitio web oficial: +- Documentación usuario oficial: +- Documentación administrador oficial: +- Repositorio del código fuente oficial de la aplicación : +- Catálogo YunoHost: +- Reportar un error: + +## Información para desarrolladores + +Por favor enviar sus correcciones a la [`branch testing`](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing + +Para probar la rama `testing`, sigue asÍ: + +```bash +sudo yunohost app install https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +o +sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +``` + +**Mas informaciones sobre el empaquetado de aplicaciones:** diff --git a/README_zh_Hans.md b/README_zh_Hans.md index 5161b30..915e5c3 100644 --- a/README_zh_Hans.md +++ b/README_zh_Hans.md @@ -3,7 +3,7 @@ 请勿手动编辑。 --> -# YunoHost 的 Nextcloud +# YunoHost 上的 Nextcloud [![集成程度](https://dash.yunohost.org/integration/nextcloud.svg)](https://dash.yunohost.org/appci/app/nextcloud) ![工作状态](https://ci-apps.yunohost.org/ci/badges/nextcloud.status.svg) ![维护状态](https://ci-apps.yunohost.org/ci/badges/nextcloud.maintain.svg) From 04b78947688231eadb37e2a08fb806d5ba7fe77c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 22 May 2024 23:06:38 +0200 Subject: [PATCH 107/127] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 4c4c859..173b50f 100644 --- a/manifest.toml +++ b/manifest.toml @@ -116,7 +116,7 @@ ram.runtime = "512M" api.allowed = ["visitors", "all_users"] [resources.apt] - packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.2-pgsql, php8.2-mysql, php8.2-fpm, php8.2-bz2, php8.2-imap, php8.2-gmp, php8.2-gd, php8.2-intl, php8.2-curl, php8.2-apcu, php8.2-redis, php8.2-ldap, php8.2-imagick, php8.2-zip, php8.2-mbstring, php8.2-xml, php8.2-igbinary, php8.2-bcmath" + packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.3-pgsql, php8.3-mysql, php8.3-fpm, php8.3-bz2, php8.3-imap, php8.3-gmp, php8.3-gd, php8.3-intl, php8.3-curl, php8.3-apcu, php8.3-redis, php8.3-ldap, php8.3-imagick, php8.3-zip, php8.3-mbstring, php8.3-xml, php8.3-igbinary, php8.3-bcmath" [resources.database] type = "postgresql" From 1ffe5e4c7df5bb2dab027e44d71691b640aff25b Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Wed, 22 May 2024 21:06:43 +0000 Subject: [PATCH 108/127] Auto-update READMEs --- ALL_README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ALL_README.md b/ALL_README.md index 8938aae..152f2e7 100644 --- a/ALL_README.md +++ b/ALL_README.md @@ -1,7 +1,7 @@ # All available README files by language - [Read the README in English](README.md) -- [Lee el README en español](README_es.md) +- [Lea el README en español](README_es.md) - [Irakurri README euskaraz](README_eu.md) - [Lire le README en français](README_fr.md) - [Le o README en galego](README_gl.md) From 2fef2c7b344b40e7b73b0dda308bb641d5b3a3c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Mon, 3 Jun 2024 16:42:01 +0200 Subject: [PATCH 109/127] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 52aa830..1493a58 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -136,7 +136,7 @@ function list_installed_apps_not_compatible_with_future_version() } -last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9]') +last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9][0-9]') last_major_version=${last_version%%.*} if [[ "$last_major_version" != "$current_major_version" ]] From 1c3536c13040c1b6b6f29578ad5db8e0387d4626 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 20 Jun 2024 14:34:48 +0200 Subject: [PATCH 110/127] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 1493a58..df14187 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -76,7 +76,7 @@ exec_occ() { #================================================= # If we're moving through version 28.0.2~ynh1 (in which the switch to psql is made) -if ynh_compare_current_package_version --comparison lt --version 28.0.2~ynh2 +if ynh_compare_current_package_version --comparison lt --version 29.0.2~ynh1 then # Double-check the MySQL DB is here if ! mysql -e "USE $db_name" 2>/dev/null From 73a3f0d699f00a07bc919992d0db430b1f6abfbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 20 Jun 2024 14:35:04 +0200 Subject: [PATCH 111/127] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index df14187..63fb3ef 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -75,7 +75,7 @@ exec_occ() { # HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= -# If we're moving through version 28.0.2~ynh1 (in which the switch to psql is made) +# If we're moving through version 29.0.2~ynh1 (in which the switch to psql is made) if ynh_compare_current_package_version --comparison lt --version 29.0.2~ynh1 then # Double-check the MySQL DB is here From 36cd0dc73d2a7281fb95ba55a6c8d4d14caaeb20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 20 Jun 2024 14:59:45 +0200 Subject: [PATCH 112/127] Update upgrade --- scripts/upgrade | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 63fb3ef..4fda8da 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -19,10 +19,10 @@ if [ -z "${phpflags:-}" ]; then ynh_app_setting_set --app=$app --key=phpflags --value="$phpflags" fi -if ynh_compare_current_package_version --comparison lt --version 22.2~ynh1 -then - ynh_die --message="Upgrading from Nextcloud < 22.2 is not supported anymore. You should first upgrade to 22.2 using: yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/41f5f902e7c7cd3c30a6793020562ba98b9bf3e9" -fi +#if ynh_compare_current_package_version --comparison lt --version 22.2~ynh1 +#then +# ynh_die --message="Upgrading from Nextcloud < 22.2 is not supported anymore. You should first upgrade to 22.2 using: yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/41f5f902e7c7cd3c30a6793020562ba98b9bf3e9" +#fi #================================================= # SPECIFIC UPGRADE From 361f046f282d67fcf57022721c117c37620f6f57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 20 Jun 2024 15:00:09 +0200 Subject: [PATCH 113/127] Update upgrade --- scripts/upgrade | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 4fda8da..63fb3ef 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -19,10 +19,10 @@ if [ -z "${phpflags:-}" ]; then ynh_app_setting_set --app=$app --key=phpflags --value="$phpflags" fi -#if ynh_compare_current_package_version --comparison lt --version 22.2~ynh1 -#then -# ynh_die --message="Upgrading from Nextcloud < 22.2 is not supported anymore. You should first upgrade to 22.2 using: yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/41f5f902e7c7cd3c30a6793020562ba98b9bf3e9" -#fi +if ynh_compare_current_package_version --comparison lt --version 22.2~ynh1 +then + ynh_die --message="Upgrading from Nextcloud < 22.2 is not supported anymore. You should first upgrade to 22.2 using: yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/41f5f902e7c7cd3c30a6793020562ba98b9bf3e9" +fi #================================================= # SPECIFIC UPGRADE From 2d4ff6bfbf76884009a0a1f997e9fd216c3889dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 25 Jun 2024 15:44:07 +0200 Subject: [PATCH 114/127] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 2821d65..b369cb4 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -76,7 +76,7 @@ exec_occ() { #================================================= # If we're moving through version 29.0.2~ynh1 (in which the switch to psql is made) -if ynh_compare_current_package_version --comparison lt --version 29.0.2~ynh1 +if ynh_compare_current_package_version --comparison lt --version 29.0.3~ynh1 then # Double-check the MySQL DB is here if ! mysql -e "USE $db_name" 2>/dev/null From 1583a7c9c4d30332c3aaa5d222b03a1826150bed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 25 Jun 2024 15:47:53 +0200 Subject: [PATCH 115/127] Update upgrade --- scripts/upgrade | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index b369cb4..5f1e665 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -75,26 +75,26 @@ exec_occ() { # HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= -# If we're moving through version 29.0.2~ynh1 (in which the switch to psql is made) -if ynh_compare_current_package_version --comparison lt --version 29.0.3~ynh1 -then - # Double-check the MySQL DB is here - if ! mysql -e "USE $db_name" 2>/dev/null - then - ynh_print_warn "Uhoh? The Nextcloud MySQL DB doesn't exist? We are supposed to move it to PostgreSQL... Maybe it was already migrated?" - # Double check the psql is not empty, otherwise big whoops? - if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] - then - ynh_die "Apparently the PostgreSQL DB is also empty, this is kind of worrying, what happened?!" - else - ynh_print_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" - fi - else - ynh_print_info --message="Migrating to PostgreSQL database..." - ynh_exec_warn_less exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n - ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name - fi -fi +# # If we're moving through version 29.0.3~ynh1 (in which the switch to psql is made) +# if ynh_compare_current_package_version --comparison lt --version 29.0.3~ynh1 +# then +# # Double-check the MySQL DB is here +# if ! mysql -e "USE $db_name" 2>/dev/null +# then +# ynh_print_warn "Uhoh? The Nextcloud MySQL DB doesn't exist? We are supposed to move it to PostgreSQL... Maybe it was already migrated?" +# # Double check the psql is not empty, otherwise big whoops? +# if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] +# then +# ynh_die "Apparently the PostgreSQL DB is also empty, this is kind of worrying, what happened?!" +# else +# ynh_print_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" +# fi +# else +# ynh_print_info --message="Migrating to PostgreSQL database..." +# ynh_exec_warn_less exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n +# ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name +# fi +# fi #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE From 4d8b668ebfa7cb4a1d3cd06780bfb2b1f64d830c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 25 Jun 2024 15:49:58 +0200 Subject: [PATCH 116/127] Update upgrade --- scripts/upgrade | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 5f1e665..089b847 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -75,26 +75,26 @@ exec_occ() { # HANDLE DATABASE MIGRATION FROM MYSL TO PSQL #================================================= -# # If we're moving through version 29.0.3~ynh1 (in which the switch to psql is made) -# if ynh_compare_current_package_version --comparison lt --version 29.0.3~ynh1 -# then -# # Double-check the MySQL DB is here -# if ! mysql -e "USE $db_name" 2>/dev/null -# then -# ynh_print_warn "Uhoh? The Nextcloud MySQL DB doesn't exist? We are supposed to move it to PostgreSQL... Maybe it was already migrated?" -# # Double check the psql is not empty, otherwise big whoops? -# if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] -# then -# ynh_die "Apparently the PostgreSQL DB is also empty, this is kind of worrying, what happened?!" -# else -# ynh_print_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" -# fi -# else -# ynh_print_info --message="Migrating to PostgreSQL database..." -# ynh_exec_warn_less exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n -# ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name -# fi -# fi +# If we're moving through version 29.0.3~ynh1 (in which the switch to psql is made) +if ynh_compare_current_package_version --comparison lt --version 29.0.3~ynh1 +then + # Double-check the MySQL DB is here + if ! mysql -e "USE $db_name" 2>/dev/null + then + ynh_print_warn "Uhoh? The Nextcloud MySQL DB doesn't exist? We are supposed to move it to PostgreSQL... Maybe it was already migrated?" + # Double check the psql is not empty, otherwise big whoops? + if [[ "$(ynh_psql_execute_as_root --database=$db_name --sql="\dt" 2>/dev/null | wc -l)" == 0 ]] + then + ynh_die "Apparently the PostgreSQL DB is also empty, this is kind of worrying, what happened?!" + else + ynh_print_warn "Apparently the PostgreSQL DB is not empty, so this is probably OK?" + fi + else + ynh_print_info --message="Migrating to PostgreSQL database..." + ynh_exec_warn_less exec_occ db:convert-type --all-apps --clear-schema pgsql $db_name 127.0.0.1 $db_name --password=$db_pwd -n + ynh_mysql_remove_db --db_user=$db_user --db_name=$db_name + fi +fi #================================================= # DOWNLOAD, CHECK AND UNPACK SOURCE From d9b99c496db43d6c4c55d21d0cb3334852e640bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Thu, 27 Jun 2024 16:06:12 +0200 Subject: [PATCH 117/127] Update upgrade --- scripts/upgrade | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/upgrade b/scripts/upgrade index 04045f8..a616b8e 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -135,6 +135,8 @@ function list_installed_apps_not_compatible_with_future_version() comm -23 <(comm -23 $installed_apps $core_apps_in_current_version) $nextcloud_destination_appcatalog } +current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) +current_major_version=${current_version%%.*} last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9][0-9]') last_major_version=${last_version%%.*} From 0742c9903d76fb47d6490b422859c25401a6a640 Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Thu, 18 Jul 2024 13:25:24 +0000 Subject: [PATCH 118/127] Auto-update READMEs --- README.md | 2 +- README_es.md | 2 +- README_eu.md | 2 +- README_fr.md | 2 +- README_gl.md | 2 +- README_zh_Hans.md | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index da9c32c..b9dea00 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Shipped version:** 29.0.3~ynh1 +**Shipped version:** 29.0.4~ynh1 **Demo:** diff --git a/README_es.md b/README_es.md index af9d262..b868571 100644 --- a/README_es.md +++ b/README_es.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Versión actual:** 29.0.3~ynh1 +**Versión actual:** 29.0.4~ynh1 **Demo:** diff --git a/README_eu.md b/README_eu.md index 0be7b88..5a1609e 100644 --- a/README_eu.md +++ b/README_eu.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Paketatutako bertsioa:** 29.0.3~ynh1 +**Paketatutako bertsioa:** 29.0.4~ynh1 **Demoa:** diff --git a/README_fr.md b/README_fr.md index cf2fbfb..0b9ec93 100644 --- a/README_fr.md +++ b/README_fr.md @@ -29,7 +29,7 @@ En plus des fonctionnalités principales de Nextcloud, les fonctionnalités suiv * Utilise l'adresse `/.well-known` pour la synchronisation CalDAV et CardDAV du domaine si aucun autre service ne l'utilise déjà - par exemple, Baïkal -**Version incluse :** 29.0.3~ynh1 +**Version incluse :** 29.0.4~ynh1 **Démo :** diff --git a/README_gl.md b/README_gl.md index 6e3bf79..939c2a4 100644 --- a/README_gl.md +++ b/README_gl.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**Versión proporcionada:** 29.0.3~ynh1 +**Versión proporcionada:** 29.0.4~ynh1 **Demo:** diff --git a/README_zh_Hans.md b/README_zh_Hans.md index 1f71c2b..eb9b198 100644 --- a/README_zh_Hans.md +++ b/README_zh_Hans.md @@ -29,7 +29,7 @@ In addition to Nextcloud core features, the following are made available with th * Serve `/.well-known` paths for CalDAV and CardDAV on the domain only if it's not already served - i.e. by Baïkal -**分发版本:** 29.0.3~ynh1 +**分发版本:** 29.0.4~ynh1 **演示:** From 8a090a966260733a16f9f9b91c0daa5d418dd74b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 26 Jul 2024 18:41:37 +0200 Subject: [PATCH 119/127] Update upgrade --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index a616b8e..fa51ffd 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -138,7 +138,7 @@ function list_installed_apps_not_compatible_with_future_version() current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) current_major_version=${current_version%%.*} -last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9][0-9]') +last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9]') last_major_version=${last_version%%.*} if [[ "$last_major_version" != "$current_major_version" ]] From 7d25e4ecaf14da55b9ca6d32cbbc0b43226e13e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Fri, 26 Jul 2024 21:17:53 +0200 Subject: [PATCH 120/127] Update upgrade --- scripts/upgrade | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index fa51ffd..eeab55a 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -39,6 +39,9 @@ filter_boring_occ_warnings() { current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) current_major_version=${current_version%%.*} +last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9]') +last_major_version=${last_version%%.*} + # Define a function to execute commands with `occ` exec_occ() { # Backward compatibility to upgrade from older versions @@ -135,11 +138,11 @@ function list_installed_apps_not_compatible_with_future_version() comm -23 <(comm -23 $installed_apps $core_apps_in_current_version) $nextcloud_destination_appcatalog } -current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) -current_major_version=${current_version%%.*} +#current_version=$(grep OC_VersionString "$install_dir/version.php" | cut -d\' -f2) +#current_major_version=${current_version%%.*} -last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9]') -last_major_version=${last_version%%.*} +#last_version=$(ynh_read_manifest --manifest_key="resources.sources.main.url" | grep -o '[0-9][0-9]\.[0-9]\.[0-9]') +#last_major_version=${last_version%%.*} if [[ "$last_major_version" != "$current_major_version" ]] then From cbc897140148c785460ac99ad7f1575bff76948a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 30 Jul 2024 15:02:02 +0200 Subject: [PATCH 121/127] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index 35f98e8..ee83dd1 100644 --- a/manifest.toml +++ b/manifest.toml @@ -116,7 +116,7 @@ ram.runtime = "512M" api.allowed = ["visitors", "all_users"] [resources.apt] - packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, php8.3-pgsql, php8.3-mysql, php8.3-fpm, php8.3-bz2, php8.3-imap, php8.3-gmp, php8.3-gd, php8.3-intl, php8.3-curl, php8.3-apcu, php8.3-redis, php8.3-ldap, php8.3-imagick, php8.3-zip, php8.3-mbstring, php8.3-xml, php8.3-igbinary, php8.3-bcmath" + packages = "postgresql, imagemagick, libmagickcore-6.q16-6-extra, acl, tar, smbclient, at, redis-server, php8.3-pgsql, php8.3-mysql, php8.3-fpm, php8.3-bz2, php8.3-imap, php8.3-gmp, php8.3-gd, php8.3-intl, php8.3-curl, php8.3-apcu, php8.3-redis, php8.3-ldap, php8.3-imagick, php8.3-zip, php8.3-mbstring, php8.3-xml, php8.3-igbinary, php8.3-bcmath" [resources.database] type = "postgresql" From de7afc994ceff84d112bdb7228209a91a31439e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 30 Jul 2024 15:02:29 +0200 Subject: [PATCH 122/127] Update manifest.toml --- manifest.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.toml b/manifest.toml index ee83dd1..94ada51 100644 --- a/manifest.toml +++ b/manifest.toml @@ -19,7 +19,7 @@ code = "https://github.com/nextcloud/server" cpe = "cpe:2.3:a:nextcloud:nextcloud" [integration] -yunohost = ">= 11.2" +yunohost = ">= 11.2.20" architectures = ["amd64", "arm64", "armhf"] multi_instance = true From f985ed4be92c916bc0963e3d8cd30f2b992c1295 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Sat, 3 Aug 2024 09:46:30 +0200 Subject: [PATCH 123/127] Update _common.sh --- scripts/_common.sh | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index 19c1859..7afbec9 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -9,8 +9,8 @@ #================================================= wait_nginx_reload() { - # Nginx may take some time to support the new configuration, - # wait for the nextcloud configuration file to disappear from nginx before checking the CalDAV/CardDAV URL. + # NGINX may take some time to support the new configuration, + # wait for the Nextcloud configuration file to disappear from NGINX before checking the CalDAV/CardDAV URL. timeout=30 for i in $(seq 1 $timeout); do if ! ynh_exec_warn_less nginx -T | grep --quiet "# configuration file /etc/nginx/conf.d/$domain.d/$app.conf:"; then @@ -18,7 +18,7 @@ wait_nginx_reload() { fi sleep 1 done - # Wait untils nginx has fully reloaded (avoid curl fail with http2) + # Wait untils NGINX has fully reloaded (avoid cURL fail with http2) sleep 2 } @@ -33,22 +33,22 @@ is_url_handled() { # Manage arguments with getopts ynh_handle_getopts_args "$@" - # Try to get the url with curl, and keep the http code and an eventual redirection url. + # Try to get the URL with cURL, and keep the http code and an eventual redirection URL. local curl_output="$(curl --insecure --silent --output /dev/null \ --write-out '%{http_code};%{redirect_url}' https://127.0.0.1$path --header "Host: $domain" --resolve $domain:443:127.0.0.1)" # Cut the output and keep only the first part to keep the http code local http_code="${curl_output%%;*}" - # Do the same thing but keep the second part, the redirection url + # Do the same thing but keep the second part, the redirection URL local redirection="${curl_output#*;}" - # Return 1 if the url isn't handled. - # Which means either curl got a 404 (or the admin) or the sso. - # A handled url should redirect to a publicly accessible url. + # Return 1 if the URL isn't handled. + # Which means either cURL got a 404 (or the admin) or the SSO. + # A handled URL should redirect to a publicly accessible URL. # Return 1 if the url has returned 404 if [ "$http_code" = "404" ] || [[ $redirection =~ "/yunohost/admin" ]]; then return 1 - # Return 1 if the url is redirected to the SSO + # Return 1 if the URL is redirected to the SSO elif [[ $redirection =~ "/yunohost/sso" ]]; then return 1 fi From d8737dbf7366e568f9f82e4b1e08177b3dae697b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 20 Aug 2024 20:30:17 +0200 Subject: [PATCH 124/127] Update manifest.toml --- manifest.toml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/manifest.toml b/manifest.toml index c3b09e0..b3e7d35 100644 --- a/manifest.toml +++ b/manifest.toml @@ -5,7 +5,7 @@ name = "Nextcloud" description.en = "Online storage, file sharing platform and various other applications" description.fr = "Stockage en ligne, plateforme de partage de fichiers et diverses autres applications" -version = "29.0.4~ynh2" +version = "29.0.5~ynh1" maintainers = ["kay0u"] @@ -19,7 +19,7 @@ code = "https://github.com/nextcloud/server" cpe = "cpe:2.3:a:nextcloud:nextcloud" [integration] -yunohost = ">= 11.2.20" +yunohost = ">= 11.2.27" architectures = ["amd64", "arm64", "armhf"] multi_instance = true @@ -65,8 +65,8 @@ ram.runtime = "512M" [resources.sources] [resources.sources.main] - url = 'https://download.nextcloud.com/server/releases/nextcloud-29.0.4.tar.bz2' - sha256 = '19c469e264b31ee80400f8396460854546569e88db4c15fc0854e192f96027eb' + url = 'https://download.nextcloud.com/server/releases/nextcloud-29.0.5.tar.bz2' + sha256 = 'c7fe9c61e5ec30a5e599e8f152a1825df684d30e899db0caa8868c8d67b53a2c' [resources.sources.28] url = 'https://download.nextcloud.com/server/releases/nextcloud-28.0.8.tar.bz2' From a531164d9d6993626677de43f787faee42bcea9d Mon Sep 17 00:00:00 2001 From: yunohost-bot Date: Tue, 20 Aug 2024 18:30:24 +0000 Subject: [PATCH 125/127] Auto-update READMEs --- ALL_README.md | 1 + README.md | 2 +- README_es.md | 2 +- README_eu.md | 2 +- README_fr.md | 2 +- README_gl.md | 2 +- README_id.md | 2 +- README_ru.md | 55 +++++++++++++++++++++++++++++++++++++++++++++++ README_zh_Hans.md | 2 +- 9 files changed, 63 insertions(+), 7 deletions(-) create mode 100644 README_ru.md diff --git a/ALL_README.md b/ALL_README.md index 4ed64dd..e3c80d2 100644 --- a/ALL_README.md +++ b/ALL_README.md @@ -6,4 +6,5 @@ - [Lire le README en français](README_fr.md) - [Le o README en galego](README_gl.md) - [Baca README dalam bahasa bahasa Indonesia](README_id.md) +- [Прочитать README на русский](README_ru.md) - [阅读中文(简体)的 README](README_zh_Hans.md) diff --git a/README.md b/README.md index 81eb8a6..2530f57 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ In the context of YunoHost, Nextcloud integrates with the SSO / user portal (Yun The `/.well-known` address will be automatically configured for CalDAV and CardDAV synchronization if no other service such as Baïkal is already using it. -**Shipped version:** 29.0.4~ynh1 +**Shipped version:** 29.0.5~ynh1 **Demo:** diff --git a/README_es.md b/README_es.md index 9b75f1c..33673b9 100644 --- a/README_es.md +++ b/README_es.md @@ -23,7 +23,7 @@ In the context of YunoHost, Nextcloud integrates with the SSO / user portal (Yun The `/.well-known` address will be automatically configured for CalDAV and CardDAV synchronization if no other service such as Baïkal is already using it. -**Versión actual:** 29.0.4~ynh1 +**Versión actual:** 29.0.5~ynh1 **Demo:** diff --git a/README_eu.md b/README_eu.md index 8b722e4..f657a4a 100644 --- a/README_eu.md +++ b/README_eu.md @@ -23,7 +23,7 @@ In the context of YunoHost, Nextcloud integrates with the SSO / user portal (Yun The `/.well-known` address will be automatically configured for CalDAV and CardDAV synchronization if no other service such as Baïkal is already using it. -**Paketatutako bertsioa:** 29.0.4~ynh1 +**Paketatutako bertsioa:** 29.0.5~ynh1 **Demoa:** diff --git a/README_fr.md b/README_fr.md index f59d583..064a9d9 100644 --- a/README_fr.md +++ b/README_fr.md @@ -23,7 +23,7 @@ Dans le cadre de YunoHost, Nextcloud s'intègre avec le SSO / portail utilisateu L'adresse `/.well-known` sera automatiquement configuré pour la synchronisation CalDAV et CardDAV si aucun autre service tel que Baïkal ne l'utilise déjà. -**Version incluse :** 29.0.4~ynh1 +**Version incluse :** 29.0.5~ynh1 **Démo :** diff --git a/README_gl.md b/README_gl.md index 9a823a3..86d544f 100644 --- a/README_gl.md +++ b/README_gl.md @@ -23,7 +23,7 @@ In the context of YunoHost, Nextcloud integrates with the SSO / user portal (Yun The `/.well-known` address will be automatically configured for CalDAV and CardDAV synchronization if no other service such as Baïkal is already using it. -**Versión proporcionada:** 29.0.4~ynh1 +**Versión proporcionada:** 29.0.5~ynh1 **Demo:** diff --git a/README_id.md b/README_id.md index 71cbfaa..aa9d19a 100644 --- a/README_id.md +++ b/README_id.md @@ -23,7 +23,7 @@ In the context of YunoHost, Nextcloud integrates with the SSO / user portal (Yun The `/.well-known` address will be automatically configured for CalDAV and CardDAV synchronization if no other service such as Baïkal is already using it. -**Versi terkirim:** 29.0.4~ynh1 +**Versi terkirim:** 29.0.5~ynh1 **Demo:** diff --git a/README_ru.md b/README_ru.md new file mode 100644 index 0000000..9442e13 --- /dev/null +++ b/README_ru.md @@ -0,0 +1,55 @@ + + +# Nextcloud для YunoHost + +[![Уровень интеграции](https://dash.yunohost.org/integration/nextcloud.svg)](https://ci-apps.yunohost.org/ci/apps/nextcloud/) ![Состояние работы](https://ci-apps.yunohost.org/ci/badges/nextcloud.status.svg) ![Состояние сопровождения](https://ci-apps.yunohost.org/ci/badges/nextcloud.maintain.svg) + +[![Установите Nextcloud с YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=nextcloud) + +*[Прочтите этот README на других языках.](./ALL_README.md)* + +> *Этот пакет позволяет Вам установить Nextcloud быстро и просто на YunoHost-сервер.* +> *Если у Вас нет YunoHost, пожалуйста, посмотрите [инструкцию](https://yunohost.org/install), чтобы узнать, как установить его.* + +## Обзор + +Nextcloud lets you access and synchronize data, files, contacts and calendars between different devices (PCs or mobiles), or share them with other people (with or without accounts), and also offers advanced communication and collaborative working features. Nextcloud features its own application mechanism (see also [Nextcloud's app store](https://apps.nextcloud.com/)) for specific functionalities. + +In the context of YunoHost, Nextcloud integrates with the SSO / user portal (YunoHost accounts are automatically connected to Nextcloud). + +The `/.well-known` address will be automatically configured for CalDAV and CardDAV synchronization if no other service such as Baïkal is already using it. + + +**Поставляемая версия:** 29.0.5~ynh1 + +**Демо-версия:** + +## Снимки экрана + +![Снимок экрана Nextcloud](./doc/screenshots/screenshot.png) + +## Документация и ресурсы + +- Официальный веб-сайт приложения: +- Официальная документация пользователя: +- Официальная документация администратора: +- Репозиторий кода главной ветки приложения: +- Магазин YunoHost: +- Сообщите об ошибке: + +## Информация для разработчиков + +Пришлите Ваш запрос на слияние в [ветку `testing`](https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing). + +Чтобы попробовать ветку `testing`, пожалуйста, сделайте что-то вроде этого: + +```bash +sudo yunohost app install https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +или +sudo yunohost app upgrade nextcloud -u https://github.com/YunoHost-Apps/nextcloud_ynh/tree/testing --debug +``` + +**Больше информации о пакетировании приложений:** diff --git a/README_zh_Hans.md b/README_zh_Hans.md index 465182e..0d157c0 100644 --- a/README_zh_Hans.md +++ b/README_zh_Hans.md @@ -23,7 +23,7 @@ In the context of YunoHost, Nextcloud integrates with the SSO / user portal (Yun The `/.well-known` address will be automatically configured for CalDAV and CardDAV synchronization if no other service such as Baïkal is already using it. -**分发版本:** 29.0.4~ynh1 +**分发版本:** 29.0.5~ynh1 **演示:** From 294298df8dbb4dde40e95e0f41fabb9bd4371564 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 3 Sep 2024 14:51:44 +0200 Subject: [PATCH 126/127] Update upgrade --- scripts/upgrade | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/upgrade b/scripts/upgrade index c31d60f..88d36e4 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -299,6 +299,12 @@ then # Then remove the config file ynh_secure_remove --file="$nc_conf" + # Occasionally new mimetypes are added to better handle certain file types. + # Migrating the mimetypes take a long time on larger instances + # so this is not done automatically during upgrades. + # Use the command `occ maintenance:repair --include-expensive` to perform the migrations. + exec_occ maintenance:repair --include-expensive + #================================================= # ALLOW USERS TO DISCONNECT FROM NEXTCLOUD #================================================= From 4e0a6356b87550ab134b8c15c3da3e55569086c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 3 Sep 2024 14:58:06 +0200 Subject: [PATCH 127/127] Update upgrade --- scripts/upgrade | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 88d36e4..4c19802 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -302,9 +302,8 @@ then # Occasionally new mimetypes are added to better handle certain file types. # Migrating the mimetypes take a long time on larger instances # so this is not done automatically during upgrades. - # Use the command `occ maintenance:repair --include-expensive` to perform the migrations. exec_occ maintenance:repair --include-expensive - + #================================================= # ALLOW USERS TO DISCONNECT FROM NEXTCLOUD #=================================================