Initial commit

This commit is contained in:
2025-11-28 01:41:57 +01:00
commit 0be86c7284
113 changed files with 8498 additions and 0 deletions

View File

@@ -0,0 +1,29 @@
{ modulesPath, config, ... }:
{
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
(modulesPath + "/profiles/qemu-guest.nix")
../../nixos/home-manager.nix
../../nixos/nix.nix
../../nixos/users.nix
../../nixos/utils.nix
../../server-modules/ssh.nix
../../server-modules/caddy.nix
../../server-modules/bitwarden.nix
../../server-modules/firewall.nix
../../server-modules/copyparty.nix
../../server-modules/home-assistant.nix
../../server-modules/glance.nix
./disk-config.nix
./hardware-configuration.nix
./variables.nix
];
home-manager.users."${config.var.username}" = import ./home.nix;
# Don't touch this
system.stateVersion = "24.05";
}

View File

@@ -0,0 +1,55 @@
{ lib, ... }:
{
disko.devices = {
disk.disk1 = {
device = lib.mkDefault "/dev/sda";
type = "disk";
content = {
type = "gpt";
partitions = {
boot = {
name = "boot";
size = "1M";
type = "EF02";
};
esp = {
name = "ESP";
size = "500M";
type = "EF00";
content = {
type = "filesystem";
format = "vfat";
mountpoint = "/boot";
};
};
root = {
name = "root";
size = "100%";
content = {
type = "lvm_pv";
vg = "pool";
};
};
};
};
};
lvm_vg = {
pool = {
type = "lvm_vg";
lvs = {
root = {
size = "100%FREE";
content = {
type = "filesystem";
format = "ext4";
mountpoint = "/";
mountOptions = [
"defaults"
];
};
};
};
};
};
};
}

View File

@@ -0,0 +1,24 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/profiles/qemu-guest.nix")
];
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ ];
boot.extraModulePackages = [ ];
# 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.useDHCP = lib.mkDefault true;
# networking.interfaces.ens18.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
}

40
hosts/orion/home.nix Normal file
View File

@@ -0,0 +1,40 @@
{
pkgs,
config,
...
}:
{
imports = [
# Mostly user-specific configuration
./variables.nix
# Programs
#../../home/programs/nvf
../../home/programs/shell
#../../home/programs/fetch
../../home/programs/git
#../../home/programs/lazygit
# Scripts
#../../home/scripts # All scripts
];
home = {
inherit (config.var) username;
homeDirectory = "/home/" + config.var.username;
packages = with pkgs; [
# Utils
btop
# Provide relevant terminfo
kitty
ghostty
];
# Don't touch this
stateVersion = "24.05";
};
programs.home-manager.enable = true;
}

42
hosts/orion/variables.nix Normal file
View File

@@ -0,0 +1,42 @@
{
config,
lib,
...
}:
{
imports = [
# Choose your theme here:
../../themes/catppuccin.nix
];
config.var = {
hostname = "orion";
username = "kiri";
configDirectory = "/home/" + config.var.username + "/.config/nixos"; # The path of the nixos configuration directory
keyboardLayout = "us";
location = "Meterik";
timeZone = "Europe/Amsterdam";
defaultLocale = "en_US.UTF-8";
timeLocale = "en_DK.UTF-8";
numericLocale = "en_IE.UTF-8";
otherLocale = "nl_NL.UTF-8";
git = {
username = "kiri";
email = "mail@jelles.net";
};
autoUpgrade = false;
autoGarbageCollector = true;
};
# Let this here
options = {
var = lib.mkOption {
type = lib.types.attrs;
default = { };
};
};
}