unifios-utilities/ipt-enable-logs/on_boot.d/30-ipt-enable-logs-launch.sh
Pedro Pombeiro 9967161b80
ipt-enable-logs (#267)
* Add some more on_boot..d examples

* Add ipt-enable-logs
2021-11-16 22:07:24 -08:00

10 lines
232 B
Bash
Executable File

#!/bin/sh
set -e
if ! iptables-save | grep -e '\-A UBIOS_.* \--log-prefix "\[' > /dev/null; then
/mnt/data/scripts/ipt-enable-logs.sh | iptables-restore -c
else
echo "iptables already contains USER log prefixes, ignoring."
fi