30 lines
678 B
Nix
30 lines
678 B
Nix
|
{
|
||
|
name = "Podman";
|
||
|
description = ''
|
||
|
Provide support for running docker containers on the system
|
||
|
'';
|
||
|
|
||
|
nixosModule =
|
||
|
{ lib, config, ... }:
|
||
|
{
|
||
|
options.podman = {
|
||
|
containers = lib.mkOption {
|
||
|
type = lib.types.attrs;
|
||
|
};
|
||
|
};
|
||
|
|
||
|
config =
|
||
|
let
|
||
|
cfg = config.podman;
|
||
|
in
|
||
|
{
|
||
|
virtualisation.containers.enable = true;
|
||
|
virtualisation.podman.enable = true;
|
||
|
virtualisation.podman.defaultNetwork.settings.dns_enabled = true;
|
||
|
virtualisation.oci-containers.backend = "podman";
|
||
|
|
||
|
virtualisation.oci-containers.containers = cfg.containers;
|
||
|
};
|
||
|
};
|
||
|
}
|