mirror of
https://github.com/linux-system-roles/network.git
synced 2026-01-23 02:15:17 +00:00
test: use is-active instead of is-enabled to check for firewalld
Need to test if firewalld is running - the is-active test is for that, not is-enabled Signed-off-by: Rich Megginson <rmeggins@redhat.com>
This commit is contained in:
parent
1cba1dbc61
commit
fe439dbe4d
2 changed files with 2 additions and 2 deletions
|
|
@ -120,7 +120,7 @@
|
|||
ip link set {{ dhcp_interface1 }}p master testbr
|
||||
ip link set {{ dhcp_interface2 }}p master testbr
|
||||
# Run joint DHCP4/DHCP6 server with RA enabled in veth namespace
|
||||
if systemctl is-enabled firewalld; then
|
||||
if systemctl is-active firewalld; then
|
||||
for service in dhcp dhcpv6 dhcpv6-client; do
|
||||
if ! firewall-cmd --query-service="$service"; then
|
||||
firewall-cmd --add-service "$service"
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@
|
|||
service radvd stop
|
||||
iptables -D INPUT -i testbr -p udp --dport 67:68 --sport 67:68 -j ACCEPT
|
||||
fi
|
||||
if systemctl is-enabled firewalld; then
|
||||
if systemctl is-active firewalld; then
|
||||
for service in dhcp dhcpv6 dhcpv6-client; do
|
||||
if firewall-cmd --query-service="$service"; then
|
||||
firewall-cmd --remove-service "$service"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue