Skip to content

Commit

Permalink
CP-50546: Remove initscripts family (#6090)
Browse files Browse the repository at this point in the history
initscripts family are legacy and want to be removed

`service iptables save` call
/usr/libexec/initscripts/legacy-actions/iptables/save, which call `exec
/usr/libexec/iptables/iptables.init save`, to save iptables rules and
remove initscripts, we call following directly
`/usr/libexec/iptables/iptables.init save`

`service` command are also updated to `systemctl`
  • Loading branch information
robhoes authored Oct 30, 2024
2 parents a767100 + c122bc4 commit 6c08d45
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions scripts/plugins/firewall-port
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,14 @@ case "${OP}" in
iptables -I INPUT -j "${CHAIN}"
fi # asuume chain is used if it exists
iptables -I "${CHAIN}" $RULE
service iptables save
/usr/libexec/iptables/iptables.init save
fi
;;
close)
if iptables -C $CHAIN $RULE 2>/dev/null
then # close port if it was opened
iptables -D $CHAIN $RULE
service iptables save
/usr/libexec/iptables/iptables.init save
fi
;;
check)
Expand Down
2 changes: 1 addition & 1 deletion scripts/xe-syslog-reconfigure
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@ else
fi

[ -s /etc/syslog.$$ ] && mv -f /etc/syslog.$$ $conf_file
service $service restart
systemctl restart $service

0 comments on commit 6c08d45

Please sign in to comment.