From 0d58dcb2537b39db6d74a47e87b24ce421606d39 Mon Sep 17 00:00:00 2001 From: Cobalt Date: Sun, 18 May 2025 15:16:33 +0200 Subject: [PATCH] flake: bump to nixos-25.05 This references the beta branch. The reference to modules in the dovecot config was also removed. --- flake.lock | 18 +++++++++--------- flake.nix | 10 +++++----- mail-server/dovecot.nix | 14 +++----------- 3 files changed, 17 insertions(+), 25 deletions(-) diff --git a/flake.lock b/flake.lock index a712d89..2ea292c 100644 --- a/flake.lock +++ b/flake.lock @@ -79,11 +79,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1747179050, - "narHash": "sha256-qhFMmDkeJX9KJwr5H32f1r7Prs7XbQWtO0h3V0a0rFY=", + "lastModified": 1747327360, + "narHash": "sha256-LSmTbiq/nqZR9B2t4MRnWG7cb0KVNU70dB7RT4+wYK4=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "adaa24fbf46737f3f1b5497bf64bae750f82942e", + "rev": "e06158e58f3adee28b139e9c2bcfcc41f8625b46", "type": "github" }, "original": { @@ -93,18 +93,18 @@ "type": "github" } }, - "nixpkgs-24_11": { + "nixpkgs-25_05": { "locked": { - "lastModified": 1747209494, - "narHash": "sha256-fLise+ys+bpyjuUUkbwqo5W/UyIELvRz9lPBPoB0fbM=", + "lastModified": 1747428706, + "narHash": "sha256-XVds9FkRrY59xRNNq14FNsFGqDiexXX/mlHcX4hPyyk=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "5d736263df906c5da72ab0f372427814de2f52f8", + "rev": "2e1496bf8652ff4af4e4d4737277f71e4a4f5cb2", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-24.11", + "ref": "nixos-25.05", "repo": "nixpkgs", "type": "github" } @@ -115,7 +115,7 @@ "flake-compat": "flake-compat", "git-hooks": "git-hooks", "nixpkgs": "nixpkgs", - "nixpkgs-24_11": "nixpkgs-24_11" + "nixpkgs-25_05": "nixpkgs-25_05" } } }, diff --git a/flake.nix b/flake.nix index 96ffb21..c3ab357 100644 --- a/flake.nix +++ b/flake.nix @@ -13,14 +13,14 @@ inputs.nixpkgs.follows = "nixpkgs"; }; nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; - nixpkgs-24_11.url = "github:NixOS/nixpkgs/nixos-24.11"; + nixpkgs-25_05.url = "github:NixOS/nixpkgs/nixos-25.05"; blobs = { url = "gitlab:simple-nixos-mailserver/blobs"; flake = false; }; }; - outputs = { self, blobs, git-hooks, nixpkgs, nixpkgs-24_11, ... }: let + outputs = { self, blobs, git-hooks, nixpkgs, nixpkgs-25_05, ... }: let lib = nixpkgs.lib; system = "x86_64-linux"; pkgs = nixpkgs.legacyPackages.${system}; @@ -31,9 +31,9 @@ pkgs = nixpkgs.legacyPackages.${system}; } { - name = "24.11"; - nixpkgs = nixpkgs-24_11; - pkgs = nixpkgs-24_11.legacyPackages.${system}; + name = "25.05"; + nixpkgs = nixpkgs-25_05; + pkgs = nixpkgs-25_05.legacyPackages.${system}; } ]; testNames = [ diff --git a/mail-server/dovecot.nix b/mail-server/dovecot.nix index 6704426..8af4be4 100644 --- a/mail-server/dovecot.nix +++ b/mail-server/dovecot.nix @@ -14,7 +14,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see -{ options, config, pkgs, lib, ... }: +{ config, pkgs, lib, ... }: with (import ./common.nix { inherit config pkgs lib; }); @@ -123,9 +123,6 @@ let dovecotModules = [ pkgs.dovecot_pigeonhole ] ++ lib.optional cfg.fullTextSearch.enable pkgs.dovecot_fts_xapian; - # Remove and assume `false` after NixOS 25.05 - haveDovecotModulesOption = options.services.dovecot2 ? "modules" && (options.services.dovecot2.modules.visible or true); - in { config = with cfg; lib.mkIf enable { @@ -141,12 +138,10 @@ in # which are usually not compatible. environment.systemPackages = [ pkgs.dovecot_pigeonhole - ] ++ lib.optionals (!haveDovecotModulesOption) dovecotModules; + ] ++ dovecotModules; # For compatibility with python imaplib - environment.etc = lib.mkIf (!haveDovecotModulesOption) { - "dovecot/modules".source = "/run/current-system/sw/lib/dovecot/modules"; - }; + environment.etc."dovecot/modules".source = "/run/current-system/sw/lib/dovecot/modules"; services.dovecot2 = lib.mkMerge [{ enable = true; @@ -366,9 +361,6 @@ in lda_mailbox_autocreate = yes ''; } - (lib.mkIf haveDovecotModulesOption { - modules = dovecotModules; - }) ]; systemd.services.dovecot2 = {