diff --git a/network/files/firewall_pterodactyl-rules.j2 b/network/files/firewall_pterodactyl-rules.j2 new file mode 100644 index 0000000..c586799 --- /dev/null +++ b/network/files/firewall_pterodactyl-rules.j2 @@ -0,0 +1,10 @@ +## This file is managed by Ansible +#!/usr/sbin/nft + +table ip nat { + chain DOCKER {} +} + +table ip filter { + chain DOCKER {} +} diff --git a/network/firewall.ansible.yml b/network/firewall.ansible.yml index 13327b6..dd429a5 100644 --- a/network/firewall.ansible.yml +++ b/network/firewall.ansible.yml @@ -20,7 +20,15 @@ group: root mode: '0600' vars: - ALLOWED_PORTS: [80, 443, 25565, 51871] + ALLOWED_PORTS: [80, 443] + - name: Additional pterodactyl rules + template: + src: files/firewall_pterodactyl-rules.j2 + dest: /etc/nftables.d/pterodactyl.nft + owner: root + group: root + mode: '0600' + when: installation_type == 'gaming' - name: Enable nftables service service: name: nftables