diff options
-rw-r--r-- | scripts/vyatta-delete-log-file.sh | 8 | ||||
-rw-r--r-- | templates/delete/log/file/node.def | 1 | ||||
-rw-r--r-- | templates/delete/log/file/node.tag/node.def | 2 | ||||
-rw-r--r-- | templates/delete/log/node.def | 1 | ||||
-rw-r--r-- | templates/delete/node.def | 1 |
5 files changed, 13 insertions, 0 deletions
diff --git a/scripts/vyatta-delete-log-file.sh b/scripts/vyatta-delete-log-file.sh new file mode 100644 index 0000000..d0463dd --- /dev/null +++ b/scripts/vyatta-delete-log-file.sh @@ -0,0 +1,8 @@ +#!/bin/sh + +if [ -e /var/log/user/$1 ] +then + rm -f /var/log/user/$1 +else + echo "File does not exist" +fi diff --git a/templates/delete/log/file/node.def b/templates/delete/log/file/node.def new file mode 100644 index 0000000..96d455d --- /dev/null +++ b/templates/delete/log/file/node.def @@ -0,0 +1 @@ +help: Delete the specified log file diff --git a/templates/delete/log/file/node.tag/node.def b/templates/delete/log/file/node.tag/node.def new file mode 100644 index 0000000..3b9406e --- /dev/null +++ b/templates/delete/log/file/node.tag/node.def @@ -0,0 +1,2 @@ +help: Delete a specified log file +run: sudo ${vyatta_bindir}/sudo-users/vyatta-delete-log-file.sh "$4" diff --git a/templates/delete/log/node.def b/templates/delete/log/node.def new file mode 100644 index 0000000..badd128 --- /dev/null +++ b/templates/delete/log/node.def @@ -0,0 +1 @@ +help: Delete a log file diff --git a/templates/delete/node.def b/templates/delete/node.def new file mode 100644 index 0000000..80b977d --- /dev/null +++ b/templates/delete/node.def @@ -0,0 +1 @@ +help: Delete a file |