Files
Olympus/system-config/configuration/pi4/default.nix
2025-08-23 11:07:59 -05:00

151 lines
3.8 KiB
Nix

{ config, lib, pkgs, inputs, ... }: {
imports = [
./hardware-configuration.nix
inputs.disko.nixosModules.default
(import ./disko.nix { device1 = "/dev/mmcblk0"; })
inputs.home-manager.nixosModules.default
inputs.sops-nix.nixosModules.sops
];
config = {
sysconfig = {
remoteBuildClient = true;
openssh.enable = true;
#pipewire.enable = true;
git.enable = true;
nh.enable = true;
netbird.enable = true;
};
home-manager = {
backupFileExtension = "backup";
extraSpecialArgs = { inherit inputs; };
sharedModules = [ inputs.sops-nix.homeManagerModules.sops ];
users = {
"nathan" = lib.mkMerge [
{
config.homeconfig = {
homeScripts.enable = false;
minimal = true;
mpd.enable = true;
};
}
inputs.nathan-home-manager
];
};
};
boot = {
loader = {
grub.enable = false;
generic-extlinux-compatible.enable = true;
};
};
networking = {
hostName = "pi4";
nameservers = [ "1.1.1.1" "1.0.0.1" ];
networkmanager.enable = true;
};
time.timeZone = "America/Chicago";
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
hardware = {
bluetooth.enable = true;
};
programs.zsh.enable = true;
environment.shells = with pkgs; [ zsh ];
users = {
defaultUserShell = pkgs.zsh;
groups.gpio = {};
users = {
nathan = {
isNormalUser = true;
description = "Nathan";
initialPassword = "7567";
extraGroups = [
"wheel"
"networkmanager"
"gpio"
"spi"
"audio"
"pulse"
"pulse-access"
];
};
};
};
services = {
udev.extraRules = ''
'';
pulseaudio = {
enable = true;
extraConfig = ''
'';
};
services.avahi = {
enable = true;
ipv4 = true;
ipv6 = true;
openFirewall = true;
nssmdns4 = true;
wideArea = true;
};
};
nix = {
nixPath = [ "nixpkgs=${inputs.nixpkgs}" ];
settings = {
experimental-features = [ "nix-command" "flakes" ];
};
};
sops = {
age.keyFile = "/home/nathan/.config/sops/age/keys.txt";
defaultSopsFile = ./secrets.yaml;
defaultSopsFormat = "yaml";
};
fonts.packages = with pkgs; [ nerd-fonts.fira-code ];
sound.enable = true;
security.rtkit.enable = true;
system.stateVersion = "25.05";
};
}