summaryrefslogtreecommitdiff
path: root/templates/system/syslog
diff options
context:
space:
mode:
authorAn-Cheng Huang <ancheng@sydney.vyatta.com>2007-10-24 10:01:04 -0700
committerAn-Cheng Huang <ancheng@sydney.vyatta.com>2007-10-24 10:01:04 -0700
commit1229e8c6f130c62c42900f424a772d4e9c5e8ef5 (patch)
treea89f7b29d4a7e62c803f3b0306922777681f319a /templates/system/syslog
parentb1fcb904eab1425d349fd7ab8d65b39c1bfb2e3f (diff)
downloadvyatta-cfg-system-1229e8c6f130c62c42900f424a772d4e9c5e8ef5.tar.gz
vyatta-cfg-system-1229e8c6f130c62c42900f424a772d4e9c5e8ef5.zip
add 'sudo' for 'system' and 'service/ssh' configuration commands.
Diffstat (limited to 'templates/system/syslog')
-rw-r--r--templates/system/syslog/console/facility/node.def7
-rw-r--r--templates/system/syslog/file/node.tag/archive/node.def6
-rw-r--r--templates/system/syslog/file/node.tag/facility/node.def8
-rw-r--r--templates/system/syslog/global/archive/node.def6
-rw-r--r--templates/system/syslog/global/facility/node.def7
-rw-r--r--templates/system/syslog/host/node.tag/facility/node.def7
-rw-r--r--templates/system/syslog/node.def2
-rw-r--r--templates/system/syslog/user/node.tag/facility/node.def8
8 files changed, 15 insertions, 36 deletions
diff --git a/templates/system/syslog/console/facility/node.def b/templates/system/syslog/console/facility/node.def
index bfe3856f..c5d0d76f 100644
--- a/templates/system/syslog/console/facility/node.def
+++ b/templates/system/syslog/console/facility/node.def
@@ -1,11 +1,8 @@
tag:
type: txt
help: "Configure facility for console logging"
-create: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
+update: "sudo sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' '\\/dev\\/console' \
\\\"$(@).\\\\\$LVL\t/dev/console\n\\\"\" "
-update: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
-/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' '\\/dev\\/console' \
-\\\"$(@).\\\\\$LVL\t/dev/console\n\\\"\" "
-delete: "sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl \
+delete: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl \
'$(@)\\.' '\\/dev\\/console' ''\" "
diff --git a/templates/system/syslog/file/node.tag/archive/node.def b/templates/system/syslog/file/node.tag/archive/node.def
index d0b0e230..6e857360 100644
--- a/templates/system/syslog/file/node.tag/archive/node.def
+++ b/templates/system/syslog/file/node.tag/archive/node.def
@@ -1,8 +1,6 @@
help: "Configure log file size and rotation characteristics"
# need mandatory files & size
-create: "sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
+update: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
'$(../@)' '$(files/@)' '$(size/@)' 1\" "
-update: "sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
-'$(../@)' '$(files/@)' '$(size/@)' 1\" "
-delete: "sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
+delete: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
'$(../@)' '$(files/@)' '$(size/@)' 0\" "
diff --git a/templates/system/syslog/file/node.tag/facility/node.def b/templates/system/syslog/file/node.tag/facility/node.def
index 3ef56e35..af3ab498 100644
--- a/templates/system/syslog/file/node.tag/facility/node.def
+++ b/templates/system/syslog/file/node.tag/facility/node.def
@@ -1,13 +1,9 @@
tag:
type: txt
help: "Configure facility for file logging"
-create: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
+update: "sudo sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' \
'\\/var\\/log\\/user\\/$(../@)' \
\\\"$(@).\\\\\$LVL\t/var/log/user/$(../@) \n\\\"\" "
-update: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
-/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' \
-'\\/var\\/log\\/user\\/$(../@)' \
-\\\"$(@).\\\\\$LVL\t/var/log/user/$(../@) \n\\\"\" "
-delete: "sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' \
+delete: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' \
'\\/var\\/log\\/user\\/$(../@)' ''\" "
diff --git a/templates/system/syslog/global/archive/node.def b/templates/system/syslog/global/archive/node.def
index dcfc2446..aefdb2d4 100644
--- a/templates/system/syslog/global/archive/node.def
+++ b/templates/system/syslog/global/archive/node.def
@@ -1,8 +1,6 @@
help: "Configure log file size and rotation characteristics"
# need mandatory files & size
-create: "sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
+update: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
'$(files/@)' '$(size/@)' 1\" "
-update: "sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
-'$(files/@)' '$(size/@)' 1\" "
-delete: "sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
+delete: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_logrotate.pl \
'$(files/@)' '$(size/@)' 0\" "
diff --git a/templates/system/syslog/global/facility/node.def b/templates/system/syslog/global/facility/node.def
index cd037f6a..1cfb8223 100644
--- a/templates/system/syslog/global/facility/node.def
+++ b/templates/system/syslog/global/facility/node.def
@@ -1,11 +1,8 @@
tag:
type: txt
help: "Configure facility for system logging"
-create: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
+update: "sudo sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
/opt/vyatta/sbin/vyatta_update_syslog.pl '' '\\/var\\/log\\/messages' \
\\\"$(@).\\\\\$LVL\t/var/log/messages \n\\\"\" "
-update: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
-/opt/vyatta/sbin/vyatta_update_syslog.pl '' '\\/var\\/log\\/messages' \
-\\\"$(@).\\\\\$LVL\t/var/log/messages \n\\\"\" "
-delete: "sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl \
+delete: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl \
'' '\\/var\\/log\\/messages' '*.warning\t/var/log/messages \n'\" "
diff --git a/templates/system/syslog/host/node.tag/facility/node.def b/templates/system/syslog/host/node.tag/facility/node.def
index 2dc56e66..f4063eed 100644
--- a/templates/system/syslog/host/node.tag/facility/node.def
+++ b/templates/system/syslog/host/node.tag/facility/node.def
@@ -1,11 +1,8 @@
tag:
type: txt
help: "Configure facility for host logging"
-create: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
+update: "sudo sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' '@$(../@) ' \
\\\"$(@).\\\\\$LVL\t@$(../@) \n\\\"\" "
-update: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
-/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' '@$(../@) ' \
-\\\"$(@).\\\\\$LVL\t@$(../@) \n\\\"\" "
-delete: "sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' \
+delete: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl '$(@)\\.' \
'@$(../@) ' ''\" "
diff --git a/templates/system/syslog/node.def b/templates/system/syslog/node.def
index 04d3675e..e6e68aba 100644
--- a/templates/system/syslog/node.def
+++ b/templates/system/syslog/node.def
@@ -1,3 +1,3 @@
help: "Configure syslog daemon"
-delete: "sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl \
+delete: "sudo sh -c \"/opt/vyatta/sbin/vyatta_update_syslog.pl \
'' '\\/var\\/log\\/messages' '*.warning\t/var/log/messages \n'\" "
diff --git a/templates/system/syslog/user/node.tag/facility/node.def b/templates/system/syslog/user/node.tag/facility/node.def
index 1b227471..6a5d7228 100644
--- a/templates/system/syslog/user/node.tag/facility/node.def
+++ b/templates/system/syslog/user/node.tag/facility/node.def
@@ -1,14 +1,10 @@
tag:
type: txt
help: "Configure facility for user logging"
-create: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
+update: "sudo sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
/opt/vyatta/sbin/vyatta_update_syslog.pl \\\"$(@)\\.\\\\\$LVL\\\" \
' $(../@) ' \
\\\"$(@).\\\\\$LVL $(../@) \n\\\"\" "
-update: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
-/opt/vyatta/sbin/vyatta_update_syslog.pl \\\"$(@)\\.\\\\\$LVL\\\" \
-' $(../@) ' \
-\\\"$(@).\\\\\$LVL $(../@) \n\\\"\" "
-delete: "sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
+delete: "sudo sh -c \"LVL=`echo -n $(level/@) | tr '[a-z]' '[A-Z]'` && \
/opt/vyatta/sbin/vyatta_update_syslog.pl \\\"$(@)\\.\\\\\$LVL\\\" \
' $(../@) ' ''\" "