feat(hosts): add cmdframe

initial cmdframe configuration
This commit is contained in:
Felix Schröter 2025-06-04 18:03:55 +02:00
parent 67f8fa2cb5
commit 43c35fb2a8
Signed by: felschr
GPG key ID: 671E39E6744C807D
6 changed files with 173 additions and 0 deletions

View file

@ -0,0 +1,42 @@
{ config, ... }:
{
imports = [
./disk-config.nix
../../hardware/base.nix
../../hardware/bluetooth.nix
../../system/desktop.nix
../../system/printing/home.nix
../../desktop
../../desktop/cosmic.nix
../../virtualisation/containers.nix
../../virtualisation/podman.nix
../../virtualisation/libvirt.nix
../../modules/systemdNotify.nix
];
services.fprintd.enable = true;
programs.zsh.enable = true;
services.openssh = {
enable = true;
settings = {
KbdInteractiveAuthentication = false;
PasswordAuthentication = false;
PermitRootLogin = "no";
};
};
services.tailscale.extraUpFlags = [
"--accept-routes"
"--operator=felschr"
];
systemd.notify.enable = true;
systemd.notify.method = "libnotify";
systemd.notify.libnotify.user = "felschr";
# only change this when specified in release notes
system.stateVersion = "25.05";
}

View file

@ -0,0 +1,69 @@
{
disko.devices = {
disk = {
main = {
type = "disk";
device = "/dev/nvme0n1";
content = {
type = "gpt";
partitions = {
ESP = {
size = "2G";
type = "EF00";
content = {
type = "filesystem";
format = "vfat";
mountpoint = "/boot";
mountOptions = [ "umask=0077" ];
};
};
luks = {
size = "100%";
content = {
type = "luks";
name = "enc";
settings = {
allowDiscards = true;
};
content = {
type = "btrfs";
extraArgs = [ "-f" ];
subvolumes = {
"@" = {
mountpoint = "/";
mountOptions = [
"compress-force=zstd:1"
"noatime"
];
};
"@/nix" = {
mountpoint = "/nix";
mountOptions = [
"compress-force=zstd:1"
"noatime"
];
};
"@home" = {
mountpoint = "/home";
mountOptions = [
"compress-force=zstd:1"
"noatime"
];
};
"@snapshots" = {
mountpoint = "/.snapshots";
mountOptions = [
"compress-force=zstd:1"
"noatime"
];
};
};
};
};
};
};
};
};
};
};
}

View file

@ -0,0 +1,5 @@
_:
# TODO
{
}

View file

@ -1,6 +1,9 @@
{ self, inputs, ... }:
{
flake = {
diskoConfigurations = {
cmdframe = import ./cmdframe/disk-config.nix;
};
nixosConfigurations = {
home-pc = inputs.nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
@ -73,6 +76,33 @@
inherit inputs;
};
};
cmdframe = inputs.nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
inputs.disko.nixosModules.disko
inputs.nixpkgs.nixosModules.notDetected
inputs.nixos-hardware.nixosModules.framework-amd-ai-300-series
(self.lib.createSystemModule "cmdframe" {
hardwareConfig = ../hosts/cmdframe/hardware.nix;
config = ../hosts/cmdframe/default.nix;
})
(self.lib.createUserModule "felschr" {
homeModule = self.homeModules.felschr-work;
user.extraGroups = [
"wheel"
"networkmanager"
"audio"
"disk"
"libvirtd"
"qemu-libvirtd"
];
usesContainers = true;
})
];
specialArgs = {
inherit inputs;
};
};
};
deploy.nodes.home-server = {