System/machines/perception/configuration.nix

54 lines
1.2 KiB
Nix
Raw Normal View History

2023-04-08 23:20:43 -04:00
{ config, lib, pkgs, inputs, ... }:
{
# Sops setup for this machine
sops.secrets = {
"borg-ssh-key" = {
sopsFile = ../../secrets/perception/borg.yaml;
format = "yaml";
};
"borg-password" = {
sopsFile = ../../secrets/perception/borg.yaml;
format = "yaml";
};
};
# Setup system configuration
nathan = {
services = {
borg = {
enable = true;
extraExcludes = [ "/var/log" ];
passwordFile = config.sops.secrets."borg-password".path;
sshKey = config.sops.secrets."borg-ssh-key".path;
};
};
config = {
2023-04-08 23:36:46 -04:00
setupGrub = false;
2023-04-08 23:20:43 -04:00
nix = {
autoUpdate = true;
autoGC = true;
};
harden = false;
};
};
2023-04-08 23:36:46 -04:00
# Configure bootloader
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
boot.loader.efi.efiSysMountPoint = "/boot/efi";
boot.kernelParams = [ "net.ifnames=0" ];
2023-04-08 23:20:43 -04:00
# Configure networking
networking = {
domain = "mccarty.io";
useDHCP = true;
# Open ports in firewall
firewall = {
allowedTCPPorts = [ ];
allowedUDPPorts = [ ];
};
};
# Setup home manager
home-manager.users.nathan = import ./home.nix;
}