mirror of
https://github.com/Gerg-L/nixos.git
synced 2025-12-10 00:43:56 -05:00
systems -> hosts
moved functions to /lib inputs over imports turned each module file into a nixosModule moved registry and $NIX_PATH pinning to /modules/pinning.nix
This commit is contained in:
parent
ee2beea680
commit
f43d0b741c
42 changed files with 224 additions and 240 deletions
84
hosts/moms-laptop/default.nix
Normal file
84
hosts/moms-laptop/default.nix
Normal file
|
|
@ -0,0 +1,84 @@
|
|||
_: {
|
||||
pkgs,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
localModules = {
|
||||
remoteBuild.enable = true;
|
||||
DM = {
|
||||
lightdm.enable = true;
|
||||
autoLogin = true;
|
||||
loginUser = "jo";
|
||||
};
|
||||
DE.xfce.enable = true;
|
||||
theming = {
|
||||
enable = true;
|
||||
kmscon.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
environment.systemPackages = builtins.attrValues {
|
||||
inherit
|
||||
(pkgs)
|
||||
neovim
|
||||
vlc
|
||||
nomacs
|
||||
rsync
|
||||
pavucontrol #gui volume control
|
||||
librewolf #best browser
|
||||
;
|
||||
};
|
||||
services.xserver.videoDrivers = ["intel"];
|
||||
networking = {
|
||||
hostName = "moms-laptop";
|
||||
networkmanager.enable = true;
|
||||
};
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
sops.secrets.root.neededForUsers = true;
|
||||
users = {
|
||||
mutableUsers = false;
|
||||
users = {
|
||||
jo = {
|
||||
useDefaultShell = true;
|
||||
uid = 1000;
|
||||
isNormalUser = true;
|
||||
extraGroups = ["networkmanager" "audio"];
|
||||
initialHashedPassword = "";
|
||||
};
|
||||
"root" = {
|
||||
uid = 0;
|
||||
home = "/root";
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAuO/3IF+AjH8QjW4DAUV7mjlp2Mryd+1UnpAUofS2yA gerg@gerg-phone"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILpYY2uw0OH1Re+3BkYFlxn0O/D8ryqByJB/ljefooNc gerg@gerg-windows"
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJWbwkFJmRBgyWyWU+w3ksZ+KuFw9uXJN3PwqqE7Z/i8 gerg@gerg-desktop"
|
||||
];
|
||||
passwordFile = config.sops.secrets.root.path;
|
||||
};
|
||||
};
|
||||
};
|
||||
boot = {
|
||||
initrd.availableKernelModules = ["xhci-pci" "ehci-pci" "ahci" "usbhid" "sd_mod" "sr_mod" "rtsx_usb_sdmmc"];
|
||||
kernelModules = ["kvm-intel"];
|
||||
};
|
||||
systemd.tmpfiles.rules = [
|
||||
"L+ /home/jo/Desktop/gimp.desktop - - - - ${pkgs.gimp}/share/applications/gimp.desktop"
|
||||
"L+ /home/jo/Desktop/org.gnome.Calculator.desktop - - - - ${pkgs.gnome.gnome-calculator}/share/applications/org.gnome.Calculator.desktop"
|
||||
"L+ /home/jo/Desktop/org.nomacs.ImageLounge.desktop - - - - ${pkgs.nomacs}/share/applications/org.nomacs.ImageLounge.desktop"
|
||||
"L+ /home/jo/Desktop/thunar.desktop - - - - ${pkgs.xfce.thunar}/share/applications/thunar.desktop"
|
||||
"L+ /home/jo/Desktop/librewolf.desktop - - - - ${pkgs.librewolf}/share/applications/librewolf.desktop"
|
||||
"L+ /home/jo/Desktop/vlc.desktop - - - - ${pkgs.vlc}/share/applications/vlc.desktop"
|
||||
"L /home/jo/Desktop/Downloads - - - - /home/jo/Downloads"
|
||||
"L /home/jo/Desktop/Documents - - - - /home/jo/Documents"
|
||||
"L /home/jo/Desktop/Pictures - - - - /home/jo/Pictures"
|
||||
];
|
||||
|
||||
system.stateVersion = "23.05";
|
||||
|
||||
swapDevices = [
|
||||
{
|
||||
device = "/swapfile";
|
||||
size = 8 * 1024;
|
||||
}
|
||||
];
|
||||
}
|
||||
39
hosts/moms-laptop/disko.nix
Normal file
39
hosts/moms-laptop/disko.nix
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
{disko, ...}: {disks ? [], ...}: {
|
||||
dummyvalue = {inherit disks;};
|
||||
imports = [disko.nixosModules.disko];
|
||||
disko.devices = {
|
||||
disk.sda = {
|
||||
device = "/dev/disk/by-id/ata-WDC_WDS240G2G0A-00JH30_180936803144";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "table";
|
||||
format = "gpt";
|
||||
partitions = [
|
||||
{
|
||||
name = "ESP";
|
||||
start = "1MiB";
|
||||
end = "1GiB";
|
||||
bootable = true;
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "root";
|
||||
start = "1GiB";
|
||||
end = "100%";
|
||||
part-type = "primary";
|
||||
bootable = true;
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "ext4";
|
||||
mountpoint = "/";
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
20
hosts/moms-laptop/printing.nix
Normal file
20
hosts/moms-laptop/printing.nix
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
_: {pkgs, ...}: {
|
||||
nixpkgs.allowedUnfree = ["hplip"];
|
||||
environment.systemPackages = [
|
||||
pkgs.gimp
|
||||
(pkgs.xsane.override {gimpSupport = true;})
|
||||
pkgs.libreoffice
|
||||
];
|
||||
users.users.jo.extraGroups = ["scanner" "lp" "cups"];
|
||||
hardware.sane = {
|
||||
enable = true;
|
||||
extraBackends = [pkgs.hplipWithPlugin];
|
||||
};
|
||||
systemd.tmpfiles.rules = ["L /home/jo/.config/GIMP/2.10/plug-ins/xsane - - - - /run/current-system/sw/bin/xsane"];
|
||||
services = {
|
||||
printing = {
|
||||
enable = true;
|
||||
drivers = [pkgs.hplipWithPlugin];
|
||||
};
|
||||
};
|
||||
}
|
||||
30
hosts/moms-laptop/secrets.yaml
Normal file
30
hosts/moms-laptop/secrets.yaml
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
root: ENC[AES256_GCM,data:tQMtWAjqHcuny+6R3M0BFyEaFiaAr0eU04xhLiMdZ9KuqeQoV2aasJ9I6yVWNeaNE/K2DEWEXIv3fhLVp11/CMBjd9Yi1An9Jg==,iv:cx1jHEioCRaL7u2zwp8NfDxnHr5zzWTOh8/gJgUKN+0=,tag:JVex88fYnSmfwhortUi0Xw==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1vxx3qdsucv2v2slag67c4f0kwd8jtta4tue6m8d9xfl4ryrqvyusxgwl68
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBwU3doYWlIdWEwTmVOUGRY
|
||||
aGJPMy9ac1RoUS9LdUcvbkxSU1N2MVpIeFRjCmV6QTlhMUhoVmdUOGdFdmVMNW5h
|
||||
cVI4YlBwaEZFbC8xZWYrMFZQOFVaQzgKLS0tIHMzN081UmowTXYzc1hhNk5FOWdu
|
||||
Vmh5WGFXT2M0dUttQjMxMXA5TUJFTkEKvI3cbR9A9vK6oiEc6Qaj9j84FxVekQvl
|
||||
ZfQhT6nLrh7IjR+uJ1ZqwJioSsGKLCDmBropjTWei469fJkma7p8BQ==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
- recipient: age180y8kdtdlqelayyz9mq2c7xv248rh4gdfr3amjzvdcjrz6wdaqmsj762pp
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBXZk1ScGpmT1Fjd1p3MFFw
|
||||
dE1mRjUyQkN4N05VMThUZnNHL2pQbjVQem5nCjVsejY0L0piTHMzOVo4d2xHL2Fq
|
||||
aVp0WXpMbUlEMGFoS080N1BITXhDa1EKLS0tIHRTSTAybUFUZFFNL1NOWHduWmE3
|
||||
SVJpZmRIcjJZWjNGZFllTGU4L0NLZG8K/J87ETorELtOxABopOvEcRPiY8qubzou
|
||||
Ogs1d+4CqPx/PC4tW06tkp8Fp8DWcr8/XxxsPJ9DBfVT7wCRb/RqCw==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2023-03-11T20:02:40Z"
|
||||
mac: ENC[AES256_GCM,data:XK10hpfe5zKQvP4Lf0lXTgmSULsqC446CYR7B57R6G99BJgpkdYOK9Zi1IHF3g1mwjplxY3LSi8mW+ETV7DgnhOhpTiGJQzFKmLVQCogImM63aWR6/SYRAoI3wvgb4TMv/cZvaqRHmU+HzjTN5ZCGWDfKyQvFVjOWps8FvK4kNM=,iv:cK5ARa1+Qtw/LHHNUZVFa1k79LuDIW40jhS9AyEBUCQ=,tag:b621ftO1UVE1/4G3KVsIOQ==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.7.3
|
||||
Loading…
Add table
Add a link
Reference in a new issue