astora: nat configuration for containers
This commit is contained in:
parent
5217f6d222
commit
45bde215f8
2
.secrets
2
.secrets
@ -1 +1 @@
|
|||||||
Subproject commit c7dc80d23b6bf67ae8e69545b430bb13f000fa03
|
Subproject commit 8ea79f48f6fec12860feee749b62cfe2833a09d8
|
@ -141,7 +141,7 @@
|
|||||||
Host catarina
|
Host catarina
|
||||||
HostName 192.168.156.102
|
HostName 192.168.156.102
|
||||||
Port 22
|
Port 22
|
||||||
User l.nafaryus
|
User l-nafaryus
|
||||||
'';
|
'';
|
||||||
|
|
||||||
programs.direnv.enable = true;
|
programs.direnv.enable = true;
|
||||||
|
@ -150,6 +150,7 @@
|
|||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
networkmanager.enable = true;
|
networkmanager.enable = true;
|
||||||
|
networkmanager.unmanaged = [ "interface-name:ve-*" ];
|
||||||
useDHCP = lib.mkDefault true;
|
useDHCP = lib.mkDefault true;
|
||||||
hostName = "astora";
|
hostName = "astora";
|
||||||
extraHosts = '''';
|
extraHosts = '''';
|
||||||
@ -157,6 +158,19 @@
|
|||||||
firewall = {
|
firewall = {
|
||||||
enable = true;
|
enable = true;
|
||||||
allowedTCPPorts = [ 80 443 ];
|
allowedTCPPorts = [ 80 443 ];
|
||||||
|
trustedInterfaces = [ "ve-+" ];
|
||||||
|
extraCommands = ''
|
||||||
|
iptables -t nat -A POSTROUTING -o wlo1 -j MASQUERADE
|
||||||
|
'';
|
||||||
|
extraStopCommands = ''
|
||||||
|
iptables -t nat -D POSTROUTING -o wlo1 -j MASQUERADE
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
nat = {
|
||||||
|
enable = true;
|
||||||
|
externalInterface = "wlo1";
|
||||||
|
internalInterfaces = [ "ve-+" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
interfaces.wlo1.ipv4.addresses = [ {
|
interfaces.wlo1.ipv4.addresses = [ {
|
||||||
|
Loading…
Reference in New Issue
Block a user