Compare commits

..

No commits in common. "main" and "work" have entirely different histories.
main ... work

13 changed files with 175 additions and 315 deletions

211
flake.lock generated
View file

@ -6,11 +6,11 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1744557573, "lastModified": 1738087375,
"narHash": "sha256-XAyj0iDuI51BytJ1PwN53uLpzTDdznPDQFG4RwihlTQ=", "narHash": "sha256-GLyNtU9A2VN22jNRHZ2OXuFfTJLh8uEVVt+ftsKUX0c=",
"owner": "Aylur", "owner": "Aylur",
"repo": "ags", "repo": "ags",
"rev": "3ed9737bdbc8fc7a7c7ceef2165c9109f336bff6", "rev": "a6a7a0adb17740f4c34a59902701870d46fbb6a4",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -26,11 +26,11 @@
"systems": "systems" "systems": "systems"
}, },
"locked": { "locked": {
"lastModified": 1743762088, "lastModified": 1735301051,
"narHash": "sha256-f+oXT9b3xuBDmm4v4nDqJvlHabxxZRB6+pay4Ub/NvA=", "narHash": "sha256-jU88Q9tP4vuvWYGQcmOdFwI9e2uMPVYJHbXdiklIH9o=",
"owner": "Kirottu", "owner": "Kirottu",
"repo": "anyrun", "repo": "anyrun",
"rev": "786f539d69d5abcefa68978dbaa964ac14536a00", "rev": "06017e753c8886d5296768dca80745ee09402a2d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -47,11 +47,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1742571008, "lastModified": 1737670815,
"narHash": "sha256-5WgfJAeBpxiKbTR/gJvxrGYfqQRge5aUDcGKmU1YZ1Q=", "narHash": "sha256-ZCxxshGN7XooabArcoGkYSNx5yVunqjKJi2aTv6cznI=",
"owner": "aylur", "owner": "aylur",
"repo": "astal", "repo": "astal",
"rev": "dc0e5d37abe9424c53dcbd2506a4886ffee6296e", "rev": "127e9cdcbf173846a3c40ddc0abfbb038df48042",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -67,11 +67,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1745502102, "lastModified": 1739634831,
"narHash": "sha256-LqhRwzvIVPEjH0TaPgwzqpyhW6DtCrvz7FnUJDoUZh8=", "narHash": "sha256-xFnU+uUl48Icas2wPQ+ZzlL2O3n8f6J2LrzNK9f2nng=",
"owner": "nix-community", "owner": "nix-community",
"repo": "disko", "repo": "disko",
"rev": "ca27b88c88948d96feeee9ed814cbd34f53d0d70", "rev": "fa5746ecea1772cf59b3f34c5816ab3531478142",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -80,45 +80,6 @@
"type": "github" "type": "github"
} }
}, },
"doomemacs": {
"flake": false,
"locked": {
"lastModified": 1749895289,
"narHash": "sha256-b1Hl70p4OOWkcTtXRiJ3Ker9gzOjAoZfwNqxlmE1s7g=",
"owner": "doomemacs",
"repo": "doomemacs",
"rev": "e6c755305358412a71a990fc2cf592c629edde1e",
"type": "github"
},
"original": {
"owner": "doomemacs",
"repo": "doomemacs",
"type": "github"
}
},
"emacs-overlay": {
"inputs": {
"nixpkgs": [
"nix-doom-emacs-unstraightened"
],
"nixpkgs-stable": [
"nix-doom-emacs-unstraightened"
]
},
"locked": {
"lastModified": 1750753596,
"narHash": "sha256-/XQ4k8fUYrYe+utV0aCSHT9wB0wyw/E2IzwHxYySvGc=",
"owner": "nix-community",
"repo": "emacs-overlay",
"rev": "b13d55077455690a9b4e25e4077012f3ac724e2c",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "emacs-overlay",
"type": "github"
}
},
"flake-parts": { "flake-parts": {
"inputs": { "inputs": {
"nixpkgs-lib": [ "nixpkgs-lib": [
@ -127,11 +88,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1743550720, "lastModified": 1727826117,
"narHash": "sha256-hIshGgKZCgWh6AYJpJmRgFdR3WUbkY04o82X05xqQiY=", "narHash": "sha256-K5ZLCyfO/Zj9mPFldf3iwS6oZStJcU4tSpiXTMYaaL0=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "c621e8422220273271f52058f618c94e405bb0f5", "rev": "3d04084d54bedc3d6b8b736c70ef449225c361b1",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -145,11 +106,11 @@
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
}, },
"locked": { "locked": {
"lastModified": 1743550720, "lastModified": 1738453229,
"narHash": "sha256-hIshGgKZCgWh6AYJpJmRgFdR3WUbkY04o82X05xqQiY=", "narHash": "sha256-7H9XgNiGLKN1G1CgRh0vUL4AheZSYzPm+zmZ7vxbJdo=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "c621e8422220273271f52058f618c94e405bb0f5", "rev": "32ea77a06711b758da0ad9bd6a844c5740a87abd",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -160,7 +121,7 @@
}, },
"flake-utils": { "flake-utils": {
"inputs": { "inputs": {
"systems": "systems_3" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1681202837, "lastModified": 1681202837,
@ -178,16 +139,14 @@
}, },
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": "nixpkgs_3"
"nixpkgs"
]
}, },
"locked": { "locked": {
"lastModified": 1745771770, "lastModified": 1739571712,
"narHash": "sha256-kC1yYNAO69i0Q9nnQFTxu5kdwcoHRE7x4jtJyIB5QSg=", "narHash": "sha256-0UdSDV/TBY+GuxXLbrLq3l2Fq02ciyKCIMy4qmnfJXQ=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "0fbd8207e913b2d1660a7662f9ae80e5e639de65", "rev": "6d3163aea47fdb1fe19744e91306a2ea4f602292",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -232,27 +191,6 @@
"type": "github" "type": "github"
} }
}, },
"nix-doom-emacs-unstraightened": {
"inputs": {
"doomemacs": "doomemacs",
"emacs-overlay": "emacs-overlay",
"nixpkgs": [],
"systems": "systems_2"
},
"locked": {
"lastModified": 1750754709,
"narHash": "sha256-NzU+nM97aF0ECj0FYXx55fxbkxC0LnzQxBZS7oweJXA=",
"owner": "marienz",
"repo": "nix-doom-emacs-unstraightened",
"rev": "12f1fb5974ac524a43f8467fdbb54ced5cef7ffd",
"type": "github"
},
"original": {
"owner": "marienz",
"repo": "nix-doom-emacs-unstraightened",
"type": "github"
}
},
"nix-index-database": { "nix-index-database": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -260,11 +198,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1745725746, "lastModified": 1739071773,
"narHash": "sha256-iR+idGZJ191cY6NBXyVjh9QH8GVWTkvZw/w+1Igy45A=", "narHash": "sha256-/Ak+Quinhmdxa9m3shjm4lwwwqmzG8zzGhhhhgR1k9I=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nix-index-database", "repo": "nix-index-database",
"rev": "187524713d0d9b2d2c6f688b81835114d4c2a7c6", "rev": "895d81b6228bbd50a6ef22f5a58a504ca99763ea",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -288,28 +226,13 @@
"type": "github" "type": "github"
} }
}, },
"nix-templates": {
"locked": {
"lastModified": 1750839034,
"narHash": "sha256-8pimAU3boBi8rr8JVHrldIsXzi1OmyAbXqioNc3ENTg=",
"ref": "refs/heads/main",
"rev": "ddf6814856b643f7bdbbd704549d888a96612cd2",
"revCount": 6,
"type": "git",
"url": "https://git.xnia.org/evar/nix-templates"
},
"original": {
"type": "git",
"url": "https://git.xnia.org/evar/nix-templates"
}
},
"nixos-facter-modules": { "nixos-facter-modules": {
"locked": { "locked": {
"lastModified": 1743671943, "lastModified": 1738752252,
"narHash": "sha256-7sYig0+RcrR3sOL5M+2spbpFUHyEP7cnUvCaqFOBjyU=", "narHash": "sha256-/nA3tDdp/2g0FBy8966ppC2WDoyXtUWaHkZWL+N3ZKc=",
"owner": "numtide", "owner": "numtide",
"repo": "nixos-facter-modules", "repo": "nixos-facter-modules",
"rev": "58ad9691670d293a15221d4a78818e0088d2e086", "rev": "60f8b8f3f99667de6a493a44375e5506bf0c48b1",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -320,11 +243,11 @@
}, },
"nixos-hardware": { "nixos-hardware": {
"locked": { "locked": {
"lastModified": 1745503349, "lastModified": 1738816619,
"narHash": "sha256-bUGjvaPVsOfQeTz9/rLTNLDyqbzhl0CQtJJlhFPhIYw=", "narHash": "sha256-5yRlg48XmpcX5b5HesdGMOte+YuCy9rzQkJz+imcu6I=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixos-hardware", "repo": "nixos-hardware",
"rev": "f7bee55a5e551bd8e7b5b82c9bc559bc50d868d1", "rev": "2eccff41bab80839b1d25b303b53d339fbb07087",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -335,11 +258,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1743583204, "lastModified": 1737469691,
"narHash": "sha256-F7n4+KOIfWrwoQjXrL2wD9RhFYLs2/GGe/MQY1sSdlE=", "narHash": "sha256-nmKOgAU48S41dTPIXAq0AHZSehWUn6ZPrUKijHAMmIk=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "2c8d3f48d33929642c1c12cd243df4cc7d2ce434", "rev": "9e4d5190a9482a1fb9d18adf0bdb83c6e506eaab",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -351,26 +274,23 @@
}, },
"nixpkgs-lib": { "nixpkgs-lib": {
"locked": { "locked": {
"lastModified": 1743296961, "lastModified": 1738452942,
"narHash": "sha256-b1EdN3cULCqtorQ4QeWgLMrd5ZGOjLSLemfa00heasc=", "narHash": "sha256-vJzFZGaCpnmo7I6i416HaBLpC+hvcURh/BQwROcGIp8=",
"owner": "nix-community", "type": "tarball",
"repo": "nixpkgs.lib", "url": "https://github.com/NixOS/nixpkgs/archive/072a6db25e947df2f31aab9eccd0ab75d5b2da11.tar.gz"
"rev": "e4822aea2a6d1cdd36653c134cacfd64c97ff4fa",
"type": "github"
}, },
"original": { "original": {
"owner": "nix-community", "type": "tarball",
"repo": "nixpkgs.lib", "url": "https://github.com/NixOS/nixpkgs/archive/072a6db25e947df2f31aab9eccd0ab75d5b2da11.tar.gz"
"type": "github"
} }
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1743583204, "lastModified": 1730200266,
"narHash": "sha256-F7n4+KOIfWrwoQjXrL2wD9RhFYLs2/GGe/MQY1sSdlE=", "narHash": "sha256-l253w0XMT8nWHGXuXqyiIC/bMvh1VRszGXgdpQlfhvU=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "2c8d3f48d33929642c1c12cd243df4cc7d2ce434", "rev": "807e9154dcb16384b1b765ebe9cd2bba2ac287fd",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -382,11 +302,11 @@
}, },
"nixpkgs_3": { "nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1745526057, "lastModified": 1739020877,
"narHash": "sha256-ITSpPDwvLBZBnPRS2bUcHY3gZSwis/uTe255QgMtTLA=", "narHash": "sha256-mIvECo/NNdJJ/bXjNqIh8yeoSjVLAuDuTUzAo7dzs8Y=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "f771eb401a46846c1aebd20552521b233dd7e18b", "rev": "a79cfe0ebd24952b580b1cf08cd906354996d547",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -397,6 +317,22 @@
} }
}, },
"nixpkgs_4": { "nixpkgs_4": {
"locked": {
"lastModified": 1739451785,
"narHash": "sha256-3ebRdThRic9bHMuNi2IAA/ek9b32bsy8F5R4SvGTIog=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "1128e89fd5e11bb25aedbfc287733c6502202ea9",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs_5": {
"locked": { "locked": {
"lastModified": 1682134069, "lastModified": 1682134069,
"narHash": "sha256-TnI/ZXSmRxQDt2sjRYK/8j8iha4B4zP2cnQCZZ3vp7k=", "narHash": "sha256-TnI/ZXSmRxQDt2sjRYK/8j8iha4B4zP2cnQCZZ3vp7k=",
@ -419,13 +355,11 @@
"home-manager": "home-manager", "home-manager": "home-manager",
"impermanence": "impermanence", "impermanence": "impermanence",
"muse-sounds-manager": "muse-sounds-manager", "muse-sounds-manager": "muse-sounds-manager",
"nix-doom-emacs-unstraightened": "nix-doom-emacs-unstraightened",
"nix-index-database": "nix-index-database", "nix-index-database": "nix-index-database",
"nix-std": "nix-std", "nix-std": "nix-std",
"nix-templates": "nix-templates",
"nixos-facter-modules": "nixos-facter-modules", "nixos-facter-modules": "nixos-facter-modules",
"nixos-hardware": "nixos-hardware", "nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs_3", "nixpkgs": "nixpkgs_4",
"vscode-server": "vscode-server" "vscode-server": "vscode-server"
} }
}, },
@ -459,25 +393,10 @@
"type": "github" "type": "github"
} }
}, },
"systems_3": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"vscode-server": { "vscode-server": {
"inputs": { "inputs": {
"flake-utils": "flake-utils", "flake-utils": "flake-utils",
"nixpkgs": "nixpkgs_4" "nixpkgs": "nixpkgs_5"
}, },
"locked": { "locked": {
"lastModified": 1729422940, "lastModified": 1729422940,

View file

@ -1,16 +1,6 @@
{ {
inputs = { inputs = {
nix-doom-emacs-unstraightened = { nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
url = "github:marienz/nix-doom-emacs-unstraightened";
# Optional, to download less. Neither the module nor the overlay uses this input.
inputs.nixpkgs.follows = "";
};
nix-templates = {
url = "git+https://git.xnia.org/evar/nix-templates";
inputs.nixpkgs.follows = "nixpkgs";
};
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
flake-parts.url = "github:hercules-ci/flake-parts"; flake-parts.url = "github:hercules-ci/flake-parts";
vscode-server.url = "github:nix-community/nixos-vscode-server"; vscode-server.url = "github:nix-community/nixos-vscode-server";
@ -21,10 +11,7 @@
disko.inputs.nixpkgs.follows = "nixpkgs"; disko.inputs.nixpkgs.follows = "nixpkgs";
nixos-facter-modules.url = "github:numtide/nixos-facter-modules"; nixos-facter-modules.url = "github:numtide/nixos-facter-modules";
home-manager = { home-manager.url = "github:nix-community/home-manager";
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
impermanence.url = "github:nix-community/impermanence"; impermanence.url = "github:nix-community/impermanence";
nix-index-database = { nix-index-database = {
url = "github:nix-community/nix-index-database"; url = "github:nix-community/nix-index-database";
@ -38,10 +25,9 @@
}; };
}; };
outputs = outputs = inputs @ {flake-parts, ...}:
inputs@{ flake-parts, ... }: flake-parts.lib.mkFlake {inherit inputs;} {
flake-parts.lib.mkFlake { inherit inputs; } { systems = ["x86_64-linux"];
systems = [ "x86_64-linux" ];
imports = [ imports = [
./systems ./systems
./dev-shell ./dev-shell

View file

@ -5,7 +5,6 @@
imports = [ imports = [
./apps/firefox.nix ./apps/firefox.nix
./apps/syncthing.nix ./apps/syncthing.nix
./apps/zed.nix
]; ];
home.packages = [ home.packages = [
@ -24,7 +23,7 @@
pkgs.libreoffice pkgs.libreoffice
pkgs.gimp pkgs.gimp
pkgs.krita pkgs.krita
pkgs.kdePackages.okular pkgs.okular
pkgs.localsend pkgs.localsend
pkgs.ffmpeg # Generally useful pkgs.ffmpeg # Generally useful
@ -35,8 +34,6 @@
pkgs.spotify # Proprietary pkgs.spotify # Proprietary
# Documents # Documents
pkgs.kdePackages.kimageformats
pkgs.kdePackages.kdegraphics-thumbnailers
# emily suggested I try these (albiet via their web thing), so keeping them commented # emily suggested I try these (albiet via their web thing), so keeping them commented
#pkgs.typst # TeX alternative #pkgs.typst # TeX alternative
@ -52,8 +49,6 @@
#pkgs.zed-editor #pkgs.zed-editor
pkgs.obsidian pkgs.obsidian
pkgs.anki
pkgs.quickemu
]; ];
programs.mpv.enable = true; # media player programs.mpv.enable = true; # media player

View file

@ -1,22 +0,0 @@
{ pkgs, ... }:
{
programs.zed-editor = {
enable = true;
extensions = [
"dockerfile"
# disabled until https://github.com/eth0net/zed-docker-compose/issues/2
# "docker-compose"
"nix"
];
installRemoteServer = true;
userSettings = {
"vim_mode" = true;
"terminal"."shell"."program" = "fish";
"lsp"."package-version-server"."binary"."path" = pkgs.package-version-server + "/bin/package-version-server";
"lsp"."nixd"."binary"."path" = pkgs.nixd + "/bin/nixd";
"lsp"."nil"."binary"."path" = pkgs.nil + "/bin/nil";
};
};
}

View file

@ -1,23 +1,39 @@
{ {
pkgs, pkgs,
inputs,
... ...
}: }: let
{ variables = {
# VISUAL = "emacs";
EDITOR = "nvim";
};
in {
imports = [ imports = [
inputs.nix-templates.homeManagerModules.default ./xdg.nix
inputs.nix-templates.homeManagerModules.home ./terminal.nix
inputs.nix-templates.homeManagerModules.dev ./desktop.nix
# ./emacs.nix
# ./xdg.nix ./apps.nix
./git.nix
./vm.nix ./vm.nix
]; ];
home.sessionVariables = variables;
systemd.user.sessionVariables = variables;
xdg.enable = true; # TODO: what is this?
fonts.fontconfig.enable = true; # allows adding fonts from home manager config
home.packages = with pkgs; [
noto-fonts-cjk-sans
noto-fonts-cjk-serif
noto-fonts-color-emoji
];
# programs.ssh
programs.ssh = { programs.ssh = {
enable = true; enable = true;
addKeysToAgent = "1h"; addKeysToAgent = "1h";
}; };
services.ssh-agent.enable = true; services.ssh-agent.enable = true;
programs.yt-dlp.enable = true; programs.yt-dlp.enable = true;

View file

@ -32,7 +32,6 @@
pkgs.pciutils # lspci pkgs.pciutils # lspci
pkgs.usbutils # lsusb pkgs.usbutils # lsusb
pkgs.btop
pkgs.bottom pkgs.bottom
pkgs.htop pkgs.htop
pkgs.lsof pkgs.lsof

View file

@ -6,9 +6,9 @@
... ...
}: }:
{ {
imports = [ imports = [
inputs.disko.nixosModules.disko inputs.disko.nixosModules.disko
./device.nix ./device.nix
./disk-config.nix ./disk-config.nix
./hardware-configuration.nix ./hardware-configuration.nix
@ -28,15 +28,15 @@
./vm.nix ./vm.nix
(import ./kvmfr.nix { std = inputs.nix-std.lib; lib = lib; pkgs = pkgs; config = config; }) (import ./kvmfr.nix { std = inputs.nix-std.lib; lib = lib; pkgs = pkgs; config = config; })
./libvirtd.nix ./libvirtd.nix
./osrs.nix ./osrs.nix
]; ];
# So that I can get to the netgear router # So that I can get to the netgear router
# networking.extraHosts = '' networking.extraHosts = ''
# 10.0.0.152 routerlogin.net 10.0.0.152 routerlogin.net
# 10.0.0.152 www.routerlogin.net 10.0.0.152 www.routerlogin.net
# ''; '';
services.flatpak.enable = true; services.flatpak.enable = true;
xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
@ -51,7 +51,7 @@
vfio = { vfio = {
enable = true; enable = true;
earlyKMS = true; earlyKMS = true;
applyACSpatch = true; applyACSpatch = true;
}; };
@ -86,7 +86,7 @@
# }; # };
# Allows referring to this flake by the shorthand `nixos-config`, which lets you do e.g. # Allows referring to this flake by the shorthand `nixos-config`, which lets you do e.g.
# nix repl nixos-config # nix repl nixos-config
nix.registry.nixos-config.to = { nix.registry.nixos-config.to = {
type = "git"; type = "git";
url = "file://${config.users.users.evar.home}/git/nixos-framework-laptop-config"; url = "file://${config.users.users.evar.home}/git/nixos-framework-laptop-config";
@ -94,7 +94,7 @@
# In order to catch all logs, we need to mount this early enough in the boot process. # In order to catch all logs, we need to mount this early enough in the boot process.
fileSystems."/var/log".neededForBoot = true; fileSystems."/var/log".neededForBoot = true;
zramSwap = { zramSwap = {
enable = true; enable = true;
memoryPercent = 25; memoryPercent = 25;
@ -186,11 +186,7 @@
### System software ### System software
nixpkgs.config.allowUnfree = true;
environment.systemPackages = [ environment.systemPackages = [
pkgs.unifi
pkgs.git pkgs.git
pkgs.gdu pkgs.gdu
@ -258,4 +254,4 @@
# #
# For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion . # For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion .
system.stateVersion = "23.11"; # Did you read the comment? system.stateVersion = "23.11"; # Did you read the comment?
} }

View file

@ -119,16 +119,15 @@ in {
# So I can build for kernel 6.13 # So I can build for kernel 6.13
# til https://github.com/gnif/LookingGlass/pull/1154 is merged # til https://github.com/gnif/LookingGlass/pull/1154 is merged
boot.extraModulePackages = with config.boot.kernelPackages; [ boot.extraModulePackages = with config.boot.kernelPackages; [
kvmfr (kvmfr.overrideAttrs (old: {
# (kvmfr.overrideAttrs (old: { patches = [ ]; # The patches have already since been merged
# patches = [ ]; # The patches have already since been merged src = pkgs.fetchFromGitHub {
# src = pkgs.fetchFromGitHub { owner = "zeule";
# owner = "zeule"; repo = "LookingGlass";
# repo = "LookingGlass"; rev = "7740692e3000c2019e21b9861585960174dd5ddc";
# rev = "7740692e3000c2019e21b9861585960174dd5ddc"; sha256 = "sha256-2ayH8FXOn4Bflf55WvhMWTDMLwvucmofD3POI72bC+Q=";
# sha256 = "sha256-2ayH8FXOn4Bflf55WvhMWTDMLwvucmofD3POI72bC+Q="; };
# }; }))
# }))
]; ];
services.udev.packages = optionals (cfg.devices != [ ]) [ udevPackage ]; services.udev.packages = optionals (cfg.devices != [ ]) [ udevPackage ];

View file

@ -1 +0,0 @@
evar = microsoft@evar.dev

View file

@ -4,10 +4,6 @@
pkgs, pkgs,
... ...
}: { }: {
# to allow me to be an exit node
boot.kernel.sysctl."net.ipv4.ip_forward" = 1;
boot.kernel.sysctl."net.ipv6.conf.all.forwarding" = 1;
services.tailscale = { services.tailscale = {
enable = true; enable = true;
openFirewall = true; openFirewall = true;

View file

@ -25,7 +25,6 @@
uid = 1000; uid = 1000;
isNormalUser = true; isNormalUser = true;
extraGroups = [ extraGroups = [
"libvirtd"
"wheel" "wheel"
"networkmanager" "networkmanager"
"video" "video"

View file

@ -82,33 +82,34 @@ in {
# the network bridge interface with systemctl start network-addresses-winvm0.service, # the network bridge interface with systemctl start network-addresses-winvm0.service,
# and potentially toggle the link state in the vm config # and potentially toggle the link state in the vm config
# to get this working. would be good to fix it. # to get this working. would be good to fix it.
# networking.bridges = { networking.bridges = {
# "winvm0" = { "winvm0" = {
# interfaces = [ "eth0" ]; interfaces = [ "eth0" ];
# }; };
# }; };
# networking.dhcpcd.denyInterfaces = [ "winvm0" ]; networking.dhcpcd.denyInterfaces = [ "winvm0" ];
# TODO: the below doesn't actually work, so I just
# disable wait-online entirely.
# ensure the bridge network doesn't cause us to wait # ensure the bridge network doesn't cause us to wait
# on boot # on boot
# systemd.network.wait-online.ignoredInterfaces = [ "eth0" "winvm0" ]; systemd.network.wait-online.ignoredInterfaces = [ "eth0" "winvm0" ];
# systemd.network.wait-online.anyInterface = true; boot.initrd.systemd.network.wait-online.ignoredInterfaces = [ "eth0" "winvm0" ];
# boot.initrd.systemd.network.wait-online.ignoredInterfaces = [ "eth0" "winvm0" ];
# These are needed, since I'm not currently trying to # These are needed, since I'm not currently trying to
# reserve a static IP for the bridge interface # reserve a static IP for the bridge interface
# networking.defaultGateway = { address = "10.0.0.1"; interface = "eth0"; }; networking.interfaces.winvm0 = {
# networking.interfaces.winvm0 = { useDHCP = false;
# useDHCP = false; ipv4 = {
# ipv4 = { addresses = [
# addresses = [ { address = "10.0.5.1"; prefixLength = 16; }
# { address = "10.0.5.1"; prefixLength = 32; } ];
# ]; routes = [{
# }; address = "10.0.0.0";
# }; prefixLength = 16;
options = { scope = "link"; metric = "900"; };
}];
};
};
environment.systemPackages = [ environment.systemPackages = [
# For sharing filesystems # For sharing filesystems
@ -135,10 +136,7 @@ in {
hardware.graphics.enable = true; # needed for display spice opengl hardware.graphics.enable = true; # needed for display spice opengl
virtualisation.libvirtd = { virtualisation.libvirtd = {
enable = true; enable = true;
qemu = { qemu.swtpm.enable = true; # for TPM 2.0 support
swtpm.enable = true; # for TPM 2.0 support
ovmf.packages = [ pkgs.OVMFFull.fd ];
};
onBoot = "ignore"; # only start autostart vms, not just ones that were running onBoot = "ignore"; # only start autostart vms, not just ones that were running
onShutdown = "shutdown"; # always shut down the vm's cleanly onShutdown = "shutdown"; # always shut down the vm's cleanly
@ -150,25 +148,22 @@ in {
# note that the VM needs 64 MB for the shmem in side the # note that the VM needs 64 MB for the shmem in side the
# xml for the full res of the FW laptop # xml for the full res of the FW laptop
systemd.tmpfiles.rules = [ # systemd.tmpfiles.rules = [
"f /dev/shm/scream 0660 evar qemu-libvirtd -" # "f /dev/shm/scream 0660 evar qemu-libvirtd -"
]; # "f /dev/shm/looking-glass 0660 evar qemu-libvirtd -"
# ];
# service for hooking up scream for audio # service for hooking up scream for audio
systemd.user.services.scream-ivshmem = { # systemd.user.services.scream-ivshmem = {
enable = true; # enable = true;
description = "Scream"; # description = "Scream IVSHMEM";
serviceConfig = { # serviceConfig = {
ExecStart = "${pkgs.scream}/bin/scream -v -n scream -o pulse -m /dev/shm/scream"; # ExecStart = "${pkgs.scream}/bin/scream-ivshmem-pulse /dev/shm/scream";
Restart = "always"; # Restart = "always";
}; # };
wantedBy = [ "multi-user.target" ]; # wantedBy = [ "multi-user.target" ];
requires = [ # requires = [ "pulseaudio.service" ];
"pipewire-pulse.service" # };
"pipewire.service"
"sound.target"
];
};
boot = { boot = {
initrd.kernelModules = [ initrd.kernelModules = [
@ -199,9 +194,6 @@ in {
# Samba share. Primarily intended to be used via the # Samba share. Primarily intended to be used via the
# bridged network adapter for speed # bridged network adapter for speed
#
# TODO: https://www.samba.org/samba/docs/current/man-html/vfs_btrfs.8.html
# to take advantage of btrfs stuff
services.samba = { services.samba = {
enable = true; enable = true;
openFirewall = true; openFirewall = true;
@ -212,8 +204,6 @@ in {
"netbios name" = "Atreus"; "netbios name" = "Atreus";
"security" = "user"; "security" = "user";
"username map" = "${./smb-usernames.map}";
# don't show shares to people who aren't valid to see them # don't show shares to people who aren't valid to see them
"access based share enum" = "yes"; "access based share enum" = "yes";
@ -225,48 +215,21 @@ in {
"interfaces" = "virbr0"; "interfaces" = "virbr0";
# note: localhost is the ipv6 localhost ::1 # note: localhost is the ipv6 localhost ::1
"hosts allow" = "192.168.122. 100.64.0.0/10"; "hosts allow" = "192.168.122.";
# "hosts deny" = "0.0.0.0/0"; # "hosts deny" = "0.0.0.0/0";
"guest account" = "nobody"; "guest account" = "nobody";
"map to guest" = "bad user"; "map to guest" = "bad user";
# Stuff for MacOS
# see https://wiki.samba.org/index.php/Configure_Samba_to_Work_Better_with_Mac_OS_X
# for additional settings - see manpage for vfs_fruit
"vfs objects" = "fruit streams_xattr"; # load in modules, enable APPL extensions - order is critical
"fruit:metadata" = "stream"; # stores osx medatadata
"fruit:model" = "MacSamba"; # server icon in finder
"fruit:veto_appledouble" = "no"; # following stuff generally cleans up files
"fruit:zero_file_id" = "yes";
"fruit:wipe_intentionally_left_blank_rfork" = "yes";
"fruit:delete_empty_adfiles" = "yes";
"fruit:posix_rename" = "yes";
"fruit:nfs_aces" = "no"; # prevents macOS clients from motifying the UNIX mode of directories that use NFS ACEs
};
"TimeMachineBackup" = {
"fruit:time machine" = "yes";
# "fruit:time machine max size" = "SIZE";
}; };
"Virtio Shared" = { "Virtio Shared" = {
# macos spotlight indexing backend
# see smb.conf for other elasticsearch params
"spotlight backend" = "elasticsearch";
"path" = "/home/evar/Virtio Shared"; "path" = "/home/evar/Virtio Shared";
"comment" = "Virtio shared directory"; "comment" = "Virtio shared directory";
"valid users" = "evar"; "valid users" = "evar";
"force user" = "evar";
# POSIX ACE entry maps to Full Control ACL in windows # POSIX ACE entry maps to Full Control ACL in windows
"acl map full control" = "yes"; "acl map full control" = "yes";
# allow users with write access to also change perms
"dos filemode" = "yes";
# files created by a samba client have posix ace
"force create mode" = 0777; "force create mode" = 0777;
"read only" = "no"; "read only" = "no";

View file

@ -183,13 +183,26 @@
<controller type="virtio-serial" index="0"> <controller type="virtio-serial" index="0">
<address type="pci" domain="0x0000" bus="0x03" slot="0x00" function="0x0"/> <address type="pci" domain="0x0000" bus="0x03" slot="0x00" function="0x0"/>
</controller> </controller>
<filesystem type="mount" accessmode="passthrough">
<driver type="virtiofs"/>
<binary path="/run/current-system/sw/bin/virtiofsd"/>
<source dir="/home/evar/Virtio Shared/"/>
<target dir="Virtio Shared"/>
<address type="pci" domain="0x0000" bus="0x0c" slot="0x00" function="0x0"/>
</filesystem>
<interface type="network"> <interface type="network">
<mac address="52:54:00:15:1c:97"/> <mac address="52:54:00:15:1c:97"/>
<source network="default"/> <source network="default"/>
<model type="virtio"/> <model type="virtio"/>
<link state="up"/>
<address type="pci" domain="0x0000" bus="0x0a" slot="0x00" function="0x0"/> <address type="pci" domain="0x0000" bus="0x0a" slot="0x00" function="0x0"/>
</interface> </interface>
<interface type="bridge">
<mac address="52:54:00:33:7d:5e"/>
<source bridge="winvm0"/>
<model type="virtio"/>
<link state="up"/>
<address type="pci" domain="0x0000" bus="0x0b" slot="0x00" function="0x0"/>
</interface>
<serial type="pty"> <serial type="pty">
<target type="isa-serial" port="0"> <target type="isa-serial" port="0">
<model name="isa-serial"/> <model name="isa-serial"/>
@ -242,17 +255,19 @@
</source> </source>
<address type="pci" domain="0x0000" bus="0x06" slot="0x00" function="0x0"/> <address type="pci" domain="0x0000" bus="0x06" slot="0x00" function="0x0"/>
</hostdev> </hostdev>
<hostdev mode="subsystem" type="usb" managed="yes">
<source>
<vendor id="0x256c"/>
<product id="0x006b"/>
</source>
<address type="usb" bus="0" port="1"/>
</hostdev>
<watchdog model="itco" action="reset"/> <watchdog model="itco" action="reset"/>
<memballoon model="none"/> <memballoon model="none"/>
<shmem name="scream">
<model type="ivshmem-plain"/>
<size unit="M">2</size>
<address type="pci" domain="0x0000" bus="0x00" slot="0x11" function="0x0"/>
</shmem>
</devices> </devices>
<qemu:commandline> <qemu:commandline>
<qemu:arg value="-device"/> <qemu:arg value="-device"/>
<qemu:arg value="{&quot;driver&quot;:&quot;ivshmem-plain&quot;,&quot;id&quot;:&quot;shmem1&quot;,&quot;memdev&quot;:&quot;looking-glass&quot;}"/> <qemu:arg value="{&quot;driver&quot;:&quot;ivshmem-plain&quot;,&quot;id&quot;:&quot;shmem0&quot;,&quot;memdev&quot;:&quot;looking-glass&quot;}"/>
<qemu:arg value="-object"/> <qemu:arg value="-object"/>
<qemu:arg value="{&quot;qom-type&quot;:&quot;memory-backend-file&quot;,&quot;id&quot;:&quot;looking-glass&quot;,&quot;mem-path&quot;:&quot;/dev/kvmfr0&quot;,&quot;size&quot;:134217728,&quot;share&quot;:true}"/> <qemu:arg value="{&quot;qom-type&quot;:&quot;memory-backend-file&quot;,&quot;id&quot;:&quot;looking-glass&quot;,&quot;mem-path&quot;:&quot;/dev/kvmfr0&quot;,&quot;size&quot;:134217728,&quot;share&quot;:true}"/>
</qemu:commandline> </qemu:commandline>