mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-12-07 21:42:16 -06:00
test: vaultwarden microVM
This commit is contained in:
parent
e90d05f83d
commit
7ba592c0c5
43 changed files with 4005 additions and 267 deletions
37
example/microvm/graphics.nix
Executable file
37
example/microvm/graphics.nix
Executable file
|
|
@ -0,0 +1,37 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
# TODO: did not get sommelier to work
|
||||
# run-sommelier = with pkgs; writeShellScriptBin "run-sommelier" ''
|
||||
# exec ${lib.getExe sommelier} --virtgpu-channel -- $@
|
||||
# '';
|
||||
# Working: run Wayland applications prefixed with `run-wayland-proxy`
|
||||
run-wayland-proxy =
|
||||
with pkgs;
|
||||
writeShellScriptBin "run-wayland-proxy" ''
|
||||
exec ${lib.getExe wayland-proxy-virtwl} --virtio-gpu -- $@
|
||||
'';
|
||||
# Waypipe. Needs `microvm#waypipe-client` on the host.
|
||||
run-waypipe =
|
||||
with pkgs;
|
||||
writeShellScriptBin "run-waypipe" ''
|
||||
exec ${lib.getExe waypipe}/bin/waypipe --vsock -s 2:6000 server $@
|
||||
'';
|
||||
in
|
||||
lib.mkIf config.microvm.graphics.enable {
|
||||
boot.kernelModules = [
|
||||
"drm"
|
||||
"virtio_gpu"
|
||||
];
|
||||
|
||||
environment.systemPackages = [
|
||||
#run-sommelier
|
||||
run-wayland-proxy
|
||||
run-waypipe
|
||||
];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue