serokell / deploy-rs

A simple multi-profile Nix-flake deploy tool.
Other
1.41k stars 101 forks source link

Can I set different build flag for different remote machine? #302

Open amalgame21 opened 1 week ago

amalgame21 commented 1 week ago

I am using deploy-rs to deploy raspberry pi I am unable to configure cross-compiling ( qemu method too slow , nixpkgs.buildPlatform / nixpkgs.hostPlatform don't pull binary cache), so I set remoteBuild = true; instead. But I still want to deploy with --max-job 1 --cores 1 flag because sometimes it ran out of ram and abort. I know that I can run deploy .#pi -- --max-job 1 --cores 1, but I want a single command solution for all host. like deploy . to deploy all remote server, deploy --targets .#pi .#other-host for others, I can use one command to take care or multiple servers.

It would be great if we can set it in the flake.

sedlund commented 1 week ago

Configure your system:

nix.settings.cores nix.settings.max-jobs

I suggest you get on matrix chat for help.