Fix some firewall rules
This commit is contained in:
parent
7e40fd4fb3
commit
d3a7fe8158
6 changed files with 26 additions and 17 deletions
|
@ -15,6 +15,7 @@
|
|||
family = "inet";
|
||||
content = ''
|
||||
chain input {
|
||||
type filter hook input priority filter; policy drop;
|
||||
ip saddr 10.0.0.0/8 tcp dport 2049 accept comment "Accept NFS"
|
||||
}
|
||||
'';
|
||||
|
|
|
@ -1,20 +1,25 @@
|
|||
{ config, ... }:
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
imports = [ ./nginx ];
|
||||
|
||||
services.go-autoconfig = {
|
||||
enable = config.services.mailserver.enable;
|
||||
settings = {
|
||||
service_addr = ":1323";
|
||||
domain = "autoconfig.nixfox.ca";
|
||||
imap = {
|
||||
server = "mx.nixfox.ca";
|
||||
port = 143;
|
||||
};
|
||||
smtp = {
|
||||
server = "mx.nixfox.ca";
|
||||
port = 587;
|
||||
config = lib.mkIf config.services.mailserver.enable {
|
||||
services = {
|
||||
go-autoconfig = {
|
||||
enable = true;
|
||||
settings = {
|
||||
service_addr = ":1323";
|
||||
domain = "autoconfig.nixfox.ca";
|
||||
imap = {
|
||||
server = "mx.nixfox.ca";
|
||||
port = 143;
|
||||
};
|
||||
smtp = {
|
||||
server = "mx.nixfox.ca";
|
||||
port = 587;
|
||||
};
|
||||
};
|
||||
};
|
||||
cloudflare-dyndns.domains = [ config.services.go-autoconfig.settings.domain ];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
"jimbo@bloxelcom.net"
|
||||
|
||||
"bun@nixfox.ca"
|
||||
#"vice@nixfox.ca"
|
||||
"bun@bloxelcom.net"
|
||||
"yara@nixfox.ca"
|
||||
|
||||
|
@ -61,8 +62,10 @@
|
|||
};
|
||||
};
|
||||
|
||||
# Rspamd port from earlier to avoid overlap
|
||||
services.redis.servers.rspamd.port = config.mailserver.redis.port;
|
||||
services = {
|
||||
redis.servers.rspamd.port = config.mailserver.redis.port;
|
||||
cloudflare-dyndns.domains = [ config.mailserver.fqdn ];
|
||||
};
|
||||
|
||||
environment.persistence."/persist".directories = [
|
||||
"/var/vmail"
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
family = "inet";
|
||||
content = ''
|
||||
chain input {
|
||||
type filter hook input priority 0; policy drop;
|
||||
ip saddr { 10.0.0.0/8, ${config.secrets.ips.luna}, ${config.secrets.ips.corn} } tcp dport 1935 accept comment "Accept RTMP"
|
||||
}
|
||||
'';
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
family = "inet";
|
||||
content = ''
|
||||
chain input {
|
||||
type filter hook input priority filter; policy drop;
|
||||
ip saddr 10.0.0.0/8 tcp dport 1945 accept comment "Accept RTMP"
|
||||
}
|
||||
'';
|
||||
|
|
|
@ -27,11 +27,9 @@
|
|||
turn_user_lifetime = "1h";
|
||||
};
|
||||
|
||||
# Sync the IP to Cloudflare
|
||||
cloudflare-dyndns.domains = [ config.services.coturn.realm ];
|
||||
};
|
||||
|
||||
# Open coturn ports
|
||||
networking.firewall = {
|
||||
allowedUDPPorts = [
|
||||
3478
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue