From 06cea073ec4e880c1f2747cf0314664933dd4d67 Mon Sep 17 00:00:00 2001 From: Sridhar Ratnakumar <3998+srid@users.noreply.github.com> Date: Fri, 21 Jun 2024 19:33:55 -0400 Subject: [PATCH] Deployment: `colmena` -> `nixos-flake` (#58) --- flake.lock | 16 ---------------- flake.nix | 44 ++++++-------------------------------------- 2 files changed, 6 insertions(+), 54 deletions(-) diff --git a/flake.lock b/flake.lock index ce5bdac..1b4529f 100644 --- a/flake.lock +++ b/flake.lock @@ -78,21 +78,6 @@ "type": "github" } }, - "colmena-flake": { - "locked": { - "lastModified": 1711493191, - "narHash": "sha256-boxs2M0It0Bh7CGZnEbZJohA+wphXNTjUZ32D9y1KUE=", - "owner": "juspay", - "repo": "colmena-flake", - "rev": "0a9118df5e2e20db9f0e81f273ce906e26a286f3", - "type": "github" - }, - "original": { - "owner": "juspay", - "repo": "colmena-flake", - "type": "github" - } - }, "crane": { "inputs": { "nixpkgs": [ @@ -1050,7 +1035,6 @@ "root": { "inputs": { "actualism-app": "actualism-app", - "colmena-flake": "colmena-flake", "disko": "disko", "flake-parts": "flake-parts_2", "home-manager": "home-manager", diff --git a/flake.nix b/flake.nix index 8f586f1..5dfaf49 100644 --- a/flake.nix +++ b/flake.nix @@ -13,7 +13,6 @@ nixos-flake.url = "github:srid/nixos-flake/deploy"; disko.url = "github:nix-community/disko"; disko.inputs.nixpkgs.follows = "nixpkgs"; - colmena-flake.url = "github:juspay/colmena-flake"; ragenix.url = "github:yaxitech/ragenix"; # Software inputs @@ -38,49 +37,13 @@ imports = [ inputs.treefmt-nix.flakeModule inputs.nixos-flake.flakeModule - inputs.colmena-flake.flakeModules.default + inputs.nixos-flake.flakeModule ./users ./home ./nixos ./nix-darwin ]; - # Colmena deployment configuration - # See https://github.com/juspay/colmena-flake - colmena-flake.deployment = - let - read1Password = field: - [ "op" "read" "op://Personal/nixos-config/${field}" ]; - in - { - immediacy = { - targetHost = "immediacy"; - targetUser = "srid"; - keys."hedgedoc.env" = { - user = "hedgedoc"; - keyCommand = read1Password "hedgedoc.env"; - }; - }; - github-runner = - let - user = "github-runner"; - in - { - targetHost = "github-runner"; - targetUser = "srid"; - keys = { - "github-runner-token.secret" = { - inherit user; - keyCommand = read1Password "github-runner-token"; - }; - "nix-conf-gh-token.secret" = { - user = "root"; - permissions = "0440"; - keyCommand = read1Password "nix-conf-gh-token"; - }; - }; - }; - }; flake = { # Configuration for my M1 Macbook Max (using nix-darwin) @@ -103,6 +66,11 @@ # Flake inputs we want to update periodically # Run: `nix run .#update`. nixos-flake = { + # https://github.com/srid/nixos-flake/pull/54 + deploy = { + enable = true; + sshTarget = "srid@immediacy"; + }; primary-inputs = [ "nixpkgs" "home-manager"