Compare commits
No commits in common. "6434b248053180b2913725879ca9becd53f3ebd7" and "2144d9ef61a51af58dc9a980c54722227345e980" have entirely different histories.
6434b24805
...
2144d9ef61
120 changed files with 215 additions and 186 deletions
2
.gitattributes
vendored
2
.gitattributes
vendored
|
@ -1 +1 @@
|
||||||
system/secrets/** filter=git-crypt diff=git-crypt
|
modules/system/secrets/** filter=git-crypt diff=git-crypt
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
}@inputs:
|
}@inputs:
|
||||||
{
|
{
|
||||||
nixosConfigurations.rubble = nixpkgs.lib.nixosSystem {
|
nixosConfigurations.rubble = nixpkgs.lib.nixosSystem {
|
||||||
modules = [ ./system ];
|
modules = [ ./host ];
|
||||||
specialArgs = inputs;
|
specialArgs = inputs;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
19
host/default.nix
Normal file
19
host/default.nix
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
./disko
|
||||||
|
./hardware
|
||||||
|
../modules/system
|
||||||
|
];
|
||||||
|
|
||||||
|
networking = {
|
||||||
|
hostName = "rubble";
|
||||||
|
hostId = "e0b1fcef";
|
||||||
|
};
|
||||||
|
|
||||||
|
system = {
|
||||||
|
extlinux.enable = true;
|
||||||
|
wireless.enable = true;
|
||||||
|
stateVersion = "24.11";
|
||||||
|
};
|
||||||
|
}
|
|
@ -68,12 +68,8 @@
|
||||||
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
|
mountOptions = [ "compress=zstd" "noatime" "ssd" ];
|
||||||
};
|
};
|
||||||
"/persist/.snapshots" = { };
|
"/persist/.snapshots" = { };
|
||||||
|
"/persist/home/${config.sysusers.main}" = { };
|
||||||
"/persist/home/jules" = { };
|
"/persist/home/${config.sysusers.main}/.snapshots" = { };
|
||||||
"/persist/home/jules/.snapshots" = { };
|
|
||||||
|
|
||||||
"/persist/home/jimbo" = { };
|
|
||||||
"/persist/home/jimbo/.snapshots" = { };
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
|
@ -1,9 +1,7 @@
|
||||||
{ home-manager, ... }:
|
{ home-manager, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./jules
|
./main
|
||||||
./jimbo
|
|
||||||
|
|
||||||
home-manager.nixosModules.home-manager
|
home-manager.nixosModules.home-manager
|
||||||
];
|
];
|
||||||
}
|
}
|
48
modules/system/accounts/users/custom/jules/default.nix
Normal file
48
modules/system/accounts/users/custom/jules/default.nix
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
{
|
||||||
|
options.sysusers = lib.mkOption {
|
||||||
|
type = lib.types.attrs;
|
||||||
|
};
|
||||||
|
|
||||||
|
config = {
|
||||||
|
sysusers.main = "jimbo";
|
||||||
|
|
||||||
|
users.users."${config.sysusers.main}" = {
|
||||||
|
hashedPassword = config.secrets.mainAccPass;
|
||||||
|
isNormalUser = true;
|
||||||
|
openssh.authorizedKeys.keyFiles = [
|
||||||
|
../../../../../../hosts/tower/id_ed25519.pub
|
||||||
|
|
||||||
|
../../../../../../hosts/envy/id_ed25519.pub
|
||||||
|
../../../../../../hosts/redmond/id_ed25519.pub
|
||||||
|
|
||||||
|
../../../../../../hosts/kitty/id_ed25519.pub
|
||||||
|
../../../../../../hosts/midas/id_ed25519.pub
|
||||||
|
../../../../../../hosts/prophet/id_ed25519.pub
|
||||||
|
../../../../../../hosts/rubble/id_ed25519.pub
|
||||||
|
];
|
||||||
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJahAoF74BY6GCTsFkt1ADKaraFgJJozW1Y1aBTLK0j9 Pixel9"
|
||||||
|
];
|
||||||
|
extraGroups = [
|
||||||
|
"wheel"
|
||||||
|
"audio"
|
||||||
|
"video"
|
||||||
|
"input"
|
||||||
|
"disk"
|
||||||
|
"dialout"
|
||||||
|
"rtkit"
|
||||||
|
"kvm"
|
||||||
|
"libvirtd"
|
||||||
|
"qemu-libvirtd"
|
||||||
|
"nginx"
|
||||||
|
"minecraft"
|
||||||
|
"nfsShare"
|
||||||
|
];
|
||||||
|
uid = 1000;
|
||||||
|
shell = pkgs.zsh;
|
||||||
|
};
|
||||||
|
|
||||||
|
home-manager.users."${config.sysusers.main}" = import ../../../../../home;
|
||||||
|
};
|
||||||
|
}
|
38
modules/system/accounts/users/custom/main/default.nix
Normal file
38
modules/system/accounts/users/custom/main/default.nix
Normal file
|
@ -0,0 +1,38 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
{
|
||||||
|
options.sysusers = lib.mkOption {
|
||||||
|
type = lib.types.attrs;
|
||||||
|
};
|
||||||
|
|
||||||
|
config = {
|
||||||
|
sysusers.main = "jimbo";
|
||||||
|
|
||||||
|
users.users."${config.sysusers.main}" = {
|
||||||
|
hashedPassword = config.secrets.mainAccPass;
|
||||||
|
isNormalUser = true;
|
||||||
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIC2lMkUd+BbXITE5LTg94hEzmA6UKsIIbaf5YOjGoLzl"
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIFGHaxdTeC1xnTx2BY5LLR5LxhdSkmYoWuOeEuRIz0k"
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJahAoF74BY6GCTsFkt1ADKaraFgJJozW1Y1aBTLK0j9 Pixel9"
|
||||||
|
];
|
||||||
|
extraGroups = [
|
||||||
|
"wheel"
|
||||||
|
"audio"
|
||||||
|
"video"
|
||||||
|
"input"
|
||||||
|
"disk"
|
||||||
|
"dialout"
|
||||||
|
"rtkit"
|
||||||
|
"kvm"
|
||||||
|
"libvirtd"
|
||||||
|
"qemu-libvirtd"
|
||||||
|
"nginx"
|
||||||
|
"nfsShare"
|
||||||
|
];
|
||||||
|
uid = 1000;
|
||||||
|
shell = pkgs.zsh;
|
||||||
|
};
|
||||||
|
|
||||||
|
home-manager.users."${config.sysusers.main}" = import ../../../../../home;
|
||||||
|
};
|
||||||
|
}
|
16
modules/system/default.nix
Normal file
16
modules/system/default.nix
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{ lib, ... }:
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
./accounts
|
||||||
|
./devices
|
||||||
|
./programs
|
||||||
|
./secrets
|
||||||
|
./services
|
||||||
|
./settings
|
||||||
|
];
|
||||||
|
|
||||||
|
options.system = with lib; {
|
||||||
|
desktop.enable = lib.mkEnableOption "Enable desktop apps and services";
|
||||||
|
server.enable = lib.mkEnableOption "Enable server apps and services";
|
||||||
|
};
|
||||||
|
}
|
10
modules/system/devices/boot/extlinux/default.nix
Normal file
10
modules/system/devices/boot/extlinux/default.nix
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
{ config, lib, ... }:
|
||||||
|
{
|
||||||
|
options.system.extlinux.enable = lib.mkEnableOption "Enable extlinux";
|
||||||
|
|
||||||
|
config.boot.loader = lib.mkIf config.system.extlinux.enable {
|
||||||
|
grub.enable = false;
|
||||||
|
systemd-boot.enable = lib.mkForce false;
|
||||||
|
generic-extlinux-compatible.enable = true;
|
||||||
|
};
|
||||||
|
}
|
|
@ -3,7 +3,6 @@
|
||||||
imports = [
|
imports = [
|
||||||
./boot
|
./boot
|
||||||
./disks
|
./disks
|
||||||
./hardware
|
|
||||||
./networking
|
./networking
|
||||||
];
|
];
|
||||||
}
|
}
|
|
@ -1,7 +1,6 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./disko
|
|
||||||
./filesystems
|
./filesystems
|
||||||
./immutable
|
./immutable
|
||||||
./impermanence
|
./impermanence
|
|
@ -1,10 +1,8 @@
|
||||||
{ impermanence, ... }:
|
{ impermanence, ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./jules
|
./main
|
||||||
./jimbo
|
|
||||||
./root
|
./root
|
||||||
|
|
||||||
impermanence.nixosModules.impermanence
|
impermanence.nixosModules.impermanence
|
||||||
];
|
];
|
||||||
}
|
}
|
46
modules/system/devices/disks/impermanence/main/default.nix
Normal file
46
modules/system/devices/disks/impermanence/main/default.nix
Normal file
|
@ -0,0 +1,46 @@
|
||||||
|
{ config, ... }:
|
||||||
|
{
|
||||||
|
environment.persistence."/persist" = {
|
||||||
|
hideMounts = true;
|
||||||
|
users.${config.sysusers.main} = {
|
||||||
|
directories = [
|
||||||
|
"Keepers"
|
||||||
|
"Documents"
|
||||||
|
"Pictures"
|
||||||
|
"Videos"
|
||||||
|
"Games"
|
||||||
|
"VMs"
|
||||||
|
|
||||||
|
".snapshots"
|
||||||
|
".mozilla"
|
||||||
|
".thunderbird"
|
||||||
|
|
||||||
|
".config/blender"
|
||||||
|
".config/dconf"
|
||||||
|
".config/vesktop"
|
||||||
|
".config/sunshine"
|
||||||
|
".config/heroic"
|
||||||
|
".config/obs-studio"
|
||||||
|
|
||||||
|
".local/share/mpd"
|
||||||
|
".local/share/nvim/undo"
|
||||||
|
".local/share/PrismLauncher"
|
||||||
|
".local/share/Steam"
|
||||||
|
".local/share/TelegramDesktop"
|
||||||
|
|
||||||
|
".local/state/wireplumber"
|
||||||
|
|
||||||
|
".cache/nix-index"
|
||||||
|
|
||||||
|
{ directory = ".ssh"; mode = "0700"; }
|
||||||
|
{ directory = ".gnupg"; mode = "0700"; }
|
||||||
|
{ directory = ".local/share/keyrings"; mode = "0700"; }
|
||||||
|
];
|
||||||
|
files = [
|
||||||
|
".zsh_history"
|
||||||
|
".local/state/lazygit/state.yml"
|
||||||
|
".local/share/applications" # Create directory so nothing generates inside of it
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,8 +1,7 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./jules
|
./main
|
||||||
./jimbo
|
|
||||||
./root
|
./root
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
{
|
{
|
||||||
services.snapper.configs.jules = lib.mkIf config.environment.persistence."/persist".enable {
|
services.snapper.configs.${config.sysusers.main} = lib.mkIf config.environment.persistence."/persist".enable {
|
||||||
SUBVOLUME = "/persist/home/jules";
|
SUBVOLUME = "/persist/home/${config.sysusers.main}";
|
||||||
TIMELINE_CREATE = true;
|
TIMELINE_CREATE = true;
|
||||||
TIMELINE_CLEANUP = true;
|
TIMELINE_CLEANUP = true;
|
||||||
TIMELINE_LIMIT_DAILY = 1;
|
TIMELINE_LIMIT_DAILY = 1;
|
|
@ -1,10 +1,9 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
|
imports = [ ./wireless ];
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
wireless = {
|
wireless.enable = false;
|
||||||
enable = false;
|
|
||||||
iwd.enable = true;
|
|
||||||
};
|
|
||||||
dhcpcd.enable = true;
|
dhcpcd.enable = true;
|
||||||
nftables.enable = true;
|
nftables.enable = true;
|
||||||
firewall.allowPing = false;
|
firewall.allowPing = false;
|
||||||
|
@ -22,9 +21,4 @@
|
||||||
fallbackDns = config.networking.nameservers;
|
fallbackDns = config.networking.nameservers;
|
||||||
dnsovertls = "true";
|
dnsovertls = "true";
|
||||||
};
|
};
|
||||||
|
|
||||||
environment = {
|
|
||||||
systemPackages = with pkgs; [ impala ];
|
|
||||||
persistence."/persist".directories = [ "/var/lib/iwd/" ];
|
|
||||||
};
|
|
||||||
}
|
}
|
13
modules/system/devices/networking/wireless/default.nix
Normal file
13
modules/system/devices/networking/wireless/default.nix
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
{
|
||||||
|
options.system.wireless.enable = lib.mkEnableOption "Enable wireless stack";
|
||||||
|
|
||||||
|
config = lib.mkIf config.system.wireless.enable {
|
||||||
|
networking.wireless.iwd.enable = true;
|
||||||
|
|
||||||
|
environment = {
|
||||||
|
systemPackages = with pkgs; [ impala ];
|
||||||
|
persistence."/persist".directories = [ "/var/lib/iwd/" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
BIN
modules/system/secrets/default.nix
Normal file
BIN
modules/system/secrets/default.nix
Normal file
Binary file not shown.
|
@ -33,5 +33,7 @@
|
||||||
"virbr0"
|
"virbr0"
|
||||||
"virbr1"
|
"virbr1"
|
||||||
];
|
];
|
||||||
|
|
||||||
|
systemd.tmpfiles.rules = [ "f /dev/shm/looking-glass 0660 - libvirtd -" ];
|
||||||
};
|
};
|
||||||
}
|
}
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue