diff --git a/flake.nix b/flake.nix index 0b257e3..bb39e13 100644 --- a/flake.nix +++ b/flake.nix @@ -12,29 +12,55 @@ outputs = { nixpkgs, nixvim, ... }: { - nixosConfigurations = ( - let - hosts = builtins.attrNames (builtins.readDir ./hosts); - in - builtins.listToAttrs ( - map ( - host: - nixpkgs.lib.nameValuePair host ( - nixpkgs.lib.nixosSystem { - specialArgs = { - nixpkgs-flake = nixpkgs; - inherit nixvim; - }; - system = "x86_64-linux"; - modules = [ - { networking.hostName = host; } - ./hosts/${host}/configuration.nix - ./hosts/${host}/state.nix - ]; - } - ) - ) hosts + nixosConfigurations = + ( + let + x86_64-hosts = builtins.filter (file: file != "aarch64-linux") ( + builtins.attrNames (builtins.readDir ./hosts) + ); + in + builtins.listToAttrs ( + map ( + host: + nixpkgs.lib.nameValuePair host ( + nixpkgs.lib.nixosSystem { + specialArgs = { + nixpkgs-flake = nixpkgs; + inherit nixvim; + }; + system = "x86_64-linux"; + modules = [ + { networking.hostName = host; } + ./hosts/${host}/configuration.nix + ./hosts/${host}/state.nix + ]; + } + ) + ) x86_64-hosts + ) ) - ); + // ( + let + aarch64-linux-hosts = (builtins.attrNames (builtins.readDir ./hosts/aarch64-linux)); + in + builtins.listToAttrs ( + map ( + host: + nixpkgs.lib.nameValuePair host ( + nixpkgs.lib.nixosSystem { + specialArgs = { + nixpkgs-flake = nixpkgs; + inherit nixvim; + }; + system = "aarch64-linux"; + modules = [ + { networking.hostName = host; } + ./hosts/aarch64-linux${host}/configuration.nix + ]; + } + ) + ) aarch64-linux-hosts + ) + ); }; } diff --git a/hosts/wg-rpi/configuration.nix b/hosts/aarch64-linux/wg-rpi/configuration.nix similarity index 97% rename from hosts/wg-rpi/configuration.nix rename to hosts/aarch64-linux/wg-rpi/configuration.nix index afe65be..76be4d4 100644 --- a/hosts/wg-rpi/configuration.nix +++ b/hosts/aarch64-linux/wg-rpi/configuration.nix @@ -4,11 +4,11 @@ let # SSIDpassword = "ENTER_PASSWORD"; # interface = "wlan0"; wg_interface = "end0"; - hostname = "netflix-huijaus"; + hostname = "wg-rpi"; ddPassFile = "/root/wg-conf/ddPassFile"; in { - imports = [ ../../shared/base.nix ]; + imports = [ ../../../shared/base.nix ]; environment.systemPackages = with pkgs; [ wireguard-tools @@ -94,6 +94,7 @@ in passwordFile = ddPassFile; }; #################### EVERYTHING BELOW THIS SHOULD NOT NEED TO CHANGE #################### + system.stateVersion = "24.11"; nix.settings = { cores = 3;