From 3a116c299ed6f050a518ef6beb6445a9076ff19c Mon Sep 17 00:00:00 2001 From: Sridhar Ratnakumar <3998+srid@users.noreply.github.com> Date: Mon, 20 Oct 2025 21:34:56 -0400 Subject: [PATCH] remote builder janitor --- configurations/nixos/pureintent/default.nix | 4 ++++ modules/home/all/buildMachines/default.nix | 4 ++-- modules/home/all/buildMachines/sincereintent.nix | 4 ++-- modules/home/all/nix.nix | 6 ------ 4 files changed, 8 insertions(+), 10 deletions(-) diff --git a/configurations/nixos/pureintent/default.nix b/configurations/nixos/pureintent/default.nix index d26064d..562e127 100644 --- a/configurations/nixos/pureintent/default.nix +++ b/configurations/nixos/pureintent/default.nix @@ -17,6 +17,10 @@ in home-manager.sharedModules = [ "${homeMod}/all/vira.nix" # (self + /modules/home/all/dropbox.nix) + + # Remote builders + "${homeMod}/all/buildMachines" + "${homeMod}/all/buildMachines/sincereintent.nix" ]; nix.settings.sandbox = "relaxed"; diff --git a/modules/home/all/buildMachines/default.nix b/modules/home/all/buildMachines/default.nix index 5ded69e..1703e23 100644 --- a/modules/home/all/buildMachines/default.nix +++ b/modules/home/all/buildMachines/default.nix @@ -1,7 +1,7 @@ -{ pkgs, ... }: +{ pkgs, lib, ... }: { nix = { - package = pkgs.nix; + package = lib.mkDefault pkgs.nix; enable = true; distributedBuilds = true; }; diff --git a/modules/home/all/buildMachines/sincereintent.nix b/modules/home/all/buildMachines/sincereintent.nix index 4b013e8..b9063f1 100644 --- a/modules/home/all/buildMachines/sincereintent.nix +++ b/modules/home/all/buildMachines/sincereintent.nix @@ -15,11 +15,11 @@ mandatoryFeatures = [ ]; # We need this! - sshKey = "/home/srid/.ssh/id_ed25519"; + sshKey = "/home/srid/.ssh/nix-remote-builder"; # This too! # Run on the remote machine: - # nix run nixpkgs#base64 -w0 /etc/ssh/ssh_host_ed25519_key.pub + # , base64 -w0 /etc/ssh/ssh_host_ed25519_key.pub publicHostKey = "c3NoLWVkMjU1MTkgQUFBQUMzTnphQzFsWkRJMU5URTVBQUFBSU82S2Q2OG5LdFlqNVhTaWgveVlteE96M2o0WUdMUGQxUTE1cTF0dUdsZWUgCg=="; } ]; diff --git a/modules/home/all/nix.nix b/modules/home/all/nix.nix index 0e718ed..8ee1c6d 100644 --- a/modules/home/all/nix.nix +++ b/modules/home/all/nix.nix @@ -1,10 +1,4 @@ -{ pkgs, lib, ... }: - { - # Nix configuration is managed globally by nix-darwin. - # Prevent $HOME nix.conf from disrespecting it. - home.file.".config/nix/nix.conf".text = ""; - # Global session path for all shells # Normally, we do this on macOS only. And it is not necessary on NixOS. Yet, # non-NixOS Linux will need it (when using the official Nix installer).