summaryrefslogtreecommitdiff
path: root/op-mode-definitions/webproxy.xml.in
diff options
context:
space:
mode:
Diffstat (limited to 'op-mode-definitions/webproxy.xml.in')
-rw-r--r--op-mode-definitions/webproxy.xml.in50
1 files changed, 23 insertions, 27 deletions
diff --git a/op-mode-definitions/webproxy.xml.in b/op-mode-definitions/webproxy.xml.in
index 5ae1577d8..57df44ff8 100644
--- a/op-mode-definitions/webproxy.xml.in
+++ b/op-mode-definitions/webproxy.xml.in
@@ -2,43 +2,28 @@
<interfaceDefinition>
<node name="monitor">
<children>
- <node name="webproxy">
- <properties>
- <help>Monitor WebProxy service</help>
- </properties>
- <command>${vyatta_bindir}/vyatta-monitor Webproxy squid</command>
+ <node name="log">
<children>
- <node name="access-log">
- <properties>
- <help>Monitor the last lines of the squid access log</help>
- </properties>
- <command>if [ -f /var/log/squid/access.log ]; then sudo tail --follow=name /var/log/squid/access.log; else echo "WebProxy access-log does not exist"; fi</command>
- </node>
- <node name="background">
+ <node name="webproxy">
<properties>
- <help>Monitor Webproxy in the background</help>
+ <help>Monitor last lines of Webproxy log</help>
</properties>
+ <command>journalctl --no-hostname --boot --follow --unit squid.service</command>
<children>
- <node name="start">
+ <leafNode name="access-log">
<properties>
- <help>Start background monitoring of Webproxy</help>
+ <help>Monitor the last lines of the Webproxy access log</help>
</properties>
- <command>${vyatta_bindir}/vyatta-monitor-background Webproxy squid</command>
- </node>
- <node name="stop">
+ <command>if [ -f /var/log/squid/access.log ]; then sudo tail --follow=name /var/log/squid/access.log; else echo "WebProxy access-log does not exist"; fi</command>
+ </leafNode>
+ <leafNode name="cache-log">
<properties>
- <help>Stop background monitoring of Webproxy</help>
+ <help>Monitor the last lines of the Webproxy cache log</help>
</properties>
- <command>${vyatta_bindir}/vyatta-monitor-background-stop Webproxy </command>
- </node>
+ <command>if [ -f /var/log/squid/cache.log ]; then sudo tail --follow=name /var/log/squid/cache.log; else echo "WebProxy cache-log does not exist"; fi</command>
+ </leafNode>
</children>
</node>
- <node name="cache-log">
- <properties>
- <help>Monitor the last lines of the squid cache log</help>
- </properties>
- <command>if [ -f /var/log/squid/cache.log ]; then sudo tail --follow=name /var/log/squid/cache.log; else echo "WebProxy cache-log does not exist"; fi</command>
- </node>
</children>
</node>
</children>
@@ -102,6 +87,17 @@
<help>Update the webproxy blacklist database</help>
</properties>
<command>sudo ${vyos_op_scripts_dir}/webproxy_update_blacklist.sh --update-blacklist</command>
+ <children>
+ <tagNode name="vrf">
+ <properties>
+ <help>Update webproxy blacklist database via specified VRF</help>
+ <completionHelp>
+ <path>vrf name</path>
+ </completionHelp>
+ </properties>
+ <command>sudo ${vyos_op_scripts_dir}/webproxy_update_blacklist.sh --update-blacklist --vrf "${5}" </command>
+ </tagNode>
+ </children>
</node>
</children>
</node>