diff --git a/flake.lock b/flake.lock index 3296c43..d1f0084 100644 --- a/flake.lock +++ b/flake.lock @@ -25,6 +25,22 @@ "type": "github" } }, + "aghpb": { + "flake": false, + "locked": { + "lastModified": 1773167124, + "narHash": "sha256-ELnpKMODHKZcsXZ9/6XyTo17u3j2bUs9nplyULz6uFI=", + "owner": "cat-milk", + "repo": "Anime-Girls-Holding-Programming-Books", + "rev": "c04a6e18f474965b731b65e539ad69a94123c444", + "type": "github" + }, + "original": { + "owner": "cat-milk", + "repo": "Anime-Girls-Holding-Programming-Books", + "type": "github" + } + }, "assets": { "flake": false, "locked": { @@ -313,6 +329,7 @@ "root": { "inputs": { "agenix": "agenix", + "aghpb": "aghpb", "assets": "assets", "catppuccin": "catppuccin", "flake-file": "flake-file", diff --git a/flake.nix b/flake.nix index 546ea72..3f049a5 100644 --- a/flake.nix +++ b/flake.nix @@ -11,6 +11,10 @@ nixpkgs.follows = "nixpkgs"; }; }; + aghpb = { + url = "github:cat-milk/Anime-Girls-Holding-Programming-Books"; + flake = false; + }; assets = { url = "path:./assets"; flake = false; diff --git a/modules/hosts/tux/filesystems.nix b/modules/hosts/tux/filesystems.nix new file mode 100644 index 0000000..b7195db --- /dev/null +++ b/modules/hosts/tux/filesystems.nix @@ -0,0 +1,20 @@ +{ + flake.modules.nixos.tux = { + fileSystems."/" = + { device = "/dev/disk/by-uuid/39bb2139-7d71-4f3d-9c11-2cf3fe26ad7d"; + fsType = "ext4"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/6514-61C0"; + fsType = "vfat"; + options = [ "fmask=0077" "dmask=0077" ]; + }; + + swapDevices = + [ { device = "/dev/disk/by-uuid/ac1606de-34d3-4036-baf6-2ed17e54bfc3"; } + ]; + + + }; +} diff --git a/modules/hosts/tux/flake-parts.nix b/modules/hosts/tux/flake-parts.nix new file mode 100644 index 0000000..a19b4ef --- /dev/null +++ b/modules/hosts/tux/flake-parts.nix @@ -0,0 +1,3 @@ +{ inputs, ...}: { + flake.nixosConfigurations = inputs.self.lib.mkNixos "x86_64-linux" "tux"; +} diff --git a/modules/hosts/tux/hardware.nix b/modules/hosts/tux/hardware.nix new file mode 100644 index 0000000..c038fc1 --- /dev/null +++ b/modules/hosts/tux/hardware.nix @@ -0,0 +1,15 @@ +{inputs, ...}: { + flake.modules.nixos.tux = { + imports = with inputs.self.modules.nixos; [ + intel-gpu + ]; + + boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "sd_mod" "sdhci_pci" ]; + + nixpkgs.hostPlatform = "x86_64-linux"; + + hardware.enableRedistributableFirmware = true; + hardware.cpu.intel.updateMicrocode = true; + + }; +} diff --git a/modules/hosts/tux/networking.nix b/modules/hosts/tux/networking.nix new file mode 100644 index 0000000..45db07e --- /dev/null +++ b/modules/hosts/tux/networking.nix @@ -0,0 +1,8 @@ +{inputs, ...}: { + flake.modules.nixos.tux = { + imports = with inputs.self.modules.nixos; [ + networkmanager + ]; + networking.hostName = "tux"; + }; +} diff --git a/modules/hosts/tux/tux.nix b/modules/hosts/tux/tux.nix new file mode 100644 index 0000000..5bddb82 --- /dev/null +++ b/modules/hosts/tux/tux.nix @@ -0,0 +1,17 @@ +{ inputs, ... }: { + flake.modules.nixos.tux = { + imports = with inputs.self.modules.nixos; + with inputs.self.factory; [ + system-desktop + systemd-boot + + (autologin "weckyy702") + + development-tools + i18n-de + tailscale + + #TODO: laptop specific aspects like powertop + ]; + }; +} diff --git a/modules/hosts/tux/users/weckyy702/backlight.nix b/modules/hosts/tux/users/weckyy702/backlight.nix new file mode 100644 index 0000000..7c4390c --- /dev/null +++ b/modules/hosts/tux/users/weckyy702/backlight.nix @@ -0,0 +1,8 @@ +{ inputs, ... }: { + flake.modules.nixos.tux = { + imports = with inputs.self.modules.nixos; [ + backlight + ]; + users.users.weckyy702.extraGroups = [ "video" ]; + }; +} diff --git a/modules/hosts/tux/users/weckyy702/hyprland.nix b/modules/hosts/tux/users/weckyy702/hyprland.nix new file mode 100644 index 0000000..2481dbd --- /dev/null +++ b/modules/hosts/tux/users/weckyy702/hyprland.nix @@ -0,0 +1,19 @@ +{ inputs, ... }: { + flake-file.inputs = { + aghpb = { + url = "github:cat-milk/Anime-Girls-Holding-Programming-Books"; + flake = false; + }; + }; + + flake.modules.homeManager.tux-hyprland = { + imports = with inputs.self.modules.homeManager; [ + ashell + ]; + wayland.windowManager.hyprland.settings = { + monitor = [ + "eDP-1,preferred,0x0,1.066666667" + ]; + }; + }; +} diff --git a/modules/hosts/tux/users/weckyy702/mount-nas.nix b/modules/hosts/tux/users/weckyy702/mount-nas.nix new file mode 100644 index 0000000..5dc7455 --- /dev/null +++ b/modules/hosts/tux/users/weckyy702/mount-nas.nix @@ -0,0 +1,16 @@ +{ inputs, ... }: { + flake.modules.nixos.tux = { config, ... }: { + age.secrets."nas-creds".file = "${inputs.secrets}/nas-creds.age"; + + imports = with inputs.self.factory; [ + (mount-cifs { + host = "duke.veltnet"; + resource = "smb-share"; + destination = "/home/weckyy702/duke"; + credentials_path = "${config.age.secrets.nas-creds.path}"; + UID = "weckyy702"; + GID = "users"; + }) + ]; + }; +} diff --git a/modules/hosts/tux/users/weckyy702/wallpaper.nix b/modules/hosts/tux/users/weckyy702/wallpaper.nix new file mode 100644 index 0000000..db56754 --- /dev/null +++ b/modules/hosts/tux/users/weckyy702/wallpaper.nix @@ -0,0 +1,14 @@ +{ inputs, ... }: { + flake.modules.homeManager.randomized-aghpb-wallpaper = { + imports = with inputs.self.factory; [ + (wpaperd { + default = { + path = inputs.aghpb; + recursive = true; + mode = "stretch"; + duration = "5m"; + }; + }) + ]; + }; +} diff --git a/modules/hosts/tux/users/weckyy702/weckyy702.nix b/modules/hosts/tux/users/weckyy702/weckyy702.nix new file mode 100644 index 0000000..6ee1614 --- /dev/null +++ b/modules/hosts/tux/users/weckyy702/weckyy702.nix @@ -0,0 +1,20 @@ +{ inputs, ... }: { + flake.modules.nixos.tux = { + imports = with inputs.self.modules.nixos; [ + weckyy702 + upower + ]; + + home-manager.users.weckyy702 = { + imports = with inputs.self.modules.homeManager; + with inputs.self.factory; [ + borgmatic + obsidian + vesktop + tux-hyprland + randomized-aghpb-wallpaper + nm-applet + ]; + }; + }; +}