From dd76c6a5eb5fccdc8d7e3fd8298dd8feb5eba38a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20B=C3=A4dorf?= Date: Sat, 4 Feb 2023 14:40:05 +0100 Subject: [PATCH] Working with local mailman module override --- flake.lock | 25 +++++++++++++++++++------ flake.nix | 3 +++ hosts/flora-6/flora-6.nix | 3 +++ hosts/flora-6/mailman.nix | 12 ++++++++++++ overlays/overrides.nix | 5 +++++ 5 files changed, 42 insertions(+), 6 deletions(-) diff --git a/flake.lock b/flake.lock index 5afcac8c..aced2e8e 100644 --- a/flake.lock +++ b/flake.lock @@ -299,11 +299,11 @@ }, "latest": { "locked": { - "lastModified": 1675115703, - "narHash": "sha256-4zetAPSyY0D77x+Ww9QBe8RHn1akvIvHJ/kgg8kGDbk=", + "lastModified": 1675362331, + "narHash": "sha256-VmcnKPj5gJLxWK7Bxlhg2LoQvhKRss7Ax+uoFjd3qKY=", "owner": "nixos", "repo": "nixpkgs", - "rev": "2caf4ef5005ecc68141ecb4aac271079f7371c44", + "rev": "a100acd7bbf105915b0004427802286c37738fef", "type": "github" }, "original": { @@ -313,13 +313,25 @@ "type": "github" } }, + "local": { + "locked": { + "lastModified": 1675517877, + "narHash": "sha256-I345MML405WkdyPGaDQxXTHnWD1kNoAH6LmUlM/omiE=", + "path": "/home/ben/Workspace/nixpkgs", + "type": "path" + }, + "original": { + "path": "/home/ben/Workspace/nixpkgs", + "type": "path" + } + }, "nixos": { "locked": { - "lastModified": 1675154384, - "narHash": "sha256-gUXzyTS3WsO3g2Rz0qOYR2a26whkyL2UfTr1oPH9mm8=", + "lastModified": 1675410244, + "narHash": "sha256-ODj6egMoH/HgAF/0wIy0EfRBeUx5FMuLl6uAdUW3kCI=", "owner": "nixos", "repo": "nixpkgs", - "rev": "0218941ea68b4c625533bead7bbb94ccce52dceb", + "rev": "f7543a7539a007e9562e4d8d24e17a4bcf369b68", "type": "github" }, "original": { @@ -382,6 +394,7 @@ "home": "home", "keycloak-theme-pub-solar": "keycloak-theme-pub-solar", "latest": "latest", + "local": "local", "nixos": "nixos", "nixos-hardware": "nixos-hardware", "nur": "nur", diff --git a/flake.nix b/flake.nix index c2d2840f..b91bf096 100644 --- a/flake.nix +++ b/flake.nix @@ -10,6 +10,8 @@ nixos.url = "github:nixos/nixpkgs/nixos-22.11"; latest.url = "github:nixos/nixpkgs/nixos-unstable"; + local.url = "path:/home/ben/Workspace/nixpkgs"; + flake-compat.url = "github:edolstra/flake-compat"; flake-compat.flake = false; @@ -73,6 +75,7 @@ overlays = []; }; latest = {}; + local = {}; }; lib = import ./lib {lib = digga.lib // nixos.lib;}; diff --git a/hosts/flora-6/flora-6.nix b/hosts/flora-6/flora-6.nix index d7c59716..39e409bc 100644 --- a/hosts/flora-6/flora-6.nix +++ b/hosts/flora-6/flora-6.nix @@ -1,6 +1,7 @@ { config, latestModulesPath, + localModulesPath, lib, inputs, pkgs, @@ -26,9 +27,11 @@ in { profiles.users.barkeeper "${latestModulesPath}/services/misc/gitea.nix" + "${localModulesPath}/services/mail/mailman.nix" ]; disabledModules = [ "services/misc/gitea.nix" + "services/mail/mailman.nix" ]; config = { diff --git a/hosts/flora-6/mailman.nix b/hosts/flora-6/mailman.nix index a007c971..df71916a 100644 --- a/hosts/flora-6/mailman.nix +++ b/hosts/flora-6/mailman.nix @@ -33,6 +33,18 @@ in { hyperkitty.enable = true; webHosts = ["list.pub.solar"]; siteOwner = "admins@pub.solar"; + extraPythonPackages = ps: + with ps; [ + (buildPythonPackage rec { + pname = "django-keycloak"; + version = "0.1.1"; + src = fetchPypi { + inherit pname version; + sha256 = "sha256-YoT+fi1w8e4tGW4nK7QmK+WBFQ+IlNXo64FSp0ff/aM="; + }; + doCheck = false; + }) + ]; }; # TODO add django-keycloak as auth provider diff --git a/overlays/overrides.nix b/overlays/overrides.nix index 5650deda..4938df63 100644 --- a/overlays/overrides.nix +++ b/overlays/overrides.nix @@ -21,6 +21,11 @@ channels: final: prev: { gitea ; + inherit + (channels.local) + mailmanPackages + ; + haskellPackages = prev.haskellPackages.override (old: {