modules: system: add podman
This commit is contained in:
parent
06e7134ae0
commit
15a093ff61
|
@ -8,6 +8,7 @@
|
||||||
./language
|
./language
|
||||||
./nix
|
./nix
|
||||||
./packages
|
./packages
|
||||||
|
./podman
|
||||||
./users
|
./users
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
25
modules/system/podman/default.nix
Normal file
25
modules/system/podman/default.nix
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
# Podman related settings
|
||||||
|
{ config, inputs, lib, options, pkgs, ... }:
|
||||||
|
let
|
||||||
|
cfg = config.my.system.podman;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
options.my.system.podman = with lib; {
|
||||||
|
enable = mkEnableOption "podman configuration";
|
||||||
|
};
|
||||||
|
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
|
virtualisation.podman = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
# Use fake `docker` command to redirect to `podman`
|
||||||
|
dockerCompat = true;
|
||||||
|
|
||||||
|
# Expose a docker-like socket
|
||||||
|
dockerSocket.enable = true;
|
||||||
|
|
||||||
|
# Allow DNS resolution in the default network
|
||||||
|
defaultNetwork.dnsname.enable = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -30,6 +30,7 @@ in
|
||||||
"media" # access to media files
|
"media" # access to media files
|
||||||
"networkmanager" # wireless configuration
|
"networkmanager" # wireless configuration
|
||||||
"plugdev" # usage of ZSA keyboard tools
|
"plugdev" # usage of ZSA keyboard tools
|
||||||
|
"podman" # usage of `podman` socket
|
||||||
"video" # screen control
|
"video" # screen control
|
||||||
"wheel" # `sudo` for the user.
|
"wheel" # `sudo` for the user.
|
||||||
];
|
];
|
||||||
|
|
Loading…
Reference in a new issue