Separate LXC, VM and microvm configs (it's getting ugly, need to tidy things up soon)
This commit is contained in:
parent
44655068b8
commit
d48bfa332c
4 changed files with 19 additions and 9 deletions
|
@ -1,7 +1,10 @@
|
|||
{ config, pkgs, lib, inputs, modulesPath, ... }:
|
||||
{
|
||||
|
||||
imports = [ ./lxc.nix ];
|
||||
imports = [
|
||||
./lxc.nix
|
||||
./vm.nix
|
||||
];
|
||||
|
||||
nix = {
|
||||
settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
|
|
12
services/minimalConfig/vm.nix
Normal file
12
services/minimalConfig/vm.nix
Normal file
|
@ -0,0 +1,12 @@
|
|||
{lib, config, modulesPath, ...}:
|
||||
let
|
||||
cfg = config.services.vm;
|
||||
in
|
||||
{
|
||||
options.services.vm = {
|
||||
enable = lib.mkEnableOption "Enable LXC container config";
|
||||
};
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.cloud-init.network.enable = true;
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue