nixos-config/modules/lxd/default.nix
Erwin Boskma 4cd0f83ce8
Some checks failed
/ check (push) Failing after 2m46s
Run nixfmt
2024-02-05 11:46:52 +01:00

25 lines
438 B
Nix

{ config, lib, ... }:
with lib;
let
cfg = config.eboskma.lxd;
vars = config.eboskma.var;
in
{
options.eboskma.lxd = {
enable = mkEnableOption "lxd";
};
config = mkIf cfg.enable {
virtualisation.lxd = {
enable = true;
recommendedSysctlSettings = true;
};
virtualisation.lxc = {
enable = true;
lxcfs.enable = true;
};
users.users.${vars.mainUser}.extraGroups = [ "lxd" ];
};
}