nix-config/hosts/archlaptop-vm/default.nix

97 lines
2.9 KiB
Nix
Raw Normal View History

2024-04-05 01:44:59 +02:00
{
inputs,
outputs,
configLib,
2024-04-05 01:44:59 +02:00
...
}:
inputs.nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = {inherit inputs outputs configLib;};
2024-04-05 01:44:59 +02:00
# > Our main nixos configuration file <
modules = [
inputs.home-manager.nixosModules.home-manager
./hardware-configuration.nix
2024-05-10 00:47:54 +02:00
../../roles/nixos/graphical-vm.nix
../../configs/nixos/common.nix
../../configs/nixos/printing.nix
../../configs/nixos/sound.nix
2024-06-03 23:38:29 +02:00
../../configs/nixos/interactive-networking.nix
../../configs/nixos/i3
2024-06-04 00:36:45 +02:00
../../configs/nixos/sshd.nix
./secrets.nix
2024-04-05 01:44:59 +02:00
({
config,
pkgs,
configLib,
2024-04-05 01:44:59 +02:00
...
}: {
host = {
user = "gabe";
fullName = "Gabe Venberg";
2024-04-05 01:44:59 +02:00
gui.enable = true;
isVm = true;
2024-04-05 01:44:59 +02:00
};
networking.hostName = "archlaptop-vm"; # Define your hostname.
2024-06-04 18:00:43 +02:00
users.mutableUsers = false;
2024-04-05 01:44:59 +02:00
# Define a user account. Don't forget to set a password with passwd.
users.users.${config.host.user} = {
2024-06-04 18:00:43 +02:00
hashedPasswordFile = config.sops.secrets.gv-password.path;
packages = with pkgs; [firefox];
2024-04-05 01:44:59 +02:00
};
2024-06-04 18:00:43 +02:00
home-manager.sharedModules = [
inputs.sops-nix.homeManagerModules.sops
];
2024-04-27 05:29:37 +02:00
home-manager.users.${config.host.user} = {
inputs,
osConfig,
...
}: {
host = osConfig.host;
user = {
2024-04-05 01:44:59 +02:00
git = {
profile = {
name = config.host.fullName;
2024-04-05 01:44:59 +02:00
email = "gabevenberg@gmail.com";
};
workProfile.enable = false;
};
};
imports = [
2024-05-10 00:47:54 +02:00
../../roles/home-manager/terminal.nix
../../configs/home-manager/common.nix
../../configs/home-manager/email.nix
2024-04-05 01:44:59 +02:00
inputs.nixvim.homeManagerModules.nixvim
2024-06-04 18:00:43 +02:00
../../configs/home-manager/secrets.nix
2024-04-05 01:44:59 +02:00
];
2024-06-04 18:00:43 +02:00
sops = {
secrets = {
gmail-password.sopsFile = "${inputs.nix-secrets}/workstations.yaml";
irc-cert.sopsFile = "${inputs.nix-secrets}/workstations.yaml";
};
};
2024-04-05 01:44:59 +02:00
};
2024-05-15 20:22:50 +02:00
# Bootloader.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
2024-04-05 01:44:59 +02:00
# Open ports in the firewall.
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# 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 = "23.11"; # Did you read the comment?
})
];
}