mirror of
https://github.com/tuxdotrs/nix-config.git
synced 2026-09-19 16:49:04 +05:30
style: format code
This commit is contained in:
@@ -1,138 +1,138 @@
|
||||
{ inputs, config, ... }:
|
||||
{
|
||||
flake.modules.nixos.alpha =
|
||||
{
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
}@innerArgs:
|
||||
{
|
||||
imports =
|
||||
with config.flake.modules.nixos;
|
||||
[
|
||||
boot
|
||||
networking
|
||||
virtualisation
|
||||
services
|
||||
]
|
||||
++ [
|
||||
inputs.trok.nixosModules.default
|
||||
inputs.tfolio.nixosModules.default
|
||||
];
|
||||
inputs,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
flake.modules.nixos.alpha = {
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
} @ innerArgs: {
|
||||
imports = with config.flake.modules.nixos;
|
||||
[
|
||||
boot
|
||||
networking
|
||||
virtualisation
|
||||
services
|
||||
]
|
||||
++ [
|
||||
inputs.trok.nixosModules.default
|
||||
inputs.tfolio.nixosModules.default
|
||||
];
|
||||
|
||||
tnix = {
|
||||
boot = {
|
||||
legacy.enable = true;
|
||||
tnix = {
|
||||
boot = {
|
||||
legacy.enable = true;
|
||||
|
||||
impermanence = {
|
||||
enable = true;
|
||||
impermanence = {
|
||||
enable = true;
|
||||
|
||||
home = {
|
||||
directories = [
|
||||
".local/share/nvim"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/state/lazygit"
|
||||
".local/share/opencode"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
networking = {
|
||||
openssh = {
|
||||
enable = true;
|
||||
ports = [
|
||||
23
|
||||
home = {
|
||||
directories = [
|
||||
".local/share/nvim"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/state/lazygit"
|
||||
".local/share/opencode"
|
||||
];
|
||||
};
|
||||
netbird-client.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
pangolin = {
|
||||
enable = true;
|
||||
domain = "pangolin.lab.tux.rs";
|
||||
baseDomain = "lab.tux.rs";
|
||||
environmentFile = innerArgs.config.sops.secrets."pangolin".path;
|
||||
};
|
||||
|
||||
uptime-kuma = {
|
||||
enable = true;
|
||||
domain = "status.lab.tux.rs";
|
||||
};
|
||||
|
||||
mediaflow-proxy = {
|
||||
enable = true;
|
||||
environmentFile = innerArgs.config.sops.secrets."mediaflow-proxy".path;
|
||||
};
|
||||
|
||||
trok = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
networking = {
|
||||
openssh = {
|
||||
enable = true;
|
||||
ports = [
|
||||
23
|
||||
];
|
||||
};
|
||||
netbird-client.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
pangolin = {
|
||||
enable = true;
|
||||
domain = "pangolin.lab.tux.rs";
|
||||
baseDomain = "lab.tux.rs";
|
||||
environmentFile = innerArgs.config.sops.secrets."pangolin".path;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
"cloudflare-credentials/email" = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
"cloudflare-credentials/dns-api-token" = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
aiostreams = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
uptime-kuma = {
|
||||
enable = true;
|
||||
domain = "status.lab.tux.rs";
|
||||
};
|
||||
|
||||
mediaflow-proxy = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
enable = true;
|
||||
environmentFile = innerArgs.config.sops.secrets."mediaflow-proxy".path;
|
||||
};
|
||||
|
||||
pangolin = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
trok = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager.enable = true;
|
||||
firewall.enable = false;
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
};
|
||||
|
||||
services.tfolio.enable = true;
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
"cloudflare-credentials/email" = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
"cloudflare-credentials/dns-api-token" = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
aiostreams = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
mediaflow-proxy = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
pangolin = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager.enable = true;
|
||||
firewall.enable = false;
|
||||
};
|
||||
|
||||
services.tfolio.enable = true;
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,22 +1,23 @@
|
||||
{ inputs, ... }:
|
||||
{
|
||||
flake.modules.nixos.alpha =
|
||||
{ config, lib, ... }:
|
||||
let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
isLegacy = config.tnix.boot.legacy.enable;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
{inputs, ...}: {
|
||||
flake.modules.nixos.alpha = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
isLegacy = config.tnix.boot.legacy.enable;
|
||||
in {
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/sda";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/sda";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions =
|
||||
{
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
@@ -36,36 +37,37 @@
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes = {
|
||||
"/root" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/";
|
||||
subvolumes =
|
||||
{
|
||||
"/root" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/";
|
||||
};
|
||||
"/nix" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"noacl"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/nix";
|
||||
};
|
||||
}
|
||||
# Conditionally merge /persist only when impermanence is enabled
|
||||
// lib.optionalAttrs hasOptinPersistence {
|
||||
"/persist" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/persist";
|
||||
};
|
||||
};
|
||||
"/nix" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"noacl"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/nix";
|
||||
};
|
||||
}
|
||||
# Conditionally merge /persist only when impermanence is enabled
|
||||
// lib.optionalAttrs hasOptinPersistence {
|
||||
"/persist" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/persist";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -76,7 +78,7 @@
|
||||
type = "EF02";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,17 +1,15 @@
|
||||
{
|
||||
flake.modules.nixos.alpha =
|
||||
{
|
||||
lib,
|
||||
modulesPath,
|
||||
system,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/profiles/qemu-guest.nix")
|
||||
];
|
||||
flake.modules.nixos.alpha = {
|
||||
lib,
|
||||
modulesPath,
|
||||
system,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/profiles/qemu-guest.nix")
|
||||
];
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
};
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,165 +1,163 @@
|
||||
{ config, ... }: {
|
||||
flake.modules.nixos.arcturus =
|
||||
{
|
||||
pkgs,
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
}@innerArgs:
|
||||
{
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
virtualisation
|
||||
services
|
||||
];
|
||||
{config, ...}: {
|
||||
flake.modules.nixos.arcturus = {
|
||||
pkgs,
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
} @ innerArgs: {
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
virtualisation
|
||||
services
|
||||
];
|
||||
|
||||
tnix = {
|
||||
boot = {
|
||||
secure-boot.enable = true;
|
||||
tnix = {
|
||||
boot = {
|
||||
secure-boot.enable = true;
|
||||
|
||||
impermanence = {
|
||||
enable = true;
|
||||
impermanence = {
|
||||
enable = true;
|
||||
|
||||
home = {
|
||||
directories = [
|
||||
"Distrobox"
|
||||
".bun"
|
||||
".rustup"
|
||||
".config/sops"
|
||||
".local/share/nvim"
|
||||
".local/share/opencode"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/state/lazygit"
|
||||
];
|
||||
home = {
|
||||
directories = [
|
||||
"Distrobox"
|
||||
".bun"
|
||||
".rustup"
|
||||
".config/sops"
|
||||
".local/share/nvim"
|
||||
".local/share/opencode"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/state/lazygit"
|
||||
];
|
||||
|
||||
files = [
|
||||
".wakatime.cfg"
|
||||
];
|
||||
};
|
||||
files = [
|
||||
".wakatime.cfg"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
networking = {
|
||||
openssh.enable = true;
|
||||
netbird-client.enable = true;
|
||||
newt = {
|
||||
enable = true;
|
||||
environmentFile = innerArgs.config.sops.secrets.newt.path;
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
hermes-agent = {
|
||||
enable = true;
|
||||
environmentFiles = [ innerArgs.config.sops.secrets.hermes.path ];
|
||||
};
|
||||
|
||||
cyber-tux = {
|
||||
enable = true;
|
||||
environmentFile = innerArgs.config.sops.secrets.discord-token.path;
|
||||
};
|
||||
|
||||
vaultwarden = {
|
||||
enable = true;
|
||||
domain = "bw.lab.tux.rs";
|
||||
configurePangolin = true;
|
||||
};
|
||||
|
||||
copyparty = {
|
||||
enable = true;
|
||||
domain = "files.lab.tux.rs";
|
||||
accounts.${userName}.passwordFile = innerArgs.config.sops.secrets.copyparty.path;
|
||||
volumes = {
|
||||
"/" = {
|
||||
path = "/var/lib/copyparty/data";
|
||||
access = {
|
||||
r = "*";
|
||||
rwmdgGha = [ userName ];
|
||||
};
|
||||
};
|
||||
};
|
||||
configurePangolin = true;
|
||||
};
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
distrobox.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
|
||||
discord-token = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
networking = {
|
||||
openssh.enable = true;
|
||||
netbird-client.enable = true;
|
||||
newt = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
enable = true;
|
||||
environmentFile = innerArgs.config.sops.secrets.newt.path;
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
hermes-agent = {
|
||||
enable = true;
|
||||
environmentFiles = [innerArgs.config.sops.secrets.hermes.path];
|
||||
};
|
||||
|
||||
cyber-tux = {
|
||||
enable = true;
|
||||
environmentFile = innerArgs.config.sops.secrets.discord-token.path;
|
||||
};
|
||||
|
||||
vaultwarden = {
|
||||
enable = true;
|
||||
domain = "bw.lab.tux.rs";
|
||||
configurePangolin = true;
|
||||
};
|
||||
|
||||
copyparty = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = innerArgs.config.services.copyparty.user;
|
||||
};
|
||||
|
||||
hermes = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
wireless.iwd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
Network = {
|
||||
EnableIPv6 = true;
|
||||
};
|
||||
Settings = {
|
||||
AutoConnect = true;
|
||||
domain = "files.lab.tux.rs";
|
||||
accounts.${userName}.passwordFile = innerArgs.config.sops.secrets.copyparty.path;
|
||||
volumes = {
|
||||
"/" = {
|
||||
path = "/var/lib/copyparty/data";
|
||||
access = {
|
||||
r = "*";
|
||||
rwmdgGha = [userName];
|
||||
};
|
||||
};
|
||||
};
|
||||
configurePangolin = true;
|
||||
};
|
||||
firewall.enable = false;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
impala
|
||||
];
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
distrobox.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
|
||||
discord-token = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
newt = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
copyparty = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = innerArgs.config.services.copyparty.user;
|
||||
};
|
||||
|
||||
hermes = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
wireless.iwd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
Network = {
|
||||
EnableIPv6 = true;
|
||||
};
|
||||
Settings = {
|
||||
AutoConnect = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
firewall.enable = false;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
impala
|
||||
];
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,41 +1,42 @@
|
||||
{ inputs, ... }:
|
||||
{
|
||||
flake.modules.nixos.arcturus =
|
||||
{ config, lib, ... }:
|
||||
let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
{inputs, ...}: {
|
||||
flake.modules.nixos.arcturus = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
in {
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/nvme0n1";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [
|
||||
"defaults"
|
||||
"umask=0077"
|
||||
];
|
||||
};
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/nvme0n1";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [
|
||||
"defaults"
|
||||
"umask=0077"
|
||||
];
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
type = "8300";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes = {
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
type = "8300";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes =
|
||||
{
|
||||
"/root" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
@@ -65,10 +66,10 @@
|
||||
mountpoint = "/persist";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,36 +1,33 @@
|
||||
{ config, ... }:
|
||||
{
|
||||
flake.modules.nixos.arcturus =
|
||||
{
|
||||
lib,
|
||||
pkgs,
|
||||
system,
|
||||
...
|
||||
}@innerArgs:
|
||||
{
|
||||
imports = with config.flake.modules.nixos; [
|
||||
hardware
|
||||
];
|
||||
{config, ...}: {
|
||||
flake.modules.nixos.arcturus = {
|
||||
lib,
|
||||
pkgs,
|
||||
system,
|
||||
...
|
||||
} @ innerArgs: {
|
||||
imports = with config.flake.modules.nixos; [
|
||||
hardware
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault innerArgs.config.hardware.enableRedistributableFirmware;
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault innerArgs.config.hardware.enableRedistributableFirmware;
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvtopPackages.amd
|
||||
];
|
||||
};
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvtopPackages.amd
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,141 +1,139 @@
|
||||
{ config, ... }: {
|
||||
flake.modules.nixos.canopus =
|
||||
{
|
||||
pkgs,
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
desktop
|
||||
gaming
|
||||
virtualisation
|
||||
];
|
||||
{config, ...}: {
|
||||
flake.modules.nixos.canopus = {
|
||||
pkgs,
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
}: {
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
desktop
|
||||
gaming
|
||||
virtualisation
|
||||
];
|
||||
|
||||
tnix = {
|
||||
boot = {
|
||||
secure-boot.enable = true;
|
||||
tnix = {
|
||||
boot = {
|
||||
secure-boot.enable = true;
|
||||
|
||||
impermanence = {
|
||||
enable = true;
|
||||
impermanence = {
|
||||
enable = true;
|
||||
|
||||
home = {
|
||||
directories = [
|
||||
"Distrobox"
|
||||
".steam"
|
||||
".bun"
|
||||
".rustup"
|
||||
".cache/awww"
|
||||
".config/BraveSoftware"
|
||||
".config/zed"
|
||||
".config/Vencord"
|
||||
".config/vesktop"
|
||||
".config/sops"
|
||||
".config/obs-studio"
|
||||
".config/easyeffects"
|
||||
".config/DankMaterialShell"
|
||||
".local/share/Steam"
|
||||
".local/share/lutris"
|
||||
".local/share/net.lutris.Lutris"
|
||||
".local/share/nvim"
|
||||
".local/share/opencode"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/share/voxtype"
|
||||
".local/state/lazygit"
|
||||
".local/share/vicinae"
|
||||
".local/share/TelegramDesktop"
|
||||
".local/share/GalaxyBudsClient"
|
||||
".local/state/serpantinum"
|
||||
".local/share/zed"
|
||||
];
|
||||
home = {
|
||||
directories = [
|
||||
"Distrobox"
|
||||
".steam"
|
||||
".bun"
|
||||
".rustup"
|
||||
".cache/awww"
|
||||
".config/BraveSoftware"
|
||||
".config/zed"
|
||||
".config/Vencord"
|
||||
".config/vesktop"
|
||||
".config/sops"
|
||||
".config/obs-studio"
|
||||
".config/easyeffects"
|
||||
".config/DankMaterialShell"
|
||||
".local/share/Steam"
|
||||
".local/share/lutris"
|
||||
".local/share/net.lutris.Lutris"
|
||||
".local/share/nvim"
|
||||
".local/share/opencode"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/share/voxtype"
|
||||
".local/state/lazygit"
|
||||
".local/share/vicinae"
|
||||
".local/share/TelegramDesktop"
|
||||
".local/share/GalaxyBudsClient"
|
||||
".local/state/serpantinum"
|
||||
".local/share/zed"
|
||||
];
|
||||
|
||||
files = [
|
||||
".wakatime.cfg"
|
||||
];
|
||||
};
|
||||
files = [
|
||||
".wakatime.cfg"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
networking = {
|
||||
openssh.enable = true;
|
||||
netbird-client.enable = true;
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
docker.nvidia.enable = false;
|
||||
qemu.enable = true;
|
||||
waydroid.enable = true;
|
||||
distrobox.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
vicinae-json = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
wireless.iwd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
Network = {
|
||||
EnableIPv6 = true;
|
||||
};
|
||||
Settings = {
|
||||
AutoConnect = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
firewall.enable = false;
|
||||
openssh.enable = true;
|
||||
netbird-client.enable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
davinci-resolve
|
||||
telegram-desktop
|
||||
galaxy-buds-client
|
||||
impala
|
||||
];
|
||||
|
||||
# !!! DO NOT CHANGE THIS !!!
|
||||
# This should match the version used at initial install.
|
||||
system.stateVersion = "26.05";
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
docker.nvidia.enable = false;
|
||||
qemu.enable = true;
|
||||
waydroid.enable = true;
|
||||
distrobox.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
vicinae-json = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
wireless.iwd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
Network = {
|
||||
EnableIPv6 = true;
|
||||
};
|
||||
Settings = {
|
||||
AutoConnect = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
firewall.enable = false;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
davinci-resolve
|
||||
telegram-desktop
|
||||
galaxy-buds-client
|
||||
impala
|
||||
];
|
||||
|
||||
# !!! DO NOT CHANGE THIS !!!
|
||||
# This should match the version used at initial install.
|
||||
system.stateVersion = "26.05";
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,49 +1,50 @@
|
||||
{ inputs, ... }:
|
||||
{
|
||||
flake.modules.nixos.canopus =
|
||||
{ config, lib, ... }:
|
||||
let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
{inputs, ...}: {
|
||||
flake.modules.nixos.canopus = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
in {
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/nvme0n1";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [
|
||||
"defaults"
|
||||
"umask=0077"
|
||||
];
|
||||
};
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/nvme0n1";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [
|
||||
"defaults"
|
||||
"umask=0077"
|
||||
];
|
||||
};
|
||||
swap = {
|
||||
size = "32G";
|
||||
content = {
|
||||
type = "swap";
|
||||
discardPolicy = "both";
|
||||
resumeDevice = true;
|
||||
};
|
||||
};
|
||||
swap = {
|
||||
size = "32G";
|
||||
content = {
|
||||
type = "swap";
|
||||
discardPolicy = "both";
|
||||
resumeDevice = true;
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
type = "8300";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes = {
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
type = "8300";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes =
|
||||
{
|
||||
"/root" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
@@ -73,10 +74,10 @@
|
||||
mountpoint = "/persist";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,150 +1,150 @@
|
||||
{ inputs, config, ... }:
|
||||
{
|
||||
flake.modules.nixos.canopus =
|
||||
{
|
||||
lib,
|
||||
pkgs,
|
||||
system,
|
||||
...
|
||||
}@innerArgs:
|
||||
{
|
||||
imports =
|
||||
with config.flake.modules.nixos;
|
||||
[
|
||||
hardware
|
||||
]
|
||||
++ [
|
||||
inputs.nixos-hardware.nixosModules.asus-zephyrus-ga503
|
||||
inputs.cardwire.nixosModules.default
|
||||
];
|
||||
|
||||
boot.kernelParams = [ "nvidia-drm.modeset=1" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
inputs,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
flake.modules.nixos.canopus = {
|
||||
lib,
|
||||
pkgs,
|
||||
system,
|
||||
...
|
||||
} @ innerArgs: {
|
||||
imports = with config.flake.modules.nixos;
|
||||
[
|
||||
hardware
|
||||
]
|
||||
++ [
|
||||
inputs.nixos-hardware.nixosModules.asus-zephyrus-ga503
|
||||
inputs.cardwire.nixosModules.default
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
hardware = {
|
||||
nvidia = {
|
||||
modesetting.enable = true;
|
||||
open = false;
|
||||
nvidiaSettings = true;
|
||||
};
|
||||
boot.kernelParams = ["nvidia-drm.modeset=1"];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
cpu.amd.updateMicrocode = lib.mkDefault innerArgs.config.hardware.enableRedistributableFirmware;
|
||||
hardware = {
|
||||
nvidia = {
|
||||
modesetting.enable = true;
|
||||
open = false;
|
||||
nvidiaSettings = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
xserver.videoDrivers = [ "nvidia" ];
|
||||
power-profiles-daemon.enable = true;
|
||||
upower.enable = true;
|
||||
|
||||
cardwire = {
|
||||
enable = true;
|
||||
settings = {
|
||||
auto_apply_gpu_state = true;
|
||||
experimental_nvidia_block = true;
|
||||
battery_auto_switch = true;
|
||||
battery_auto_switch_mode = "hybrid";
|
||||
};
|
||||
};
|
||||
|
||||
asusd = {
|
||||
enable = true;
|
||||
asusdConfig.text = ''
|
||||
(
|
||||
charge_control_end_threshold: 80,
|
||||
disable_nvidia_powerd_on_battery: true,
|
||||
ac_command: "",
|
||||
bat_command: "",
|
||||
|
||||
platform_profile_linked_epp: true,
|
||||
platform_profile_on_battery: Quiet,
|
||||
platform_profile_on_ac: Performance,
|
||||
|
||||
change_platform_profile_on_battery: true,
|
||||
change_platform_profile_on_ac: true,
|
||||
|
||||
profile_quiet_epp: Power,
|
||||
profile_balanced_epp: BalancePower,
|
||||
profile_custom_epp: Performance,
|
||||
profile_performance_epp: Performance,
|
||||
|
||||
ac_profile_tunings: {},
|
||||
dc_profile_tunings: {},
|
||||
armoury_settings: {},
|
||||
)
|
||||
'';
|
||||
profileConfig.text = ''
|
||||
(
|
||||
active_profile: Quiet,
|
||||
)
|
||||
'';
|
||||
fanCurvesConfig.text = ''
|
||||
(
|
||||
profiles: (
|
||||
balanced: [
|
||||
(
|
||||
fan: CPU,
|
||||
pwm: (20, 40, 60, 85, 110, 140, 170, 200),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
(
|
||||
fan: GPU,
|
||||
pwm: (20, 40, 60, 85, 110, 140, 170, 200),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
],
|
||||
performance: [
|
||||
(
|
||||
fan: CPU,
|
||||
pwm: (35, 60, 90, 120, 150, 180, 220, 255),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
(
|
||||
fan: GPU,
|
||||
pwm: (35, 60, 90, 120, 150, 180, 220, 255),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
],
|
||||
quiet: [
|
||||
(
|
||||
fan: CPU,
|
||||
pwm: (0, 10, 20, 35, 55, 80, 110, 140),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
(
|
||||
fan: GPU,
|
||||
pwm: (0, 10, 20, 35, 55, 80, 110, 140),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
],
|
||||
custom: [],
|
||||
),
|
||||
)
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.config.cudaSupport = true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvtopPackages.full
|
||||
];
|
||||
cpu.amd.updateMicrocode = lib.mkDefault innerArgs.config.hardware.enableRedistributableFirmware;
|
||||
};
|
||||
|
||||
services = {
|
||||
xserver.videoDrivers = ["nvidia"];
|
||||
power-profiles-daemon.enable = true;
|
||||
upower.enable = true;
|
||||
|
||||
cardwire = {
|
||||
enable = true;
|
||||
settings = {
|
||||
auto_apply_gpu_state = true;
|
||||
experimental_nvidia_block = true;
|
||||
battery_auto_switch = true;
|
||||
battery_auto_switch_mode = "hybrid";
|
||||
};
|
||||
};
|
||||
|
||||
asusd = {
|
||||
enable = true;
|
||||
asusdConfig.text = ''
|
||||
(
|
||||
charge_control_end_threshold: 80,
|
||||
disable_nvidia_powerd_on_battery: true,
|
||||
ac_command: "",
|
||||
bat_command: "",
|
||||
|
||||
platform_profile_linked_epp: true,
|
||||
platform_profile_on_battery: Quiet,
|
||||
platform_profile_on_ac: Performance,
|
||||
|
||||
change_platform_profile_on_battery: true,
|
||||
change_platform_profile_on_ac: true,
|
||||
|
||||
profile_quiet_epp: Power,
|
||||
profile_balanced_epp: BalancePower,
|
||||
profile_custom_epp: Performance,
|
||||
profile_performance_epp: Performance,
|
||||
|
||||
ac_profile_tunings: {},
|
||||
dc_profile_tunings: {},
|
||||
armoury_settings: {},
|
||||
)
|
||||
'';
|
||||
profileConfig.text = ''
|
||||
(
|
||||
active_profile: Quiet,
|
||||
)
|
||||
'';
|
||||
fanCurvesConfig.text = ''
|
||||
(
|
||||
profiles: (
|
||||
balanced: [
|
||||
(
|
||||
fan: CPU,
|
||||
pwm: (20, 40, 60, 85, 110, 140, 170, 200),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
(
|
||||
fan: GPU,
|
||||
pwm: (20, 40, 60, 85, 110, 140, 170, 200),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
],
|
||||
performance: [
|
||||
(
|
||||
fan: CPU,
|
||||
pwm: (35, 60, 90, 120, 150, 180, 220, 255),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
(
|
||||
fan: GPU,
|
||||
pwm: (35, 60, 90, 120, 150, 180, 220, 255),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
],
|
||||
quiet: [
|
||||
(
|
||||
fan: CPU,
|
||||
pwm: (0, 10, 20, 35, 55, 80, 110, 140),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
(
|
||||
fan: GPU,
|
||||
pwm: (0, 10, 20, 35, 55, 80, 110, 140),
|
||||
temp: (45, 55, 62, 68, 74, 80, 86, 92),
|
||||
enabled: true,
|
||||
),
|
||||
],
|
||||
custom: [],
|
||||
),
|
||||
)
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.config.cudaSupport = true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvtopPackages.full
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
{ config, ... }:
|
||||
{
|
||||
flake.modules.homeManager.canopus = { pkgs, ... }: {
|
||||
{config, ...}: {
|
||||
flake.modules.homeManager.canopus = {pkgs, ...}: {
|
||||
imports = with config.flake.modules.homeManager; [
|
||||
desktop
|
||||
];
|
||||
@@ -27,8 +26,7 @@
|
||||
enable = true;
|
||||
settings = {
|
||||
authorized_fingerprints = {
|
||||
"f4:4b:17:61:f7:01:a4:a2:e1:c7:8c:1c:7a:f3:8b:87:14:3d:05:3d:a0:8b:cc:e7:88:d8:d8:d2:a4:c2:75:8b" =
|
||||
"sirius";
|
||||
"f4:4b:17:61:f7:01:a4:a2:e1:c7:8c:1c:7a:f3:8b:87:14:3d:05:3d:a0:8b:cc:e7:88:d8:d8:d2:a4:c2:75:8b" = "sirius";
|
||||
};
|
||||
};
|
||||
};
|
||||
@@ -42,7 +40,7 @@
|
||||
position = "0x0",
|
||||
scale = "1",
|
||||
disabled = false
|
||||
})' &&
|
||||
})' &&
|
||||
hyprctl eval 'hl.monitor({
|
||||
output = "HDMI-A-1",
|
||||
mode = "preferred",
|
||||
@@ -58,7 +56,7 @@
|
||||
position = "0x0",
|
||||
scale = "1",
|
||||
disabled = false
|
||||
})' &&
|
||||
})' &&
|
||||
hyprctl eval 'hl.monitor({
|
||||
output = "HDMI-A-1",
|
||||
mode = "preferred",
|
||||
@@ -71,7 +69,7 @@
|
||||
hyprctl eval 'hl.monitor({
|
||||
output = "eDP-1",
|
||||
disabled = true
|
||||
})' &&
|
||||
})' &&
|
||||
hyprctl eval 'hl.monitor({
|
||||
output = "HDMI-A-1",
|
||||
mode = "preferred",
|
||||
|
||||
@@ -1,140 +1,138 @@
|
||||
{ config, ... }: {
|
||||
flake.modules.nixos.sirius =
|
||||
{
|
||||
pkgs,
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
desktop
|
||||
gaming
|
||||
virtualisation
|
||||
];
|
||||
{config, ...}: {
|
||||
flake.modules.nixos.sirius = {
|
||||
pkgs,
|
||||
hostName,
|
||||
userName,
|
||||
...
|
||||
}: {
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
desktop
|
||||
gaming
|
||||
virtualisation
|
||||
];
|
||||
|
||||
tnix = {
|
||||
boot = {
|
||||
secure-boot.enable = true;
|
||||
tnix = {
|
||||
boot = {
|
||||
secure-boot.enable = true;
|
||||
|
||||
impermanence = {
|
||||
enable = true;
|
||||
impermanence = {
|
||||
enable = true;
|
||||
|
||||
home = {
|
||||
directories = [
|
||||
"Distrobox"
|
||||
".bun"
|
||||
".rustup"
|
||||
".steam"
|
||||
".cache/awww"
|
||||
".config/BraveSoftware"
|
||||
".config/zed"
|
||||
".config/Vencord"
|
||||
".config/vesktop"
|
||||
".config/sops"
|
||||
".config/obs-studio"
|
||||
".config/easyeffects"
|
||||
".config/DankMaterialShell"
|
||||
".local/share/Steam"
|
||||
".local/share/lutris"
|
||||
".local/share/net.lutris.Lutris"
|
||||
".local/share/nvim"
|
||||
".local/share/opencode"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/share/voxtype"
|
||||
".local/state/lazygit"
|
||||
".local/share/vicinae"
|
||||
".local/share/TelegramDesktop"
|
||||
".local/state/serpantinum"
|
||||
".local/share/zed"
|
||||
];
|
||||
home = {
|
||||
directories = [
|
||||
"Distrobox"
|
||||
".bun"
|
||||
".rustup"
|
||||
".steam"
|
||||
".cache/awww"
|
||||
".config/BraveSoftware"
|
||||
".config/zed"
|
||||
".config/Vencord"
|
||||
".config/vesktop"
|
||||
".config/sops"
|
||||
".config/obs-studio"
|
||||
".config/easyeffects"
|
||||
".config/DankMaterialShell"
|
||||
".local/share/Steam"
|
||||
".local/share/lutris"
|
||||
".local/share/net.lutris.Lutris"
|
||||
".local/share/nvim"
|
||||
".local/share/opencode"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/share/voxtype"
|
||||
".local/state/lazygit"
|
||||
".local/share/vicinae"
|
||||
".local/share/TelegramDesktop"
|
||||
".local/state/serpantinum"
|
||||
".local/share/zed"
|
||||
];
|
||||
|
||||
files = [
|
||||
".wakatime.cfg"
|
||||
".config/lan-mouse/lan-mouse.pem"
|
||||
];
|
||||
};
|
||||
files = [
|
||||
".wakatime.cfg"
|
||||
".config/lan-mouse/lan-mouse.pem"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
networking = {
|
||||
openssh.enable = true;
|
||||
netbird-client.enable = true;
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
docker.nvidia.enable = true;
|
||||
qemu.enable = true;
|
||||
waydroid.enable = true;
|
||||
distrobox.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
vicinae-json = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
wireless.iwd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
Network = {
|
||||
EnableIPv6 = true;
|
||||
};
|
||||
Settings = {
|
||||
AutoConnect = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
firewall.enable = false;
|
||||
openssh.enable = true;
|
||||
netbird-client.enable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
davinci-resolve
|
||||
telegram-desktop
|
||||
impala
|
||||
];
|
||||
|
||||
# !!! DO NOT CHANGE THIS !!!
|
||||
# This should match the version used at initial install.
|
||||
system.stateVersion = "26.05";
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
docker.nvidia.enable = true;
|
||||
qemu.enable = true;
|
||||
waydroid.enable = true;
|
||||
distrobox.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
sops.secrets = {
|
||||
tux-password = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
neededForUsers = true;
|
||||
};
|
||||
|
||||
gemini-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
openrouter-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
opencode-go-api-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
netbird-key = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
|
||||
vicinae-json = {
|
||||
sopsFile = ./secrets.yaml;
|
||||
owner = userName;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
wireless.iwd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
Network = {
|
||||
EnableIPv6 = true;
|
||||
};
|
||||
Settings = {
|
||||
AutoConnect = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
firewall.enable = false;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
davinci-resolve
|
||||
telegram-desktop
|
||||
impala
|
||||
];
|
||||
|
||||
# !!! DO NOT CHANGE THIS !!!
|
||||
# This should match the version used at initial install.
|
||||
system.stateVersion = "26.05";
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,49 +1,50 @@
|
||||
{ inputs, ... }:
|
||||
{
|
||||
flake.modules.nixos.sirius =
|
||||
{ config, lib, ... }:
|
||||
let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
{inputs, ...}: {
|
||||
flake.modules.nixos.sirius = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
in {
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/nvme1n1";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [
|
||||
"defaults"
|
||||
"umask=0077"
|
||||
];
|
||||
};
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/nvme1n1";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
content = {
|
||||
type = "filesystem";
|
||||
format = "vfat";
|
||||
mountpoint = "/boot";
|
||||
mountOptions = [
|
||||
"defaults"
|
||||
"umask=0077"
|
||||
];
|
||||
};
|
||||
swap = {
|
||||
size = "70G";
|
||||
content = {
|
||||
type = "swap";
|
||||
discardPolicy = "both";
|
||||
resumeDevice = true;
|
||||
};
|
||||
};
|
||||
swap = {
|
||||
size = "70G";
|
||||
content = {
|
||||
type = "swap";
|
||||
discardPolicy = "both";
|
||||
resumeDevice = true;
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
type = "8300";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes = {
|
||||
};
|
||||
root = {
|
||||
size = "100%";
|
||||
type = "8300";
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes =
|
||||
{
|
||||
"/root" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
@@ -73,10 +74,10 @@
|
||||
mountpoint = "/persist";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,61 +1,61 @@
|
||||
{ inputs, config, ... }:
|
||||
{
|
||||
flake.modules.nixos.sirius =
|
||||
{
|
||||
lib,
|
||||
pkgs,
|
||||
system,
|
||||
...
|
||||
}@innerArgs:
|
||||
{
|
||||
imports =
|
||||
with config.flake.modules.nixos;
|
||||
[
|
||||
hardware
|
||||
]
|
||||
++ [
|
||||
inputs.cardwire.nixosModules.default
|
||||
];
|
||||
|
||||
boot.kernelParams = [ "nvidia-drm.modeset=1" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
inputs,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
flake.modules.nixos.sirius = {
|
||||
lib,
|
||||
pkgs,
|
||||
system,
|
||||
...
|
||||
} @ innerArgs: {
|
||||
imports = with config.flake.modules.nixos;
|
||||
[
|
||||
hardware
|
||||
]
|
||||
++ [
|
||||
inputs.cardwire.nixosModules.default
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
hardware = {
|
||||
nvidia = {
|
||||
modesetting.enable = true;
|
||||
open = false;
|
||||
nvidiaSettings = true;
|
||||
};
|
||||
boot.kernelParams = ["nvidia-drm.modeset=1"];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-amd"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
cpu.amd.updateMicrocode = lib.mkDefault innerArgs.config.hardware.enableRedistributableFirmware;
|
||||
hardware = {
|
||||
nvidia = {
|
||||
modesetting.enable = true;
|
||||
open = false;
|
||||
nvidiaSettings = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
xserver.videoDrivers = [ "nvidia" ];
|
||||
power-profiles-daemon.enable = true;
|
||||
|
||||
cardwire = {
|
||||
enable = true;
|
||||
settings.auto_apply_gpu_state = true;
|
||||
};
|
||||
};
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.config.cudaSupport = true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvtopPackages.full
|
||||
];
|
||||
cpu.amd.updateMicrocode = lib.mkDefault innerArgs.config.hardware.enableRedistributableFirmware;
|
||||
};
|
||||
|
||||
services = {
|
||||
xserver.videoDrivers = ["nvidia"];
|
||||
power-profiles-daemon.enable = true;
|
||||
|
||||
cardwire = {
|
||||
enable = true;
|
||||
settings.auto_apply_gpu_state = true;
|
||||
};
|
||||
};
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.config.cudaSupport = true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvtopPackages.full
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
{ config, ... }:
|
||||
{
|
||||
{config, ...}: {
|
||||
flake.modules.homeManager.sirius = {
|
||||
imports = with config.flake.modules.homeManager; [
|
||||
desktop
|
||||
@@ -45,7 +44,7 @@
|
||||
position = "bottom";
|
||||
hostname = "canopus";
|
||||
activate_on_startup = true;
|
||||
ips = [ "192.168.8.2" ];
|
||||
ips = ["192.168.8.2"];
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
@@ -1,56 +1,51 @@
|
||||
{ config, ... }:
|
||||
{
|
||||
flake.modules.nixOnDroid.vega =
|
||||
{
|
||||
pkgs,
|
||||
userEmail,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = with config.flake.modules.nixOnDroid; [
|
||||
networking
|
||||
{config, ...}: {
|
||||
flake.modules.nixOnDroid.vega = {
|
||||
pkgs,
|
||||
userEmail,
|
||||
...
|
||||
}: {
|
||||
imports = with config.flake.modules.nixOnDroid; [
|
||||
networking
|
||||
];
|
||||
|
||||
# @TODO: Broken currently
|
||||
# android-integration.am.enable = true;
|
||||
# android-integration.termux-open-url.enable = true;
|
||||
# android-integration.xdg-open.enable = true;
|
||||
# android-integration.termux-setup-storage.enable = true;
|
||||
# android-integration.termux-reload-settings.enable = true;
|
||||
|
||||
terminal.font = let
|
||||
firacode = pkgs.nerd-fonts.fira-code;
|
||||
fontPath = "share/fonts/truetype/NerdFonts/FiraCode/FiraCodeNerdFont-Regular.ttf";
|
||||
in "${firacode}/${fontPath}";
|
||||
|
||||
time.timeZone = "Asia/Kolkata";
|
||||
|
||||
tnix.networking.openssh = {
|
||||
enable = true;
|
||||
ports = [8033];
|
||||
authorizedKeys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIL+OzPUe2ECPC929DqpkM39tl/vdNAXfsRnmrGfR+X3D ${userEmail}"
|
||||
];
|
||||
|
||||
# @TODO: Broken currently
|
||||
# android-integration.am.enable = true;
|
||||
# android-integration.termux-open-url.enable = true;
|
||||
# android-integration.xdg-open.enable = true;
|
||||
# android-integration.termux-setup-storage.enable = true;
|
||||
# android-integration.termux-reload-settings.enable = true;
|
||||
|
||||
terminal.font =
|
||||
let
|
||||
firacode = pkgs.nerd-fonts.fira-code;
|
||||
fontPath = "share/fonts/truetype/NerdFonts/FiraCode/FiraCodeNerdFont-Regular.ttf";
|
||||
in
|
||||
"${firacode}/${fontPath}";
|
||||
|
||||
time.timeZone = "Asia/Kolkata";
|
||||
|
||||
tnix.networking.openssh = {
|
||||
enable = true;
|
||||
ports = [ 8033 ];
|
||||
authorizedKeys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIL+OzPUe2ECPC929DqpkM39tl/vdNAXfsRnmrGfR+X3D ${userEmail}"
|
||||
];
|
||||
};
|
||||
|
||||
user = {
|
||||
uid = 10481;
|
||||
gid = 10481;
|
||||
shell = "${pkgs.zsh}/bin/zsh";
|
||||
};
|
||||
|
||||
environment.etcBackupExtension = ".backup";
|
||||
environment.motd = "";
|
||||
environment.packages = with pkgs; [
|
||||
ncurses
|
||||
procps
|
||||
util-linux
|
||||
rsync
|
||||
gnutar
|
||||
];
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
};
|
||||
|
||||
user = {
|
||||
uid = 10481;
|
||||
gid = 10481;
|
||||
shell = "${pkgs.zsh}/bin/zsh";
|
||||
};
|
||||
|
||||
environment.etcBackupExtension = ".backup";
|
||||
environment.motd = "";
|
||||
environment.packages = with pkgs; [
|
||||
ncurses
|
||||
procps
|
||||
util-linux
|
||||
rsync
|
||||
gnutar
|
||||
];
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
{ lib, ... }:
|
||||
{
|
||||
{lib, ...}: {
|
||||
flake.modules.homeManager.vega = {
|
||||
# @TODO: Broken currently - By default it's enabled by neovim module
|
||||
programs.vim.enable = lib.mkForce false;
|
||||
|
||||
@@ -1,50 +1,44 @@
|
||||
{ config, ... }:
|
||||
{
|
||||
flake.modules.nixos.vps =
|
||||
{
|
||||
hostName,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
virtualisation
|
||||
services
|
||||
];
|
||||
{config, ...}: {
|
||||
flake.modules.nixos.vps = {hostName, ...}: {
|
||||
imports = with config.flake.modules.nixos; [
|
||||
boot
|
||||
networking
|
||||
virtualisation
|
||||
services
|
||||
];
|
||||
|
||||
tnix = {
|
||||
boot = {
|
||||
legacy.enable = true;
|
||||
tnix = {
|
||||
boot = {
|
||||
legacy.enable = true;
|
||||
|
||||
impermanence = {
|
||||
enable = true;
|
||||
impermanence = {
|
||||
enable = true;
|
||||
|
||||
home = {
|
||||
directories = [
|
||||
".local/share/nvim"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/state/lazygit"
|
||||
];
|
||||
};
|
||||
home = {
|
||||
directories = [
|
||||
".local/share/nvim"
|
||||
".local/share/zsh"
|
||||
".local/share/zoxide"
|
||||
".local/state/lazygit"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
networking.openssh.enable = true;
|
||||
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager.enable = true;
|
||||
firewall.enable = false;
|
||||
};
|
||||
networking.openssh.enable = true;
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
virtualisation = {
|
||||
docker.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
# --- Networking ---
|
||||
networking = {
|
||||
hostName = hostName;
|
||||
networkmanager.enable = true;
|
||||
firewall.enable = false;
|
||||
};
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,22 +1,23 @@
|
||||
{ inputs, ... }:
|
||||
{
|
||||
flake.modules.nixos.vps =
|
||||
{ config, lib, ... }:
|
||||
let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
isLegacy = config.tnix.boot.legacy.enable;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
{inputs, ...}: {
|
||||
flake.modules.nixos.vps = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
hasOptinPersistence = config.tnix.boot.impermanence.enable;
|
||||
isLegacy = config.tnix.boot.legacy.enable;
|
||||
in {
|
||||
imports = [
|
||||
inputs.disko.nixosModules.disko
|
||||
];
|
||||
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/sda";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions = {
|
||||
disko.devices.disk.primary = {
|
||||
device = "/dev/sda";
|
||||
type = "disk";
|
||||
content = {
|
||||
type = "gpt";
|
||||
partitions =
|
||||
{
|
||||
ESP = {
|
||||
size = "1G";
|
||||
type = "EF00";
|
||||
@@ -36,36 +37,37 @@
|
||||
content = {
|
||||
type = "btrfs";
|
||||
# Base subvolumes that always exist
|
||||
subvolumes = {
|
||||
"/root" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/";
|
||||
subvolumes =
|
||||
{
|
||||
"/root" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/";
|
||||
};
|
||||
"/nix" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"noacl"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/nix";
|
||||
};
|
||||
}
|
||||
# Conditionally merge /persist only when impermanence is enabled
|
||||
// lib.optionalAttrs hasOptinPersistence {
|
||||
"/persist" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/persist";
|
||||
};
|
||||
};
|
||||
"/nix" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"noacl"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/nix";
|
||||
};
|
||||
}
|
||||
# Conditionally merge /persist only when impermanence is enabled
|
||||
// lib.optionalAttrs hasOptinPersistence {
|
||||
"/persist" = {
|
||||
mountOptions = [
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
"space_cache=v2"
|
||||
];
|
||||
mountpoint = "/persist";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -76,7 +78,7 @@
|
||||
type = "EF02";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,17 +1,15 @@
|
||||
{
|
||||
flake.modules.nixos.vps =
|
||||
{
|
||||
lib,
|
||||
modulesPath,
|
||||
system,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/profiles/qemu-guest.nix")
|
||||
];
|
||||
flake.modules.nixos.vps = {
|
||||
lib,
|
||||
modulesPath,
|
||||
system,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/profiles/qemu-guest.nix")
|
||||
];
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
};
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
nixpkgs.hostPlatform = lib.mkDefault system;
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user