Bug #656

cron entries with newlines keep being updated

Added by Tobu - almost 5 years ago. Updated over 1 year ago.

Status:Accepted Start date:
Priority:Normal Due date:
Assignee:- % Done:

0%

Category:cron
Target version:-
Affected Puppet version:0.24.7 Branch:
Keywords:cronfixit
Votes: 0

Description

Here is the puppet snippet I use:

class standalone-puppet {
        $logdest = "/var/log/puppet/cron.log"
        cron { hourly-puppet:
                command => "/usr/bin/puppet \
                        --use-nodes /etc/puppet/manifests/site.pp \
                        --logdest $logdest",
                user => root,
                minute => 48,
        }
}

Every time puppet runs and updates the cronjob, on debian, it updates the cron entry:

notice: //default/standalone-puppet/Cron[hourly-puppet]/command: command changed '/usr/bin/puppet --use-nodes /etc/puppet/manifests/site.pp --logdest /var/log/puppet/cron.log' to '/usr/bin/puppet                         --use-nodes /etc/puppet/manifests/site.pp                         --logdest /var/log/puppet/cron.log'

I’m not sure the problem is on puppet or crontab’s side, but it would be nice to prevent this. Also, maybe there is a better technique for writing long strings – here documents?


Related issues

blocks Puppet - Bug #6990: Rehabilitate cron provider Accepted 04/06/2011

History

Updated by Redmine Admin almost 4 years ago

  • Status changed from 1 to Accepted

Updated by Luke Kanies over 3 years ago

  • Target version changed from 0.25.0 to 4
  • Affected Puppet version set to 0.24.7

We’ve got multiple cron tickets now; we need to do a full sweep of them in one of these releases.

Updated by Luke Kanies about 2 years ago

  • Assignee deleted (Luke Kanies)

Updated by Nigel Kersten over 1 year ago

  • Target version deleted (4)
  • Keywords set to cronfixit

Also available in: Atom PDF