diff options
author | Markus Strauss <Markus@ITstrauss.eu> | 2011-11-01 13:15:18 -0400 |
---|---|---|
committer | Markus Strauss <Markus@ITstrauss.eu> | 2011-11-01 13:18:04 -0400 |
commit | 970bd1cdab842aabda585aa99ed5f5ddb164336d (patch) | |
tree | 4afc86c7cac1b3bbac84d5a0b1a2e3a4a60918bd | |
parent | 92a6e244cbbc07c0e08912f85e92dbf288b54224 (diff) | |
download | puppet-runit-970bd1cdab842aabda585aa99ed5f5ddb164336d.tar.gz puppet-runit-970bd1cdab842aabda585aa99ed5f5ddb164336d.tar.bz2 |
fixed name of $logdir parameter
-rw-r--r-- | manifests/service.pp | 8 | ||||
-rw-r--r-- | templates/logger_run.erb | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/manifests/service.pp b/manifests/service.pp index 85a7ec5..15b3460 100644 --- a/manifests/service.pp +++ b/manifests/service.pp @@ -18,16 +18,16 @@ define runit::service ( # logging stuff $logger = true, # shall we setup an logging service; if you use 'command' before, # all output from command will be logged automatically to $logdir/current - $_logdir = undef, + $logdir = undef, $timeout = 7 # service restart/stop timeouts (only relevant for 'enabled' services) ) { # using the following construct, because '$logdir = "${rundir}/log"' in the # define statement produces compilation warnings - if $_logdir == undef { - $logdir = "${rundir}/log" + if $logdir == undef { + $_logdir = "${rundir}/log" } else { - $logdir = $_logdir + $_logdir = $logdir } # FixMe: Validate parameters diff --git a/templates/logger_run.erb b/templates/logger_run.erb index f85bf79..5c0a30b 100644 --- a/templates/logger_run.erb +++ b/templates/logger_run.erb @@ -1,5 +1,5 @@ #!/bin/sh -logdir=<%= logdir %> +logdir=<%= _logdir %> mkdir -p "${logdir}" chown <%= user %>:<%= group %> "${logdir}" exec chpst -u <%= user %>:<%= group %> svlogd -tt "${logdir}" |