docker: Make interface name dependent on whether nftables is used
This commit is contained in:
parent
f3857b3bae
commit
9546c19d9b
1 changed files with 3 additions and 1 deletions
|
@ -5,6 +5,8 @@
|
||||||
}:
|
}:
|
||||||
with lib; let
|
with lib; let
|
||||||
cfg = config.eboskma.podman;
|
cfg = config.eboskma.podman;
|
||||||
|
|
||||||
|
podmanInterfaces = if config.networking.nftables.enable then "podman*" else "podman+";
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.eboskma.podman = {
|
options.eboskma.podman = {
|
||||||
|
@ -55,7 +57,7 @@ in
|
||||||
users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = [ "podman" ];
|
users.extraUsers.${config.eboskma.var.mainUser}.extraGroups = [ "podman" ];
|
||||||
|
|
||||||
# Make DNS work in containers
|
# Make DNS work in containers
|
||||||
networking.firewall.interfaces."podman*" = {
|
networking.firewall.interfaces.${podmanInterfaces} = {
|
||||||
allowedUDPPorts = [ 53 ];
|
allowedUDPPorts = [ 53 ];
|
||||||
allowedTCPPorts = [ 53 ];
|
allowedTCPPorts = [ 53 ];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue