ports/143022: [PATCH] sysutils/puppet: fix crontab problem
Alexander Kriventsov
avk at vl.ru
Wed Jan 20 15:30:05 UTC 2010
>Number: 143022
>Category: ports
>Synopsis: [PATCH] sysutils/puppet: fix crontab problem
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: update
>Submitter-Id: current-users
>Arrival-Date: Wed Jan 20 15:30:04 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator: Alexander Kriventsov
>Release: FreeBSD RELENG_8
>Organization:
McHost
>Environment:
FreeBSD RELENG_8
>Description:
Fix issue with crontab
Original http://projects.reductivelabs.com/issues/3010
This problem was fixed in 0.25.4
>How-To-Repeat:
>Fix:
Patch attached with submission follows:
diff -urN puppet.orig/Makefile puppet/Makefile
--- puppet.orig/Makefile 2010-01-18 11:25:44.000000000 +0000
+++ puppet/Makefile 2010-01-20 15:07:16.000000000 +0000
@@ -7,6 +7,7 @@
PORTNAME= puppet
PORTVERSION= 0.25.3
+PORTREVISION= 1
CATEGORIES= sysutils
MASTER_SITES= http://www.reductivelabs.com/downloads/puppet/
diff -urN puppet.orig/files/patch-lib-puppet-provider-cron-crontab.rb puppet/files/patch-lib-puppet-provider-cron-crontab.rb
--- puppet.orig/files/patch-lib-puppet-provider-cron-crontab.rb 1970-01-01 00:00:00.000000000 +0000
+++ puppet/files/patch-lib-puppet-provider-cron-crontab.rb 2010-01-20 14:51:59.000000000 +0000
@@ -0,0 +1,25 @@
+--- lib/puppet/provider/cron/crontab.rb.orig 2010-01-11 23:55:13.000000000 +0000
++++ lib/puppet/provider/cron/crontab.rb 2010-01-19 02:49:58.000000000 +0000
+@@ -27,13 +27,18 @@
+
+ text_line :environment, :match => %r{^\w+=}
+
+- crontab = record_line :crontab, :fields => %w{special minute hour monthday month weekday command},
+- :match => %r{^\s*(?:@(\w+)|(\S+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+))\s+(.+)$},
+- :optional => %w{special minute hour weekday month monthday}, :absent => "*"
++ record_line :freebsd_special, :fields => %w{special command},
++ :match => %r{^@(\w+)\s+(.+)$}, :pre_gen => proc { |record|
++ record[:special] = "@" + record[:special]
++ }
++
++ crontab = record_line :crontab, :fields => %w{minute hour monthday month weekday command},
++ :match => %r{^\s*(\S+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(\S+)\s+(.+)$},
++ :optional => %w{minute hour weekday month monthday}, :absent => "*"
+
+ class << crontab
+ def numeric_fields
+- fields - [:command, :special]
++ fields - [:command]
+ end
+ # Do some post-processing of the parsed record. Basically just
+ # split the numeric fields on ','.
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list