diff --git a/flake.nix b/flake.nix index 0be5e8d..0f06d06 100644 --- a/flake.nix +++ b/flake.nix @@ -17,7 +17,6 @@ devshell.url = "github:numtide/devshell"; nixos-hardware = { url = "github:NixOS/nixos-hardware/master"; - inputs.nixpkgs.follows = "nixpkgs"; }; }; @@ -27,6 +26,7 @@ imports = [ inputs.devshell.flakeModule ./nixos/machines/wsl/configuration.nix + ./nixos/machines/installer/configuration.nix ./home-manager/machines/wsl/home.nix ./devshells/rust.nix ./devshells/idris2.nix diff --git a/nixos/machines/installer/configuration.nix b/nixos/machines/installer/configuration.nix new file mode 100644 index 0000000..216e31d --- /dev/null +++ b/nixos/machines/installer/configuration.nix @@ -0,0 +1,60 @@ +{ withSystem, inputs, ... }: +{ + # perSystem = { ... }: { config.packages.hello = ...; }; + + flake.nixosConfigurations.inst = withSystem "x86_64-linux" ( + ctx@{ config, inputs', ... }: + inputs.nixpkgs.lib.nixosSystem { + # Expose `packages`, `inputs` and `inputs'` as module arguments. + # Use specialArgs permits use in `imports`. + # Note: if you publish modules for reuse, do not rely on specialArgs, but + # on the flake scope instead. See also https://flake.parts/define-module-in-separate-file.html + specialArgs = { + packages = config.packages; + inherit inputs inputs'; + }; + modules = [ + "${inputs.nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-graphical-calamares-plasma5.nix" + "${inputs.nixpkgs}/nixos/modules/installer/cd-dvd/channel.nix" + inputs.nixos-hardware.nixosModules.microsoft-surface-common + ( + # NixOS-WSL specific options are documented on the NixOS-WSL repository: + # https://github.com/nix-community/NixOS-WSL + + { + config, + lib, + pkgs, + ... + }: + + { + imports = [ + ]; + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + + nix.settings.experimental-features = [ + "nix-command" + "flakes" + ]; + + networking.hostId = "9affdaa4"; + + environment.systemPackages = with pkgs; [ + ]; + + time.timeZone = "America/Kentucky/Louisville"; + + # This value determines the NixOS release from which the default + # settings for stateful data, like file locations and database versions + # on your system were taken. It's perfectly fine and recommended to leave + # this value at the release version of the first install of this system. + # Before changing this value read the documentation for this option + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). + system.stateVersion = "24.11"; # Did you read the comment? + } + ) + ]; + } + ); +}