add docker
This commit is contained in:
parent
0b6e55da82
commit
325a193a38
@ -19,6 +19,7 @@
|
||||
virt.enable = true;
|
||||
hyprland.enable = true;
|
||||
kde.enable = true;
|
||||
docker.enable = true;
|
||||
};
|
||||
|
||||
home-manager = {
|
||||
|
||||
@ -2,5 +2,6 @@
|
||||
{
|
||||
imports = [
|
||||
./nixos
|
||||
./docker.nix
|
||||
];
|
||||
}
|
||||
|
||||
20
modules/nix/containers/docker.nix
Normal file
20
modules/nix/containers/docker.nix
Normal file
@ -0,0 +1,20 @@
|
||||
{
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkOption types;
|
||||
in
|
||||
{
|
||||
options.smayzy.docker.enable = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
description = "enable docker";
|
||||
};
|
||||
|
||||
config = mkIf config.smayzy.docker.enable {
|
||||
virtualisation.docker.enable = true;
|
||||
users.extraGroups.docker.members = [ "smayzy" ];
|
||||
};
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user