1
Fork 0

vm: add admin endpoint

This commit is contained in:
Motiejus Jakštys 2024-01-20 14:35:18 +02:00
parent 34ba024d56
commit 7d6143a832
2 changed files with 10 additions and 0 deletions

View File

@ -121,6 +121,7 @@
nixosConfigurations.vm = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
{nixpkgs.overlays = [overlay];}
"${nixpkgs}/nixos/modules/virtualisation/qemu-vm.nix"
./vm.nix
self.nixosModules.e11sync

9
vm.nix
View File

@ -13,6 +13,10 @@
auto_https off
debug
'';
virtualHosts."http://:8003".extraConfig = ''
redir / /admin/
${builtins.readFile "${pkgs.e11sync-caddyfile}"}
'';
};
environment.systemPackages = with pkgs; [
@ -37,6 +41,11 @@
host.port = 8001;
guest.port = 8001;
}
{
from = "host";
host.port = 8003;
guest.port = 8003;
}
];
};
security.sudo.wheelNeedsPassword = false;