From 6f7bd5ba50978ccaf853a091940ddd8434674b0b Mon Sep 17 00:00:00 2001 From: John Bargman Date: Wed, 15 Apr 2026 05:13:42 +0000 Subject: add remote-command app for SSH execution on crash-over-burn-1 Usage: nix run .#remote-command -- "" Deploy user: commander@193.16.42.36:1108--- flake.nix | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) (limited to 'flake.nix') diff --git a/flake.nix b/flake.nix index fa7ee5d..9667b90 100644 --- a/flake.nix +++ b/flake.nix @@ -22,7 +22,25 @@ in { formatter.x86_64-linux = pkgs.nixpkgs-fmt; - apps.x86_64-linux = (nixinate.lib.genDeploy.x86_64-linux self) // ({ secrix = secrix self; }); + apps.x86_64-linux = + let + remote = { + host = "193.16.42.36"; + port = 1108; + user = "commander"; + }; + remoteCmd = pkgs.writeScriptBin "remote-cmd" '' + #!${pkgs.runtimeShell} + exec ${pkgs.openssh}/bin/ssh -p ${toString remote.port} -o StrictHostKeyChecking=accept-new ${remote.user}@${remote.host} "$@" + ''; + in + (nixinate.lib.genDeploy.x86_64-linux self) // { + secrix = secrix self; + remote-command = { + type = "app"; + program = "${remoteCmd}/bin/remote-cmd"; + }; + }; devShells.x86_64-linux.default = pkgs.mkShell { buildInputs = with pkgs; [ figlet tmux ]; -- cgit v1.2.3