This adds some code to flake.nix to read the directory of hosts/ and find all hosts based on their host.nix file, and set the hostname based on the directory. I don't know enough about hostnames to know what are valid characters, but in the future this could allow a hostname such as "servers/madoka" which may be an issue. For now the structure is simple enough of "hosts/name" resulting in hostname "name" Another commit is planned which will do the same thing for users
33 lines
643 B
Nix
33 lines
643 B
Nix
{ ... }:
|
|
|
|
{
|
|
imports = [
|
|
./hardware.nix
|
|
];
|
|
networking.hostName = "onizuka";
|
|
nixpkgs.config.allowUnfree = true;
|
|
system.stateVersion = "23.05";
|
|
|
|
nvidia.enable = true;
|
|
pipewire.enable = true;
|
|
polkit.enable = true;
|
|
tablet.enable = true;
|
|
|
|
user.name = "pan";
|
|
user.timezone = "America/Los_Angeles";
|
|
system.doAutoUpgrade = true;
|
|
|
|
tuigreet.enable = true;
|
|
hyprland.enable = true;
|
|
|
|
librewolf.enable = true;
|
|
fish.enable = true;
|
|
fish.setDefault = true;
|
|
syncthing.enable = true;
|
|
|
|
steam.enable = true;
|
|
steam.gamemode.enable = true;
|
|
aagl.enable = true;
|
|
aagl.honkai-rail = true;
|
|
input-remapper.enable = true;
|
|
}
|