summaryrefslogtreecommitdiff
path: root/extra/ebtables/ebtables.systemd
diff options
context:
space:
mode:
Diffstat (limited to 'extra/ebtables/ebtables.systemd')
-rw-r--r--extra/ebtables/ebtables.systemd21
1 files changed, 21 insertions, 0 deletions
diff --git a/extra/ebtables/ebtables.systemd b/extra/ebtables/ebtables.systemd
new file mode 100644
index 000000000..7c21ff967
--- /dev/null
+++ b/extra/ebtables/ebtables.systemd
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+CONFIG_FILE='/etc/ebtables.conf'
+
+case $1 in
+ start)
+ ebtables-restore < "$CONFIG_FILE"
+ ;;
+ stop)
+ ebtables -F
+ ;;
+ save)
+ ebtables-save > "$CONFIG_FILE"
+ ;;
+ *)
+ echo "usage: ${0##*/} {start|stop|save}" >&2
+ exit 1
+ ;;
+esac
+
+# vim:set ts=2 sw=2 ft=sh et: