diff options
| author | seth <[email protected]> | 2023-11-14 23:21:10 -0500 |
|---|---|---|
| committer | seth <[email protected]> | 2023-11-15 01:54:45 -0500 |
| commit | 6cce6f2211910a668976442cf66608b4fb780611 (patch) | |
| tree | f0d7b43773114cbabca1280f0626eb0d5a29e4b6 /systems | |
| parent | b450cfc9937966ffca2fa71a63ddca8be6af8ae1 (diff) | |
Revert "systems: nixinate -> deploy-rs (again)"
This reverts commit f281097023293a482498412d3760f350663b7314.
Revert "ci: fix typo in deploy nix develop command"
This reverts commit 2f15e8997f3086a1dc0fc6f472b46aaee11c98bf.
Diffstat (limited to 'systems')
| -rw-r--r-- | systems/atlas/default.nix | 8 | ||||
| -rw-r--r-- | systems/default.nix | 8 | ||||
| -rw-r--r-- | systems/deploy.nix | 43 |
3 files changed, 12 insertions, 47 deletions
diff --git a/systems/atlas/default.nix b/systems/atlas/default.nix index e8c28e3..d241658 100644 --- a/systems/atlas/default.nix +++ b/systems/atlas/default.nix @@ -9,6 +9,14 @@ ./nginx.nix ]; + _module.args.nixinate = { + host = "atlas"; + sshUser = "root"; + buildOn = "remote"; + substituteOnTarget = true; + hermetic = false; + }; + age.secrets.teawiebot.file = ../../secrets/systems/atlas/teawieBot.age; boot = { diff --git a/systems/default.nix b/systems/default.nix index 5c6703e..023dc59 100644 --- a/systems/default.nix +++ b/systems/default.nix @@ -24,10 +24,6 @@ mapNixOS = mapSystems inputs.nixpkgs.lib.nixosSystem; inherit (import ./common.nix {inherit inputs self;}) darwin nixos server; in { - imports = [ - ./deploy.nix - ]; - flake = { darwinConfigurations = mapDarwin { caroline = { @@ -76,4 +72,8 @@ in { inherit (inputs) openwrt-imagebuilder; }); }; + + perSystem = {system, ...}: { + apps = (inputs.nixinate.nixinate.${system} self).nixinate; + }; } diff --git a/systems/deploy.nix b/systems/deploy.nix deleted file mode 100644 index 186ff37..0000000 --- a/systems/deploy.nix +++ /dev/null @@ -1,43 +0,0 @@ -{ - lib, - inputs, - self, - ... -}: let - targets = ["atlas"]; - - getDeploy = pkgs: - (import pkgs.path { - inherit (pkgs) system; - overlays = [ - inputs.deploy.overlay - (_: prev: { - deploy-rs = { - inherit (pkgs) deploy-rs; - inherit (prev.deploy-rs) lib; - }; - }) - ]; - }) - .deploy-rs; - - getType = pkgs: - if pkgs.stdenv.isDarwin - then "darwin" - else "nixos"; - - toDeployNode = hostname: system: { - sshUser = "root"; - inherit hostname; - profiles.system.path = (getDeploy system.pkgs).lib.activate.${getType system.pkgs} system; - }; -in { - flake.deploy = { - remoteBuild = true; - fastConnection = false; - nodes = lib.pipe (self.nixosConfigurations // self.darwinConfigurations) [ - (lib.getAttrs targets) - (lib.mapAttrs toDeployNode) - ]; - }; -} |
