aboutsummaryrefslogtreecommitdiff
path: root/modules/deploy.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/deploy.nix')
-rw-r--r--modules/deploy.nix49
1 files changed, 49 insertions, 0 deletions
diff --git a/modules/deploy.nix b/modules/deploy.nix
new file mode 100644
index 0000000..14e3315
--- /dev/null
+++ b/modules/deploy.nix
@@ -0,0 +1,49 @@
+{
+ inputs,
+ self,
+ withSystem,
+ config,
+ ...
+}: {
+ perSystem = {
+ pkgs,
+ self',
+ system,
+ ...
+ }: let
+ deployPkgs = import inputs.nixpkgs {
+ inherit system;
+ overlays = [
+ inputs.deploy-rs.overlays.default
+ (self: super: {
+ deploy-rs = {
+ inherit (pkgs) deploy-rs;
+ lib = super.deploy-rs.lib;
+ };
+ })
+ ];
+ };
+ in {
+ _module.args = {
+ inherit deployPkgs;
+ };
+ };
+ flake.deploy.nodes = {
+ ltrr-block = {
+ hostname = "ltrr-block";
+ profiles.system = {
+ user = "root";
+ path = withSystem "x86_64-linux" ({deployPkgs, ...}: deployPkgs.deploy-rs.lib.activate.nixos self.nixosConfigurations.ltrr-block);
+ };
+ sshUser = "root";
+ };
+ ltrr-cloud = {
+ hostname = "kcu.su";
+ profiles.system = {
+ user = "root";
+ path = withSystem "x86_64-linux" ({deployPkgs, ...}: deployPkgs.deploy-rs.lib.activate.nixos self.nixosConfigurations.ltrr-cloud);
+ };
+ sshUser = "root";
+ };
+ };
+}