mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-11-21 15:01:28 +01:00
Give the idols-ruby and idols-kana VMs a headless computer-use environment: Xvfb plus i3, driven by cua-driver (and computer-use-linux as a fallback). Includes the system module (AT-SPI, fonts, Mesa, Clash Verge proxy, proxy-region timezone), the home i3 module (Xvfb/i3/x11vnc services, browser flags), host wiring and an eval test.
52 lines
1.2 KiB
Nix
52 lines
1.2 KiB
Nix
{
|
|
# NOTE: the args not used in this file CAN NOT be removed!
|
|
# because haumea pass argument lazily,
|
|
# and these arguments are used in the functions like `mylib.nixosSystem`, `mylib.colmenaSystem`, etc.
|
|
inputs,
|
|
lib,
|
|
mylib,
|
|
myvars,
|
|
system,
|
|
genSpecialArgs,
|
|
...
|
|
}@args:
|
|
let
|
|
# 星野 瑠美衣, Hoshino Rubii
|
|
name = "ruby";
|
|
tags = [
|
|
name
|
|
"homelab-operation"
|
|
];
|
|
ssh-user = "root";
|
|
|
|
modules = {
|
|
nixos-modules =
|
|
(map mylib.relativeToRoot [
|
|
# common
|
|
"secrets/nixos.nix"
|
|
"modules/nixos/server/server.nix"
|
|
"modules/nixos/server/qemu-guest-hardware-configuration.nix"
|
|
# headless computer-use environment (sway + desktop automation)
|
|
"modules/nixos/desktop/computer-use.nix"
|
|
# host specific
|
|
"hosts/idols-${name}"
|
|
])
|
|
++ [
|
|
];
|
|
home-modules = map mylib.relativeToRoot [
|
|
# host specific
|
|
"home/hosts/linux/idols-${name}.nix"
|
|
];
|
|
};
|
|
|
|
systemArgs = modules // args;
|
|
in
|
|
{
|
|
nixosConfigurations.${name} = mylib.nixosSystem systemArgs;
|
|
|
|
colmena.${name} = mylib.colmenaSystem (systemArgs // { inherit tags ssh-user; });
|
|
|
|
# nixos tests
|
|
packages."${name}-nixos-tests" = import ../nixos-tests/idols-ruby.nix systemArgs;
|
|
}
|