From 5dfa44689b8cf469bd0311378718eb2d52d54996 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Fri, 29 Oct 2021 13:34:46 -0700 Subject: FIREWALLD:HAS-ZONE: reload after adding zone Signed-off-by: Sean Whitton --- src/property/firewalld.lisp | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/property/firewalld.lisp b/src/property/firewalld.lisp index 1c93653..7b1ec10 100644 --- a/src/property/firewalld.lisp +++ b/src/property/firewalld.lisp @@ -149,13 +149,14 @@ FIREWALLD:POLICY.)" You will not usually need to call this property directly; it is applied by properties which add services, interfaces etc. to zones." (:desc #?"firewalld zone ${zone} exists") - (with-unapply - (%firewall-cmd nil :check `(,#?"--zone=${zone}" "--get-target") - :apply #?"--new-zone=${zone}") - :unapply - (%firewall-cmd nil :complement-check t - :check `(,#?"--zone=${zone}" "--get-target") - :apply #?"--delete-zone=${zone}"))) + (on-change (with-unapply + (%firewall-cmd nil :check `(,#?"--zone=${zone}" "--get-target") + :apply #?"--new-zone=${zone}") + :unapply + (%firewall-cmd nil :complement-check t + :check `(,#?"--zone=${zone}" "--get-target") + :apply #?"--delete-zone=${zone}")) + (%reloaded))) (defproplist zone-target :posix (zone target) (:desc #?"firewalld zone ${zone} has target ${target}") -- cgit v1.2.3