From 078e695f13fbbc1fb39f73787e028661408efc73 Mon Sep 17 00:00:00 2001 From: Aaron Bieber Date: Thu, 28 Mar 2024 11:46:44 -0600 Subject: [PATCH] h: switch to mcchunkie flake - remove pkgs/mcchunkie --- flake.lock | 21 +++++++++++++++++++++ flake.nix | 8 +++++++- hosts/h/default.nix | 21 +-------------------- pkgs/mcchunkie.nix | 32 -------------------------------- 4 files changed, 29 insertions(+), 53 deletions(-) delete mode 100644 pkgs/mcchunkie.nix diff --git a/flake.lock b/flake.lock index b3762db..398dec1 100644 --- a/flake.lock +++ b/flake.lock @@ -202,6 +202,26 @@ "type": "github" } }, + "mcchunkie": { + "inputs": { + "nixpkgs": [ + "unstable" + ] + }, + "locked": { + "lastModified": 1711641721, + "narHash": "sha256-/C5ibcEv9QodpxSTa6G2MMzWVKjoUX9tPJTEMBcsaV8=", + "owner": "qbit", + "repo": "mcchunkie", + "rev": "d41b55e44c41824d11f85bfeb0637aa061dbfbc0", + "type": "github" + }, + "original": { + "owner": "qbit", + "repo": "mcchunkie", + "type": "github" + } + }, "microca": { "inputs": { "nixpkgs": [ @@ -364,6 +384,7 @@ "gostart": "gostart", "gqrss": "gqrss", "kogs": "kogs", + "mcchunkie": "mcchunkie", "microca": "microca", "nixos-hardware": "nixos-hardware", "peerix": "peerix", diff --git a/flake.nix b/flake.nix index 845cf75..d363a5a 100644 --- a/flake.nix +++ b/flake.nix @@ -47,6 +47,10 @@ nixos-hardware.url = "github:NixOS/nixos-hardware/master"; + mcchunkie = { + url = "github:qbit/mcchunkie"; + inputs.nixpkgs.follows = "unstable"; + }; microca = { url = "github:qbit/microca"; inputs.nixpkgs.follows = "unstable"; @@ -111,6 +115,7 @@ { self , darwin , gostart + , mcchunkie , kogs , peerix , po @@ -159,6 +164,7 @@ overlays = [ inputs.emacs-overlay.overlay inputs.gostart.overlay + inputs.mcchunkie.overlay inputs.kogs.overlay inputs.microca.overlay inputs.peerix.overlay @@ -253,6 +259,7 @@ h = buildSys "x86_64-linux" stable [ ./configs/hardened.nix gostart.nixosModule + mcchunkie.nixosModule kogs.nixosModule pots.nixosModule pr-status.nixosModule @@ -329,7 +336,6 @@ flake-warn = spkgs.callPackage ./pkgs/flake-warn.nix { inherit spkgs; }; #kurinto = spkgs.callPackage ./pkgs/kurinto.nix {}; - mcchunkie = spkgs.callPackage ./pkgs/mcchunkie.nix { inherit spkgs; }; yaegi = spkgs.callPackage ./pkgs/yaegi.nix { inherit spkgs; }; gen-patches = spkgs.callPackage ./bins/gen-patches.nix { inherit spkgs; }; diff --git a/hosts/h/default.nix b/hosts/h/default.nix index fae69d5..1069816 100644 --- a/hosts/h/default.nix +++ b/hosts/h/default.nix @@ -7,7 +7,6 @@ with pkgs; let gqrss = callPackage ../../pkgs/gqrss.nix { inherit isUnstable; }; icbirc = callPackage ../../pkgs/icbirc.nix { inherit isUnstable; }; - mcchunkie = callPackage ../../pkgs/mcchunkie.nix { inherit isUnstable; }; slidingSyncPkg = callPackage ../../pkgs/sliding-sync.nix { }; weepushover = python3Packages.callPackage ../../pkgs/weepushover.nix { inherit pkgs; }; @@ -239,7 +238,6 @@ in # matrix things matrix-synapse-tools.synadm matrix-synapse-tools.rust-synapse-compress-state - mcchunkie zonemaster-cli sqlite @@ -257,14 +255,7 @@ in users = { root = userBase; qbit = userBase; - mcchunkie = { - createHome = true; - isSystemUser = true; - home = "/var/lib/mcchunkie"; - group = "mcchunkie"; - }; }; - groups.mcchunkie = { }; }; systemd = { @@ -290,17 +281,6 @@ in ExecStart = "${icbIrcTunnel}/bin/icb-irc-tunnel"; }; }; - - mcchunkie = { - wantedBy = [ "multi-user.target" ]; - serviceConfig = { - User = "mcchunkie"; - Group = "mcchunkie"; - Restart = "always"; - WorkingDirectory = "/var/lib/mcchunkie"; - ExecStart = "${mcchunkie}/bin/mcchunkie"; - }; - }; }; }; @@ -329,6 +309,7 @@ in }; services = { + mcchunkie.enable = true; wallabag = { enable = false; secretPath = config.sops.secrets.wallabag_secret.path; diff --git a/pkgs/mcchunkie.nix b/pkgs/mcchunkie.nix deleted file mode 100644 index a3524b3..0000000 --- a/pkgs/mcchunkie.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ lib -, buildGoModule -, fetchFromGitHub -, ... -}: -with lib; -buildGoModule rec { - pname = "mcchunkie"; - version = "1.0.14"; - - src = fetchFromGitHub { - owner = "qbit"; - repo = pname; - rev = "v${version}"; - hash = "sha256-biKmKulVV4ed0x/3KLESNDXBkihk7OlPcQPeAZmVNPU="; - }; - - vendorHash = "sha256-OGSJeyGxXdKCD7nNRsJcKEKqBQOBKEc6RdtJfoIgR+0="; - - ldflags = [ "-X suah.dev/mcchunkie/plugins.version=${version}" ]; - - proxyVendor = true; - - doCheck = false; - - meta = { - description = "Matrix Bot"; - homepage = "https://github.com/qbit/mcchunkie"; - license = licenses.mit; - maintainers = with maintainers; [ qbit ]; - }; -}