Compare commits
No commits in common. "045bea8c88331068ad32a35308c6a26994ba0b1f" and "9030a1293163ae3a1b7fb39b7d5779c28e157ab5" have entirely different histories.
045bea8c88
...
9030a12931
8 changed files with 82 additions and 159 deletions
94
flake.lock
generated
94
flake.lock
generated
|
@ -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": [
|
||||||
|
@ -160,7 +121,7 @@
|
||||||
},
|
},
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_3"
|
"systems": "systems_2"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681202837,
|
"lastModified": 1681202837,
|
||||||
|
@ -232,27 +193,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": [
|
||||||
|
@ -288,21 +228,6 @@
|
||||||
"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": 1743671943,
|
||||||
|
@ -419,10 +344,8 @@
|
||||||
"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_3",
|
||||||
|
@ -459,21 +382,6 @@
|
||||||
"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",
|
||||||
|
|
17
flake.nix
17
flake.nix
|
@ -1,15 +1,5 @@
|
||||||
{
|
{
|
||||||
inputs = {
|
inputs = {
|
||||||
nix-doom-emacs-unstraightened = {
|
|
||||||
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";
|
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";
|
||||||
|
@ -38,10 +28,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
|
||||||
|
|
|
@ -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;
|
||||||
|
|
|
@ -33,10 +33,10 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
# 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 ];
|
||||||
|
|
|
@ -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 ];
|
||||||
|
|
|
@ -25,7 +25,6 @@
|
||||||
uid = 1000;
|
uid = 1000;
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
extraGroups = [
|
extraGroups = [
|
||||||
"libvirtd"
|
|
||||||
"wheel"
|
"wheel"
|
||||||
"networkmanager"
|
"networkmanager"
|
||||||
"video"
|
"video"
|
||||||
|
|
39
nixos/vm.nix
39
nixos/vm.nix
|
@ -82,33 +82,33 @@ 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
|
# TODO: the below doesn't actually work, so I just
|
||||||
# disable wait-online entirely.
|
# 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;
|
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.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 = 32; }
|
{ address = "10.0.5.1"; prefixLength = 32; }
|
||||||
# ];
|
];
|
||||||
# };
|
};
|
||||||
# };
|
};
|
||||||
|
|
||||||
environment.systemPackages = [
|
environment.systemPackages = [
|
||||||
# For sharing filesystems
|
# For sharing filesystems
|
||||||
|
@ -135,10 +135,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
|
||||||
|
|
29
win10.xml
29
win10.xml
|
@ -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="{"driver":"ivshmem-plain","id":"shmem1","memdev":"looking-glass"}"/>
|
<qemu:arg value="{"driver":"ivshmem-plain","id":"shmem0","memdev":"looking-glass"}"/>
|
||||||
<qemu:arg value="-object"/>
|
<qemu:arg value="-object"/>
|
||||||
<qemu:arg value="{"qom-type":"memory-backend-file","id":"looking-glass","mem-path":"/dev/kvmfr0","size":134217728,"share":true}"/>
|
<qemu:arg value="{"qom-type":"memory-backend-file","id":"looking-glass","mem-path":"/dev/kvmfr0","size":134217728,"share":true}"/>
|
||||||
</qemu:commandline>
|
</qemu:commandline>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue