diff options
| author | seth <[email protected]> | 2023-07-23 20:24:44 -0400 |
|---|---|---|
| committer | seth <[email protected]> | 2023-07-23 20:58:15 -0400 |
| commit | 787df3a240cf591cfe42b2db3036f903925d3d97 (patch) | |
| tree | f7466edf26e25111d7a7ff4869dbd76181054c13 /hosts | |
| parent | d7263b66eb7c8c3b34584608812cc42b07b11156 (diff) | |
hosts: init caroline
Diffstat (limited to 'hosts')
| -rw-r--r-- | hosts/caroline/default.nix | 26 | ||||
| -rw-r--r-- | hosts/default.nix | 71 | ||||
| -rw-r--r-- | hosts/profiles.nix | 74 |
3 files changed, 111 insertions, 60 deletions
diff --git a/hosts/caroline/default.nix b/hosts/caroline/default.nix new file mode 100644 index 0000000..343c1cb --- /dev/null +++ b/hosts/caroline/default.nix @@ -0,0 +1,26 @@ +{pkgs, ...}: { + imports = [ + ../../users/seth + ]; + + home-manager.users.seth = { + imports = [ + ../../users/seth/programs/firefox.nix + ]; + + home.packages = with pkgs; [ + discord-canary + iterm2 + spotify + ]; + }; + + networking = rec { + computerName = "caroline"; + hostName = computerName; + }; + + nix.settings.trusted-users = ["seth"]; + + services.tailscale.enable = true; +} diff --git a/hosts/default.nix b/hosts/default.nix index f3db7e6..a3340b5 100644 --- a/hosts/default.nix +++ b/hosts/default.nix @@ -5,41 +5,48 @@ withSystem, ... }: { - flake = { - nixosConfigurations = let - inherit (myLib.configs inputs) mkSystems; - - profiles = import ./profiles.nix {inherit self inputs;}; - in - mkSystems { - glados = { - modules = with inputs; [ - nixos-hardware.nixosModules.common-cpu-amd-pstate - nixos-hardware.nixosModules.common-gpu-nvidia-nonprime - nixos-hardware.nixosModules.common-pc-ssd - lanzaboote.nixosModules.lanzaboote - ]; - profile = profiles.personal; - }; - - glados-wsl = { - modules = [inputs.nixos-wsl.nixosModules.wsl]; - profile = profiles.personal; - }; - - atlas = { - system = "aarch64-linux"; - profile = profiles.server; - }; - - p-body = { - modules = [inputs.guzzle_api.nixosModules.guzzle_api]; - system = "x86_64-linux"; - profile = profiles.server; - }; + flake = let + inherit (myLib.configs inputs) mkSystems; + + profiles = import ./profiles.nix {inherit self inputs;}; + in { + darwinConfigurations = mkSystems { + caroline = { + system = "x86_64-darwin"; + profile = profiles.personal-darwin; + }; + }; + + nixosConfigurations = mkSystems { + glados = { + modules = with inputs; [ + nixos-hardware.nixosModules.common-cpu-amd-pstate + nixos-hardware.nixosModules.common-gpu-nvidia-nonprime + nixos-hardware.nixosModules.common-pc-ssd + lanzaboote.nixosModules.lanzaboote + ]; + profile = profiles.personal; + }; + + glados-wsl = { + modules = [inputs.nixos-wsl.nixosModules.wsl]; + profile = profiles.personal; + }; + + atlas = { + system = "aarch64-linux"; + profile = profiles.server; + }; + + p-body = { + modules = [inputs.guzzle_api.nixosModules.guzzle_api]; + system = "x86_64-linux"; + profile = profiles.server; }; + }; nixosModules.getchoo = import ../modules/nixos; + darwinModules.getchoo = import ../modules/darwin; packages.x86_64-linux.turret = withSystem "x86_64-linux" ({pkgs, ...}: pkgs.callPackage ./turret { diff --git a/hosts/profiles.nix b/hosts/profiles.nix index 4e6d019..83f2a6c 100644 --- a/hosts/profiles.nix +++ b/hosts/profiles.nix @@ -1,12 +1,43 @@ { inputs, self, -}: { +}: let + common = { + nixpkgs = { + overlays = with inputs; [nur.overlay getchoo.overlays.default self.overlays.default]; + config.allowUnfree = true; + }; + + nix = { + registry = with inputs; { + getchoo.flake = getchoo; + nixpkgs.flake = nixpkgs; + }; + + settings = { + trusted-substituters = [ + "https://getchoo.cachix.org" + "https://cache.garnix.io" + "https://nix-community.cachix.org" + "https://wurzelpfropf.cachix.org" + ]; + + trusted-public-keys = [ + "getchoo.cachix.org-1:ftdbAUJVNaFonM0obRGgR5+nUmdLMM+AOvDOSx0z5tE=" + "cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g=" + "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" + "wurzelpfropf.cachix.org-1:ilZwK5a6wJqVr7Fyrzp4blIEkGK+LJT0QrpWr1qBNq0=" + ]; + }; + }; + }; +in { personal = { system = "x86_64-linux"; builder = inputs.nixpkgs.lib.nixosSystem; modules = with inputs; [ + common ragenix.nixosModules.default home-manager.nixosModules.home-manager nur.nixosModules.nur @@ -25,36 +56,23 @@ }; }; - nixpkgs = { - overlays = with inputs; [nur.overlay getchoo.overlays.default self.overlays.default]; - config.allowUnfree = true; - }; - - nix = { - registry = { - getchoo.flake = getchoo; - nixpkgs.flake = nixpkgs; - }; + getchoo.base.enable = true; + system.stateVersion = "23.11"; + } + ]; - settings = { - trusted-substituters = [ - "https://getchoo.cachix.org" - "https://cache.garnix.io" - "https://nix-community.cachix.org" - "https://wurzelpfropf.cachix.org" - ]; - - trusted-public-keys = [ - "getchoo.cachix.org-1:ftdbAUJVNaFonM0obRGgR5+nUmdLMM+AOvDOSx0z5tE=" - "cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g=" - "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" - "wurzelpfropf.cachix.org-1:ilZwK5a6wJqVr7Fyrzp4blIEkGK+LJT0QrpWr1qBNq0=" - ]; - }; - }; + specialArgs = inputs; + }; + personal-darwin = { + builder = inputs.darwin.lib.darwinSystem; + modules = with inputs; [ + common + home-manager.darwinModules.home-manager + self.darwinModules.getchoo + { getchoo.base.enable = true; - system.stateVersion = "23.11"; + system.stateVersion = 4; } ]; |
