diff options
Diffstat (limited to 'flake.nix')
| -rw-r--r-- | flake.nix | 126 |
1 files changed, 86 insertions, 40 deletions
@@ -54,49 +54,95 @@ url = "github:Mic92/sops-nix"; inputs.nixpkgs.follows = "nixpkgs"; }; - # hytale-launcher = { - # url = "github:TNAZEP/HytaleLauncherFlake"; - # inputs.nixpkgs.follows = "nixpkgs"; - # }; + deploy-rs = { + url = "github:serokell/deploy-rs"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + nixos-mailserver = { + url = "gitlab:simple-nixos-mailserver/nixos-mailserver/nixos-26.05"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + claude-desktop = { + url = "github:aaddrick/claude-desktop-debian"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + neodrive-website = { + url = "github:BossCode45/neodrive-website"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + + # hytale-launcher = { + # url = "github:TNAZEP/HytaleLauncherFlake"; + # inputs.nixpkgs.follows = "nixpkgs"; + # }; }; - outputs = inputs@{self, nixpkgs, ... }: { - nixosConfigurations = { - nixy = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = {inherit inputs;}; - modules = [ - ./my-pkgs - ./modules - - ./hardware-setups/tuf.nix - ./computers/nixy.nix - - inputs.home-manager.nixosModules.home-manager - { - home-manager.useGlobalPkgs = true; - home-manager.useUserPackages = true; + outputs = inputs@{self, nixpkgs, ... }: let + system = "x86_64-linux"; + pkgs = import nixpkgs { inherit system; }; + deployPkgs = import nixpkgs { + inherit system; + overlays = [ + inputs.deploy-rs.overlays.default # or deploy-rs.overlays.default + (self: super: { deploy-rs = { inherit (pkgs) deploy-rs; lib = super.deploy-rs.lib; }; }) + ]; + }; + in + { + nixosConfigurations = { + nixy = nixpkgs.lib.nixosSystem { + system = "x86_64-linux"; + specialArgs = {inherit inputs;}; + modules = [ + ./my-pkgs + ./modules + + ./hardware-setups/tuf.nix + ./computers/nixy.nix - home-manager.users.boss = import ./home-manager/home.nix; - home-manager.extraSpecialArgs = {inherit inputs;}; - } + { + environment.systemPackages = [ + deployPkgs.deploy-rs.deploy-rs + ]; + } + + inputs.home-manager.nixosModules.home-manager + { + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; - inputs.stylix.nixosModules.stylix - ]; - }; - nixnode = nixpkgs.lib.nixosSystem { - system = "x86_64-linux"; - specialArgs = {inherit inputs;}; - modules = [ - ./modules - ./hardware-setups/linode.nix - ./computers/nixnode.nix - ]; - }; - }; - - packages.x86_64-linux.teh-website = (nixpkgs.legacyPackages.x86_64-linux.callPackage ./website { }); - packages.x86_64-linux.stk-installers = (nixpkgs.legacyPackages.x86_64-linux.callPackage ./my-pkgs/stk-installers.nix { }); - }; + home-manager.users.boss = import ./home-manager/home.nix; + home-manager.extraSpecialArgs = {inherit inputs;}; + } + + inputs.stylix.nixosModules.stylix + ]; + }; + nixnode = nixpkgs.lib.nixosSystem { + system = "x86_64-linux"; + specialArgs = {inherit inputs;}; + modules = [ + ./modules + ./hardware-setups/linode.nix + ./computers/nixnode.nix + ]; + }; + }; + + deploy.nodes.nixnode = { + hostname = "tehbox.org"; + profiles.system = { + user = "root"; + sshUser = "boss"; + interactiveSudo = true; + path = deployPkgs.deploy-rs.lib.activate.nixos self.nixosConfigurations.nixnode; + }; + }; + + checks = builtins.mapAttrs (system: deployLib: deployLib.deployChecks self.deploy) inputs.deploy-rs.lib; + + packages.x86_64-linux.teh-website = (nixpkgs.legacyPackages.x86_64-linux.callPackage ./website { }); + packages.x86_64-linux.stk-installers = (nixpkgs.legacyPackages.x86_64-linux.callPackage ./my-pkgs/stk-installers.nix { }); + }; } |
