commit e629fc855aaf94a4f79a8d1fedb9f1f187f36baa parent 15a404e0f518f2a5eb02f9af54eb475b6fd1d9ee Author: Vincent Demeester <vincent@sbr.pm> Date: Fri, 24 Nov 2023 12:19:38 +0100 containers: add subnet pools configuration. It helps making kind+podman run correctly rootless. systemd-run --user --scope --property=Delegate=yes kind Signed-off-by: Vincent Demeester <vincent@sbr.pm> Diffstat:
M | systems/modules/dev/containers.nix | | | 18 | +++++++++++++++++- |
1 file changed, 17 insertions(+), 1 deletion(-)
diff --git a/systems/modules/dev/containers.nix b/systems/modules/dev/containers.nix @@ -39,7 +39,23 @@ in }; config = mkIf cfg.enable (mkMerge [ { - virtualisation.containers.enable = true; + virtualisation.containers = { + enable = true; + containersConf.settings = { + network = { + default_subnet_pools = [ + { "base" = "11.0.0.0/24"; "size" = 24; } + { + "base" = "192.168.129.0/24"; + "size" = 24; + } + { "base" = "192.168.130.0/24"; "size" = 24; } + { "base" = "192.168.131.0/24"; "size" = 24; } + { "base" = "192.168.132.0/24"; "size" = 24; } + ]; + }; + }; + }; } (mkIf cfg.docker.enable { virtualisation = {