summaryrefslogtreecommitdiff
path: root/op-mode-definitions
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2024-05-23 21:56:42 +0200
committerGitHub <noreply@github.com>2024-05-23 21:56:42 +0200
commit9f9fb8d63f920f90ff7b299e4f70a5325fee95f3 (patch)
tree316959f83eaf5f6096260c65e00c929bcd296af1 /op-mode-definitions
parent3e69d8bbe01b7d03c894e21ac322974799098676 (diff)
parent01464a6069fa7cf02d5545c02ed03fa69679c32c (diff)
downloadvyos-1x-9f9fb8d63f920f90ff7b299e4f70a5325fee95f3.tar.gz
vyos-1x-9f9fb8d63f920f90ff7b299e4f70a5325fee95f3.zip
Merge pull request #3399 from 0xThiebaut/suricata
suricata: T751: Initial support for suricata
Diffstat (limited to 'op-mode-definitions')
-rw-r--r--op-mode-definitions/suricata.xml.in23
1 files changed, 23 insertions, 0 deletions
diff --git a/op-mode-definitions/suricata.xml.in b/op-mode-definitions/suricata.xml.in
new file mode 100644
index 000000000..a5025afba
--- /dev/null
+++ b/op-mode-definitions/suricata.xml.in
@@ -0,0 +1,23 @@
+<?xml version="1.0"?>
+<interfaceDefinition>
+ <node name="update">
+ <children>
+ <node name="suricata">
+ <properties>
+ <help>Update Suricata</help>
+ </properties>
+ <command>if test -f /run/suricata/suricata.yaml; then sudo suricata-update --suricata-conf /run/suricata/suricata.yaml; sudo systemctl restart suricata; else echo "Service Suricata not configured"; fi </command>
+ </node>
+ </children>
+ </node>
+ <node name="restart">
+ <children>
+ <node name="suricata">
+ <properties>
+ <help>Restart Suricata service</help>
+ </properties>
+ <command>if systemctl is-active --quiet suricata; then sudo systemctl restart suricata.service; else echo "Service Suricata not configured"; fi</command>
+ </node>
+ </children>
+ </node>
+</interfaceDefinition>