From f7011c70f30acf0fe5a229b77e4ad22041b8872e Mon Sep 17 00:00:00 2001 From: Maximilian Bosch Date: Mon, 22 Feb 2021 00:04:23 +0100 Subject: [PATCH] nextcloud21: init at 21.0.0, set as default version ChangeLog: https://nextcloud.com/changelog/#latest21 * Packaged 21.0.0, test-deployed it to my personal instance and tested the most basic functionality (`davfs2`-mount, {card,cal}dav sync, file management). * Bumped the default version for unstable/21.05 to `nextcloud21`. Since `nextcloud20` was added after the release of 20.09 (and thus the default on 20.09 is still `nextcloud19`), it's now needed to upgrade across two majors. This is not a problem though since it's possible to upgrade to v20 on 20.09 already and if not, the module will guard the administrator through the upgrade with eval warnings as it's the case since 20.03. * Dropped `nextcloud17` attribute and marked `nextcloud18` as EOL. --- nixos/doc/manual/release-notes/rl-2105.xml | 8 +++++--- nixos/modules/services/web-apps/nextcloud.nix | 11 +++++----- nixos/modules/services/web-apps/nextcloud.xml | 2 +- pkgs/servers/nextcloud/default.nix | 20 +++++++++---------- pkgs/top-level/all-packages.nix | 2 +- 5 files changed, 22 insertions(+), 21 deletions(-) diff --git a/nixos/doc/manual/release-notes/rl-2105.xml b/nixos/doc/manual/release-notes/rl-2105.xml index ca4b468e355..092068c3d3b 100644 --- a/nixos/doc/manual/release-notes/rl-2105.xml +++ b/nixos/doc/manual/release-notes/rl-2105.xml @@ -552,14 +552,16 @@ self: super: - The default-version of nextcloud is nextcloud20. + The default-version of nextcloud is nextcloud21. Please note that it's not possible to upgrade nextcloud across multiple major versions! This means that it's e.g. not possible to upgrade - from nextcloud18 to nextcloud20 in a single deploy. + from nextcloud18 to nextcloud20 in a single deploy and + most 20.09 users will have to upgrade to nextcloud20 + first. The package can be manually upgraded by setting - to nextcloud20. + to nextcloud21. diff --git a/nixos/modules/services/web-apps/nextcloud.nix b/nixos/modules/services/web-apps/nextcloud.nix index de1c67235f4..413db757357 100644 --- a/nixos/modules/services/web-apps/nextcloud.nix +++ b/nixos/modules/services/web-apps/nextcloud.nix @@ -86,7 +86,7 @@ in { package = mkOption { type = types.package; description = "Which package to use for the Nextcloud instance."; - relatedPackages = [ "nextcloud18" "nextcloud19" "nextcloud20" ]; + relatedPackages = [ "nextcloud19" "nextcloud20" "nextcloud21" ]; }; maxUploadSize = mkOption { @@ -348,7 +348,7 @@ in { ]; warnings = let - latest = 20; + latest = 21; upgradeWarning = major: nixos: '' A legacy Nextcloud install (from before NixOS ${nixos}) may be installed. @@ -366,9 +366,9 @@ in { Using config.services.nextcloud.poolConfig is deprecated and will become unsupported in a future release. Please migrate your configuration to config.services.nextcloud.poolSettings. '') - ++ (optional (versionOlder cfg.package.version "18") (upgradeWarning 17 "20.03")) ++ (optional (versionOlder cfg.package.version "19") (upgradeWarning 18 "20.09")) - ++ (optional (versionOlder cfg.package.version "20") (upgradeWarning 19 "21.05")); + ++ (optional (versionOlder cfg.package.version "20") (upgradeWarning 19 "21.05")) + ++ (optional (versionOlder cfg.package.version "21") (upgradeWarning 20 "21.05")); services.nextcloud.package = with pkgs; mkDefault ( @@ -378,14 +378,13 @@ in { nextcloud defined in an overlay, please set `services.nextcloud.package` to `pkgs.nextcloud`. '' - else if versionOlder stateVersion "20.03" then nextcloud17 else if versionOlder stateVersion "20.09" then nextcloud18 # 21.03 will not be an official release - it was instead 21.05. # This versionOlder statement remains set to 21.03 for backwards compatibility. # See https://github.com/NixOS/nixpkgs/pull/108899 and # https://github.com/NixOS/rfcs/blob/master/rfcs/0080-nixos-release-schedule.md. else if versionOlder stateVersion "21.03" then nextcloud19 - else nextcloud20 + else nextcloud21 ); } diff --git a/nixos/modules/services/web-apps/nextcloud.xml b/nixos/modules/services/web-apps/nextcloud.xml index 6cbfda118c4..83a6f68edcb 100644 --- a/nixos/modules/services/web-apps/nextcloud.xml +++ b/nixos/modules/services/web-apps/nextcloud.xml @@ -11,7 +11,7 @@ desktop client is packaged at pkgs.nextcloud-client. - The current default by NixOS is nextcloud20 which is also the latest + The current default by NixOS is nextcloud21 which is also the latest major version available.
diff --git a/pkgs/servers/nextcloud/default.nix b/pkgs/servers/nextcloud/default.nix index a40dd71fafd..53625941b61 100644 --- a/pkgs/servers/nextcloud/default.nix +++ b/pkgs/servers/nextcloud/default.nix @@ -31,24 +31,19 @@ let }; }; in { - nextcloud17 = throw '' - Nextcloud v17 has been removed from `nixpkgs` as the support for it will be dropped - by upstream within the lifetime of NixOS 20.09[1]. Please upgrade to Nextcloud v18 by + nextcloud18 = throw '' + Nextcloud v18 has been removed from `nixpkgs` as the support for it was dropped + by upstream in 2021-01. Please upgrade to at least Nextcloud v19 by declaring - services.nextcloud.package = pkgs.nextcloud18; + services.nextcloud.package = pkgs.nextcloud19; in your NixOS config. [1] https://docs.nextcloud.com/server/18/admin_manual/release_schedule.html ''; - nextcloud18 = generic { - version = "18.0.10"; - sha256 = "0kv9mdn36shr98kh27969b8xs7pgczbyjklrfskxy9mph7bbzir6"; - eol = true; - }; - + # FIXME(@Ma27) remove on 2021-06 nextcloud19 = generic { version = "19.0.6"; sha256 = "sha256-pqqIayE0OyTailtd2zeYi+G1APjv/YHqyO8jCpq7KJg="; @@ -61,4 +56,9 @@ in { version = "20.0.7"; sha256 = "sha256-jO2Ct3K/CvZ9W+EyPkD5d0KbwKK8yGQJXvx4dnUAtys="; }; + + nextcloud21 = generic { + version = "21.0.0"; + sha256 = "sha256-zq2u72doWhGvxbI7Coa6PHvQp7E41dHswFJiODZV8fA="; + }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 8403e1a925b..adcac4d6a44 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6544,7 +6544,7 @@ in grocy = callPackage ../servers/grocy { }; inherit (callPackage ../servers/nextcloud {}) - nextcloud17 nextcloud18 nextcloud19 nextcloud20; + nextcloud18 nextcloud19 nextcloud20 nextcloud21; nextcloud-client = libsForQt5.callPackage ../applications/networking/nextcloud-client { };