Commit 99350ae
Changed files (1)
modules
services
modules/services/podman.nix
@@ -1,10 +1,22 @@
{
- flake.modules.nixos."services/podman" = _: {
+ flake.modules.nixos."services/podman" = {config, ...}: {
virtualisation.podman = {
enable = true;
dockerCompat = true;
dockerSocket.enable = true;
autoPrune.enable = true;
};
+
+ # Enable container name DNS for all Podman networks.
+ networking.firewall.interfaces = let
+ matchAll =
+ if !config.networking.nftables.enable
+ then "podman+"
+ else "podman*";
+ in {
+ "${matchAll}".allowedUDPPorts = [53];
+ };
+
+ virtualisation.oci-containers.backend = "podman";
};
}