diff options
Diffstat (limited to 'hosts/pendrive')
| -rw-r--r-- | hosts/pendrive/configuration.nix | 49 | ||||
| -rw-r--r-- | hosts/pendrive/disko.nix | 84 | ||||
| -rw-r--r-- | hosts/pendrive/home.nix | 48 |
3 files changed, 181 insertions, 0 deletions
diff --git a/hosts/pendrive/configuration.nix b/hosts/pendrive/configuration.nix new file mode 100644 index 0000000..56a2aad --- /dev/null +++ b/hosts/pendrive/configuration.nix @@ -0,0 +1,49 @@ +{ inputs, username, ... }: +{ + system.stateVersion = "25.05"; + + imports = [ + inputs.disko.nixosModules.disko + ./disko.nix + + ./hardware-configuration.nix + ../../os/default.nix + ]; + + os = { + core = { + allowUnfree.enable = true; + + audio.enable = true; + bootloader = "systemd-boot"; + drivers.enable = true; + fonts.enable = true; + greet.enable = true; + home-manager = { + enable = true; + users.${username}.path = ./home.nix; + }; + locale.enable = true; + memory.zram = { + enable = true; + percent = 25; + }; + network.enable = true; + security.enable = true; + ssh.enable = true; + storage.enable = true; + users.enable = true; + }; + srv = { + files = { + thunar.enable = true; + utils.enable = true; + }; + nix-helper.enable = true; + }; + wm = { + enable = true; + niri.enable = true; + }; + }; +} diff --git a/hosts/pendrive/disko.nix b/hosts/pendrive/disko.nix new file mode 100644 index 0000000..24674b7 --- /dev/null +++ b/hosts/pendrive/disko.nix @@ -0,0 +1,84 @@ +{ + disko.devices = { + disk = { + main = { + type = "disk"; + device = "/dev/sda"; + content = { + type = "gpt"; + partitions = { + ESP = { + size = "1G"; + type = "EF00"; + content = { + type = "filesystem"; + format = "vfat"; + mountpoint = "/boot"; + mountOptions = [ "umask=0077" ]; + }; + }; + luks = { + size = "75%"; + content = { + type = "luks"; + name = "crypted"; + settings = { + allowDiscards = true; + }; + content = { + type = "btrfs"; + extraArgs = [ "-f" ]; + subvolumes = { + "@" = { + mountpoint = "/"; + mountOptions = [ + "compress=zstd:1" + "noatime" + ]; + }; + "@home" = { + mountpoint = "/home"; + mountOptions = [ + "compress=zstd:1" + "noatime" + ]; + }; + "@nix" = { + mountpoint = "/nix"; + mountOptions = [ + "compress=zstd:1" + "noatime" + ]; + }; + "@log" = { + mountpoint = "/var/log"; + mountOptions = [ + "compress=zstd:1" + "noatime" + ]; + }; + "@swap" = { + mountpoint = "/.swapvol"; + mountOptions = [ + "nodatacow" + "noatime" + ]; + }; + }; + }; + }; + }; + shared = { + size = "100%"; + content = { + type = "filesystem"; + format = "exfat"; + mountpoint = "/shared"; + }; + }; + }; + }; + }; + }; + }; +} diff --git a/hosts/pendrive/home.nix b/hosts/pendrive/home.nix new file mode 100644 index 0000000..9ae18ad --- /dev/null +++ b/hosts/pendrive/home.nix @@ -0,0 +1,48 @@ +{ username, ... }: +{ + imports = [ ../../hm/default.nix ]; + + home = { + username = "${username}"; + homeDirectory = "/home/${username}"; + stateVersion = "25.05"; + }; + + hm = { + conf = { + clip = { + enable = true; + backend = "wayland"; + }; + git.enable = true; + xdg-dirs.enable = true; + }; + editors.nixvim.enable = true; + env = { + niri.enable = true; + cursor.enableMiyabi = true; + + waybar.enable = true; + themes = { + enable = true; + gtk.enable = true; + qt.enable = true; + }; + }; + shell = { + cli.enable = true; + fish.enable = true; + foot.enable = true; + starship.enable = true; + }; + soft = { + browser.librewolf.enable = true; + mpv.enable = true; + nixcord.enable = true; + obsidian.enable = true; + spicetify.enable = true; + torrent.enable = true; + yt-dlp.enable = true; + }; + }; +} |
