Moved hosts configurations to instances
This commit is contained in:
parent
4d706138d6
commit
cbe62f3201
24 changed files with 344 additions and 344 deletions
97
instances/freya/configuration.nix
Normal file
97
instances/freya/configuration.nix
Normal file
|
|
@ -0,0 +1,97 @@
|
|||
{ pkgs, ... }: {
|
||||
|
||||
console = { font = "Lat2-Terminus16"; keyMap = "it"; };
|
||||
|
||||
environment = {
|
||||
pathsToLink = [ "/share/zsh" ];
|
||||
systemPackages = builtins.attrValues { inherit (pkgs) helix tmux vim; };
|
||||
};
|
||||
|
||||
hardware = {
|
||||
bluetooth = { enable = true; package = pkgs.bluezFull; };
|
||||
opengl = { enable = true; driSupport = true; };
|
||||
raspberry-pi."4" = {
|
||||
# audio.enable = true; # AUDIO
|
||||
# fkms-3d.enable = true; # GPU
|
||||
};
|
||||
};
|
||||
|
||||
i18n.defaultLocale = "it_IT.UTF-8";
|
||||
|
||||
networking.hostName = "freya";
|
||||
networking.firewall = {
|
||||
enable = true;
|
||||
allowPing = true;
|
||||
allowedTCPPorts = [
|
||||
# 445 # SAMBA
|
||||
# 139 # SAMBA
|
||||
# 5357 # SAMBA-WSDD
|
||||
# 8123 # HOME ASSISTANT
|
||||
8384 # SYNCTHING
|
||||
# 8385 # SYNCTHING
|
||||
];
|
||||
allowedUDPPorts = [
|
||||
137 # SYNCTHING
|
||||
138 # SYNCTHING
|
||||
# 3702 # SAMBA-WSDD
|
||||
];
|
||||
# extraCommands =
|
||||
# "iptables -t raw -A OUTPUT -p udp -m udp --dport 137 -j CT --helper netbios-ns";
|
||||
};
|
||||
|
||||
programs = {
|
||||
dconf.enable = true;
|
||||
gnupg.agent = { enable = true; enableSSHSupport = true; };
|
||||
zsh.enable = true;
|
||||
};
|
||||
|
||||
security.sudo.extraConfig = ''
|
||||
Defaults pwfeedback
|
||||
'';
|
||||
|
||||
services = {
|
||||
avahi = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
nssmdns = true;
|
||||
publish = {
|
||||
enable = true;
|
||||
addresses = true;
|
||||
domain = true;
|
||||
userServices = true;
|
||||
workstation = true;
|
||||
};
|
||||
extraServiceFiles.ssh = "${pkgs.avahi}/etc/avahi/services/ssh.service";
|
||||
};
|
||||
blueman.enable = true;
|
||||
dbus.packages = [ pkgs.dconf ];
|
||||
gnome.gnome-keyring.enable = true;
|
||||
openssh = { enable = true; openFirewall = true; };
|
||||
# xserver = {
|
||||
# enable = true;
|
||||
# desktopManager.retroarch = { enable = true; package = pkgs.retroarchFull; };
|
||||
# };
|
||||
};
|
||||
|
||||
time.timeZone = "Europe/Rome";
|
||||
|
||||
users.users = {
|
||||
bertof = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [
|
||||
"audio"
|
||||
"input"
|
||||
"docker"
|
||||
"libvirtd"
|
||||
"network"
|
||||
"networkmanager"
|
||||
"usb"
|
||||
"video"
|
||||
"wheel"
|
||||
];
|
||||
shell = pkgs.zsh;
|
||||
};
|
||||
};
|
||||
|
||||
system.stateVersion = "22.11";
|
||||
}
|
||||
31
instances/freya/hardware-configuration.nix
Normal file
31
instances/freya/hardware-configuration.nix
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
{ lib, modulesPath, ... }:
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "uas" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/44444444-4444-4444-8888-888888888888";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.networkmanager.enable = lib.mkDefault true;
|
||||
# networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.eth0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlan0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.ztmjfdwjkp.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux";
|
||||
powerManagement.cpuFreqGovernor = lib.mkDefault "ondemand";
|
||||
}
|
||||
27
instances/freya/hm.nix
Normal file
27
instances/freya/hm.nix
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
{ pkgs, ... }: {
|
||||
home = {
|
||||
language.base = "it_IT.UTF-8";
|
||||
keyboard = {
|
||||
layout = "it";
|
||||
options = [ "terminate:ctrl_alt_bksp" "compose:rctrl" ];
|
||||
};
|
||||
packages = builtins.attrValues {
|
||||
inherit (pkgs)
|
||||
cava gallery-dl procps wireguard-tools httpie;
|
||||
};
|
||||
};
|
||||
imports = [
|
||||
../../modules/hm/__basic.nix
|
||||
|
||||
../../modules/hm/cava.nix
|
||||
../../modules/hm/dunst.nix
|
||||
../../modules/hm/helix.nix
|
||||
../../modules/hm/kitty.nix
|
||||
../../modules/hm/lf.nix
|
||||
../../modules/hm/spotifyd.nix
|
||||
../../modules/hm/syncthing.nix
|
||||
# ../../modules/hm/xidlehook.nix
|
||||
];
|
||||
|
||||
home.stateVersion = "22.11";
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue