aboutsummaryrefslogtreecommitdiffstats
path: root/tasks
diff options
context:
space:
mode:
authorJan Tuomi <jan@jantuomi.fi>2025-11-30 11:50:29 +0200
committerJan Tuomi <jan@jantuomi.fi>2025-11-30 11:50:29 +0200
commit5c1f0e17b8b0e9ebba6078854c1224e7f5d93ac2 (patch)
tree00412c3090e0fb48cccc074d02f0afffee9bbcc5 /tasks
parent28379e016d4ab80a0d0529d6ca08083c75a0be4d (diff)
pf changes
Diffstat (limited to 'tasks')
-rw-r--r--tasks/jail_ingress.yml3
-rw-r--r--tasks/network.yml20
2 files changed, 3 insertions, 20 deletions
diff --git a/tasks/jail_ingress.yml b/tasks/jail_ingress.yml
index 87dff41..b971372 100644
--- a/tasks/jail_ingress.yml
+++ b/tasks/jail_ingress.yml
@@ -14,6 +14,9 @@
group: wheel
mode: "0644"
+- name: Reload pf.conf
+ shell: jexec ingress pfctl -f /etc/pf.conf
+
- name: Enable gateway mode
shell: jexec ingress sysrc gateway_enable=YES && jexec ingress sysctl net.inet.ip.forwarding=1
diff --git a/tasks/network.yml b/tasks/network.yml
index 3b95380..5f60d05 100644
--- a/tasks/network.yml
+++ b/tasks/network.yml
@@ -42,28 +42,8 @@
name: syslogd
state: started
register: started_syslogd
-
#- name: Restart syslogd
# service:
# name: syslogd
# state: restarted
# when: not started_syslogd.changed and rc_conf.changed
-
-- name: Configure pf
- template:
- src: etc_pf.conf.j2
- dest: /etc/pf.conf
- owner: root
- group: wheel
- mode: "0644"
- backup: yes
- register: pf_conf
-
-- name: Start pf
- service:
- name: pf
- state: started
-
-- name: Reload pf rules
- shell: pfctl -f /etc/pf.conf
- when: pf_conf.changed