From db7b05a46e1ab00308f6bf5c65c1a1c0a44e4a66 Mon Sep 17 00:00:00 2001 From: Dan Date: Sat, 10 Jan 2026 16:07:13 -0800 Subject: [PATCH] Pin PostgreSQL to v15 for NixOS 24.11 upgrade Prevents automatic upgrade to PostgreSQL 16 when upgrading NixOS. This allows a safer two-step approach: upgrade NixOS first, then pg_upgrade later. Co-Authored-By: Claude Opus 4.5 --- modules/dev-services.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/dev-services.nix b/modules/dev-services.nix index d7c9c9b..caa2370 100644 --- a/modules/dev-services.nix +++ b/modules/dev-services.nix @@ -1,5 +1,5 @@ # Development services module - Matrix, Forgejo, and Slack bridge -{ config, pkgs-unstable, lib, ... }: +{ config, pkgs, pkgs-unstable, lib, ... }: with lib; @@ -99,8 +99,10 @@ in config = mkIf cfg.enable { # PostgreSQL for Forgejo and bridge services (Matrix uses RocksDB) + # Pin to v15 to prevent auto-upgrade to v16 in NixOS 24.11 services.postgresql = { enable = true; + package = pkgs.postgresql_15; ensureDatabases = [ "forgejo" ] ++ optional cfg.slackBridge.enable "mautrix_slack";