Add multi-host configuration

based loosely on https://github.com/tom-on-the-internet/system-configuration
This commit is contained in:
Elnu 2022-10-09 19:09:47 -07:00
parent f554a9038b
commit 8f0f5b9bbf
13 changed files with 254 additions and 240 deletions

39
hosts/configuration.nix Normal file
View file

@ -0,0 +1,39 @@
{ config, pkgs, user, inputs, ... }:
{
# Automatically delete generations older than a week
nix.gc = {
automatic = true;
options = "--delete-generations 8d";
};
networking.networkmanager.enable = true;
time.timeZone = "America/Los_Angeles";
users.users.${user} = {
isNormalUser = true;
extraGroups = [ "wheel" "audio" "video" "optical" "storage" ];
initialPassword = "password";
};
nixpkgs.config.allowUnfree = true;
nix = {
package = pkgs.nixVersions.stable; # flakes
extraOptions = "experimental-features = nix-command flakes";
};
environment.systemPackages = with pkgs; [
rustc
cargo
];
# 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. Its 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 = "22.05"; # Did you read the comment?
}