summary refs log tree commit diff
path: root/nixos/modules/services/search
diff options
context:
space:
mode:
authorAaron Andersen <aaron@fosslib.net>2019-03-28 10:47:41 -0400
committerAaron Andersen <aaron@fosslib.net>2019-04-10 20:12:41 -0400
commitee7565af9d811526b4abd33c900104cb514c25e1 (patch)
treeb2c1a63f9183ec7da9a82766232e7f9e5326ea2e /nixos/modules/services/search
parentbd50fc942be4a648dfb3a11a848dbd2920358035 (diff)
downloadnixpkgs-ee7565af9d811526b4abd33c900104cb514c25e1.tar
nixpkgs-ee7565af9d811526b4abd33c900104cb514c25e1.tar.gz
nixpkgs-ee7565af9d811526b4abd33c900104cb514c25e1.tar.bz2
nixpkgs-ee7565af9d811526b4abd33c900104cb514c25e1.tar.lz
nixpkgs-ee7565af9d811526b4abd33c900104cb514c25e1.tar.xz
nixpkgs-ee7565af9d811526b4abd33c900104cb514c25e1.tar.zst
nixpkgs-ee7565af9d811526b4abd33c900104cb514c25e1.zip
solr: init at 8.0.0
Diffstat (limited to 'nixos/modules/services/search')
-rw-r--r--nixos/modules/services/search/solr.nix12
1 files changed, 10 insertions, 2 deletions
diff --git a/nixos/modules/services/search/solr.nix b/nixos/modules/services/search/solr.nix
index 7200c40e89f..6659cc8a2d1 100644
--- a/nixos/modules/services/search/solr.nix
+++ b/nixos/modules/services/search/solr.nix
@@ -13,11 +13,19 @@ in
     services.solr = {
       enable = mkEnableOption "Enables the solr service.";
 
+      # default to the 8.x series not forcing major version upgrade of those on the 7.x series
       package = mkOption {
         type = types.package;
-        default = pkgs.solr;
+        default = if versionAtLeast config.system.stateVersion "19.09"
+          then pkgs.solr_8
+          else pkgs.solr_7
+        ;
         defaultText = "pkgs.solr";
-        description = "Which Solr package to use.";
+        description = ''
+          Which Solr package to use. This defaults to version 7.x if
+          <literal>system.stateVersion &lt; 19.09</literal> and version 8.x
+          otherwise.
+        '';
       };
 
       port = mkOption {