diff --git a/configuration.nix b/configuration.nix index edfb26c..8d2c65e 100644 --- a/configuration.nix +++ b/configuration.nix @@ -41,12 +41,9 @@ in { wget vulnix tree - git file - git-lfs util-linux btop - mkpasswd linuxPackages.perf gitea matrix-synapse-tools.synadm @@ -54,9 +51,6 @@ in { pufferpanel (writeShellScriptBin "pufferpanel-nix" "pufferpanel --workDir /var/lib/pufferpanel $@") - (writeShellScriptBin "nix-referrers" "nix-store --query --referrers $@") - (writeShellScriptBin "silent-add" "git add --intent-to-add $@ ; git update-index --assume-unchanged $@") - (writeShellScriptBin "systemd-owner" "systemctl show -pUser,UID $@") ]; environment.sessionVariables = { diff --git a/flake.lock b/flake.lock index 1a10313..8d820b3 100644 --- a/flake.lock +++ b/flake.lock @@ -106,17 +106,18 @@ "utils": "utils" }, "locked": { - "lastModified": 1706219574, - "narHash": "sha256-qO+8UErk+bXCq2ybHU4GzXG4Ejk4Tk0rnnTPNyypW4g=", - "ref": "refs/heads/master", - "rev": "e47f3719f1db3e0961a4358d4cb234a0acaa7baf", - "revCount": 576, + "lastModified": 1706872533, + "narHash": "sha256-IeIIhd18Tp1oNipwxmRKnLr4dFxl6VUHWykQ1uVYIWE=", + "ref": "Grimmauld-master-patch-84178", + "rev": "bcd01ccb19e29ce8046962cb22ecfaa78bf1bfdd", + "revCount": 577, "type": "git", - "url": "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver" + "url": "https://gitlab.com/Grimmauld/nixos-mailserver" }, "original": { + "ref": "Grimmauld-master-patch-84178", "type": "git", - "url": "https://gitlab.com/simple-nixos-mailserver/nixos-mailserver" + "url": "https://gitlab.com/Grimmauld/nixos-mailserver" } }, "nixos-matrix-modules": { @@ -202,11 +203,11 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1706373441, - "narHash": "sha256-S1hbgNbVYhuY2L05OANWqmRzj4cElcbLuIkXTb69xkk=", + "lastModified": 1706718339, + "narHash": "sha256-S+S97c/HzkO2A/YsU7ZmNF9w2s7Xk6P8dzmfDdckzLs=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "56911ef3403a9318b7621ce745f5452fb9ef6867", + "rev": "53fbe41cf76b6a685004194e38e889bc8857e8c2", "type": "github" }, "original": { @@ -233,11 +234,11 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1706371002, - "narHash": "sha256-dwuorKimqSYgyu8Cw6ncKhyQjUDOyuXoxDTVmAXq88s=", + "lastModified": 1706550542, + "narHash": "sha256-UcsnCG6wx++23yeER4Hg18CXWbgNpqNXcHIo5/1Y+hc=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c002c6aa977ad22c60398daaa9be52f2203d0006", + "rev": "97b17f32362e475016f942bbdfda4a4a72a8a652", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index ee1828c..c82003c 100644 --- a/flake.nix +++ b/flake.nix @@ -13,7 +13,8 @@ flake = true; }; nixos-mailserver = { - url = "git+https://gitlab.com/simple-nixos-mailserver/nixos-mailserver"; +# url = "git+https://gitlab.com/simple-nixos-mailserver/nixos-mailserver"; + url = "git+https://gitlab.com/Grimmauld/nixos-mailserver?ref=Grimmauld-master-patch-84178"; flake = true; }; }; @@ -41,7 +42,8 @@ ./modules/discord-matrix-bridge.nix ./modules/mastodon.nix ./modules/folding.nix - ./modules/ptero.nix + ./modules/toolchains.nix +# ./modules/ptero.nix agenix.nixosModules.default nixos-mailserver.nixosModules.default nixos-matrix-modules.nixosModules.default diff --git a/modules/discord-matrix-bridge.nix b/modules/discord-matrix-bridge.nix index ea3d86f..8441fcc 100644 --- a/modules/discord-matrix-bridge.nix +++ b/modules/discord-matrix-bridge.nix @@ -22,11 +22,16 @@ in { enableSelfServiceBridging = true; domain = root_host; homeserverUrl = "https://${root_host}"; + disablePresence = true; + disableTypingNotifications = true; }; + logging.console = "silly"; }; + serviceDependencies = ["matrix-synapse.target"]; port = bridge_port; - localpart = "_discord_bot"; + localpart = "_discord_"; package = pkgs.matrix-appservice-discord; environmentFile = config.age.secrets.matrix_discord_bridge_token.path; }; } + diff --git a/modules/email.nix b/modules/email.nix index dcb252e..ed4c2bf 100644 --- a/modules/email.nix +++ b/modules/email.nix @@ -5,7 +5,7 @@ let in { security.acme.certs."${root_host}".extraDomainNames = [ mail_host ]; - services.dovecot2.sieve.extensions = [ "fileinto" ]; # sives break without this for some reason +# services.dovecot2.sieve.extensions = [ "fileinto" ]; # sives break without this for some reason mailserver = { enable = true; fqdn = mail_host; @@ -21,6 +21,9 @@ in { "admin@${root_host}" = { hashedPasswordFile = ./mailpass/admin; }; + "grimmauld@${root_host}" = { + hashedPasswordFile = ./mailpass/grimmauld; + }; }; # Use Let's Encrypt certificates. Note that this needs to set up a stripped diff --git a/modules/mailpass/grimmauld b/modules/mailpass/grimmauld new file mode 100644 index 0000000..8e2798c --- /dev/null +++ b/modules/mailpass/grimmauld @@ -0,0 +1 @@ +$2b$05$nmY9QnYyOhhhXn3OOalxkeWWLZtlaxD2vGwr0f6gtHNUz5EfZXvsa diff --git a/modules/toolchains.nix b/modules/toolchains.nix new file mode 100644 index 0000000..3b8fef4 --- /dev/null +++ b/modules/toolchains.nix @@ -0,0 +1,49 @@ +{config, pkgs, ...}: let + git_user = "Grimmauld"; +in { + environment.systemPackages = with pkgs; [ + (writeShellScriptBin "silent-add" "git add --intent-to-add $@ ; git update-index --assume-unchanged $@") + (writeShellScriptBin "systemd-owner" "systemctl show -pUser,UID $@") + (writeShellScriptBin "nix-referrers" "nix-store --query --referrers $@") + mkpasswd + ]; + + programs.git = { + enable = true; + lfs.enable = true; + config = { + init.defaultBranch = "main"; + credential.username = git_user; + core.editor = "${pkgs.neovim}/bin/nvim"; + user.name = git_user; + user.email = "${git_user}@grimmauld.de"; + }; + }; + + programs.tmux = { + enable = true; + historyLimit = 42000; + #keyMode = "vi"; + }; + + programs.neovim = { + enable = true; + viAlias = true; + defaultEditor = true; + configure = { + customRC = '' + set number + set hidden + set nocompatible + ''; + packages.myVimPackage = with pkgs.vimPlugins; { + # loaded on launch + start = [ vim-nix vim-scala fugitive autoclose-nvim ]; + # manually loadable by calling `:packadd $plugin-name` + opt = [ ]; + }; + }; + }; + + programs.xonsh.enable = true; +}