diff options
author | rhatto <rhatto@18ef50b8-d735-4ccd-97c1-689132df3dd9> | 2009-06-29 01:28:48 +0000 |
---|---|---|
committer | rhatto <rhatto@18ef50b8-d735-4ccd-97c1-689132df3dd9> | 2009-06-29 01:28:48 +0000 |
commit | 15ad80e50dd6d1ec00472c31e0e6a435949cdaf6 (patch) | |
tree | 9aa0d403f43015ddb818bbd680d46bed8773f54a /app/admin/puppet/rc.puppet.new | |
parent | 0e4c3b1a44c3b50cb801acd2d3e880f3b4207bed (diff) | |
download | mkbuilds-15ad80e50dd6d1ec00472c31e0e6a435949cdaf6.tar.gz mkbuilds-15ad80e50dd6d1ec00472c31e0e6a435949cdaf6.tar.bz2 |
puppet: enhancing init scripts
git-svn-id: svn+slack://slack.fluxo.info/var/svn/mkbuilds@492 18ef50b8-d735-4ccd-97c1-689132df3dd9
Diffstat (limited to 'app/admin/puppet/rc.puppet.new')
-rw-r--r-- | app/admin/puppet/rc.puppet.new | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/app/admin/puppet/rc.puppet.new b/app/admin/puppet/rc.puppet.new index d9738c0..b623d2a 100644 --- a/app/admin/puppet/rc.puppet.new +++ b/app/admin/puppet/rc.puppet.new @@ -1,10 +1,13 @@ #!/bin/sh +pidfile="/var/run/puppet/puppetd.pid" +options="--pidfile $pidfile" + puppet_start() { - echo "Starting puppet" - start-stop-daemon --start --quiet \ - --pidfile "/var/run/puppetd.pid" \ - --exec /usr/bin/puppetd + echo "Starting puppet" + start-stop-daemon --start --quiet \ + --pidfile $pidfile \ + --exec /usr/bin/puppetd -- $options if [ "$?" != "0" ]; then echo "Failed to start puppet" fi @@ -13,7 +16,7 @@ puppet_start() { puppet_stop() { echo "Stopping puppet" start-stop-daemon --stop --quiet \ - --pidfile "/var/run/puppet/puppetd.pid" + --pidfile $pidfile if [ "$?" != "0" ]; then echo "Failed to stop puppet" fi |