diff options
4 files changed, 105 insertions, 0 deletions
diff --git a/recipes-support/puppet/puppet/MAINT-Fix-duplicate-key-which-ruby-2.2-complains-abo.patch b/recipes-support/puppet/puppet/MAINT-Fix-duplicate-key-which-ruby-2.2-complains-abo.patch new file mode 100644 index 0000000..696c642 --- /dev/null +++ b/recipes-support/puppet/puppet/MAINT-Fix-duplicate-key-which-ruby-2.2-complains-abo.patch | |||
| @@ -0,0 +1,30 @@ | |||
| 1 | From 05dad9b1d30a8ff1e8e4a06bc5eaf0b19dab43e2 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Jasper Lievisse Adriaanse <jasper@humppa.nl> | ||
| 3 | Date: Fri, 24 Jul 2015 20:18:08 +0200 | ||
| 4 | Subject: [PATCH] (MAINT) Fix duplicate key which ruby 2.2 complains about | ||
| 5 | |||
| 6 | commit 05dad9b1d30a8ff1e8e4a06bc5eaf0b19dab43e2 from | ||
| 7 | https://github.com/puppetlabs/puppet.git | ||
| 8 | |||
| 9 | --- | ||
| 10 | lib/puppet/defaults.rb | 4 ---- | ||
| 11 | 1 file changed, 4 deletions(-) | ||
| 12 | |||
| 13 | diff --git a/lib/puppet/defaults.rb b/lib/puppet/defaults.rb | ||
| 14 | index eeefefa..b591697 100644 | ||
| 15 | --- a/lib/puppet/defaults.rb | ||
| 16 | +++ b/lib/puppet/defaults.rb | ||
| 17 | @@ -486,10 +486,6 @@ module Puppet | ||
| 18 | :default => "stomp", | ||
| 19 | :desc => "Which type of queue to use for asynchronous processing.", | ||
| 20 | }, | ||
| 21 | - :queue_type => { | ||
| 22 | - :default => "stomp", | ||
| 23 | - :desc => "Which type of queue to use for asynchronous processing.", | ||
| 24 | - }, | ||
| 25 | :queue_source => { | ||
| 26 | :default => "stomp://localhost:61613/", | ||
| 27 | :desc => "Which type of queue to use for asynchronous processing. If your stomp server requires | ||
| 28 | -- | ||
| 29 | 2.1.4 | ||
| 30 | |||
diff --git a/recipes-support/puppet/puppet/maint-Change-spec-test-to-pass-on-ruby-2.2.patch b/recipes-support/puppet/puppet/maint-Change-spec-test-to-pass-on-ruby-2.2.patch new file mode 100644 index 0000000..73e1769 --- /dev/null +++ b/recipes-support/puppet/puppet/maint-Change-spec-test-to-pass-on-ruby-2.2.patch | |||
| @@ -0,0 +1,37 @@ | |||
| 1 | From d183826136ca77847da5f3e460f2e460faabc5be Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Kylo Ginsberg <kylo@puppetlabs.com> | ||
| 3 | Date: Mon, 22 Dec 2014 10:11:38 -0800 | ||
| 4 | Subject: [PATCH] (maint) Change spec test to pass on ruby 2.2 | ||
| 5 | |||
| 6 | commit d183826136ca77847da5f3e460f2e460faabc5be from | ||
| 7 | https://github.com/puppetlabs/puppet.git | ||
| 8 | |||
| 9 | Prior to this change, this spec test failed on ruby 2.2.0-rc1 with: | ||
| 10 | |||
| 11 | Failure/Error: Time.stubs(:now).returns(Time.parse("2011-01-06 12:00:00 UTC")) | ||
| 12 | NoMethodError: | ||
| 13 | undefined method `utc_offset' for nil:NilClass | ||
| 14 | |||
| 15 | I didn't track down the root cause of this failure, but just | ||
| 16 | normalized this stub to use Time.utc, which (along with Time.local) | ||
| 17 | is the more common way of stubbing Time objects in the codebase. | ||
| 18 | --- | ||
| 19 | spec/unit/reports/store_spec.rb | 2 +- | ||
| 20 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
| 21 | |||
| 22 | diff --git a/spec/unit/reports/store_spec.rb b/spec/unit/reports/store_spec.rb | ||
| 23 | index 7f94f7d..f56eccd 100755 | ||
| 24 | --- a/spec/unit/reports/store_spec.rb | ||
| 25 | +++ b/spec/unit/reports/store_spec.rb | ||
| 26 | @@ -24,7 +24,7 @@ describe processor do | ||
| 27 | end | ||
| 28 | |||
| 29 | it "should write the report to the file in YAML" do | ||
| 30 | - Time.stubs(:now).returns(Time.parse("2011-01-06 12:00:00 UTC")) | ||
| 31 | + Time.stubs(:now).returns(Time.utc(2011,01,06,12,00,00)) | ||
| 32 | @report.process | ||
| 33 | |||
| 34 | File.read(File.join(Puppet[:reportdir], @report.host, "201101061200.yaml")).should == @report.to_yaml | ||
| 35 | -- | ||
| 36 | 2.1.4 | ||
| 37 | |||
diff --git a/recipes-support/puppet/puppet/safe_yaml-syck-isn-t-available-for-Ruby-2.0.0.patch b/recipes-support/puppet/puppet/safe_yaml-syck-isn-t-available-for-Ruby-2.0.0.patch new file mode 100644 index 0000000..1cd5e25 --- /dev/null +++ b/recipes-support/puppet/puppet/safe_yaml-syck-isn-t-available-for-Ruby-2.0.0.patch | |||
| @@ -0,0 +1,35 @@ | |||
| 1 | From fca1579d62d5b978375511e062b9c18f4413dd5a Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Mark Asselstine <mark.asselstine@windriver.com> | ||
| 3 | Date: Thu, 20 Aug 2015 14:06:32 -0400 | ||
| 4 | Subject: [PATCH] safe_yaml: syck isn't available for Ruby >= 2.0.0 | ||
| 5 | |||
| 6 | This change was taken from various puppet forks but does not exist in | ||
| 7 | puppet upstream as they drop support for YAML on the network as part | ||
| 8 | of work to fix PUP-3272. | ||
| 9 | |||
| 10 | https://tickets.puppetlabs.com/browse/PUP-3272 | ||
| 11 | |||
| 12 | Community versions of this change: | ||
| 13 | https://github.com/kylog/puppet/commit/42b2e77ec24dfbbf2317d08615a35127afbc4782 | ||
| 14 | |||
| 15 | Signed-off-by: Mark Asselstine <mark.asselstine@windriver.com> | ||
| 16 | --- | ||
| 17 | lib/puppet/vendor/safe_yaml/lib/safe_yaml.rb | 2 +- | ||
| 18 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
| 19 | |||
| 20 | diff --git a/lib/puppet/vendor/safe_yaml/lib/safe_yaml.rb b/lib/puppet/vendor/safe_yaml/lib/safe_yaml.rb | ||
| 21 | index 8670ace..722dd3e 100644 | ||
| 22 | --- a/lib/puppet/vendor/safe_yaml/lib/safe_yaml.rb | ||
| 23 | +++ b/lib/puppet/vendor/safe_yaml/lib/safe_yaml.rb | ||
| 24 | @@ -3,7 +3,7 @@ require "yaml" | ||
| 25 | # This needs to be defined up front in case any internal classes need to base | ||
| 26 | # their behavior off of this. | ||
| 27 | module SafeYAML | ||
| 28 | - YAML_ENGINE = defined?(YAML::ENGINE) ? YAML::ENGINE.yamler : "syck" | ||
| 29 | + YAML_ENGINE = defined?(YAML::ENGINE) ? YAML::ENGINE.yamler : (defined?(Psych) && YAML == Psych ? "psych" : "syck") | ||
| 30 | end | ||
| 31 | |||
| 32 | require "set" | ||
| 33 | -- | ||
| 34 | 2.1.4 | ||
| 35 | |||
diff --git a/recipes-support/puppet/puppet_3.7.3.bb b/recipes-support/puppet/puppet_3.7.3.bb index 14e18d9..3e8f869 100644 --- a/recipes-support/puppet/puppet_3.7.3.bb +++ b/recipes-support/puppet/puppet_3.7.3.bb | |||
| @@ -7,6 +7,9 @@ SRC_URI = " \ | |||
| 7 | https://downloads.puppetlabs.com/puppet/puppet-${PV}.tar.gz \ | 7 | https://downloads.puppetlabs.com/puppet/puppet-${PV}.tar.gz \ |
| 8 | file://add_puppet_gemspec.patch \ | 8 | file://add_puppet_gemspec.patch \ |
| 9 | file://puppet.conf \ | 9 | file://puppet.conf \ |
| 10 | file://maint-Change-spec-test-to-pass-on-ruby-2.2.patch \ | ||
| 11 | file://MAINT-Fix-duplicate-key-which-ruby-2.2-complains-abo.patch \ | ||
| 12 | file://safe_yaml-syck-isn-t-available-for-Ruby-2.0.0.patch \ | ||
| 10 | " | 13 | " |
| 11 | SRC_URI[md5sum] = "cc294da1d51df07bcc7f6cf78bd90ce0" | 14 | SRC_URI[md5sum] = "cc294da1d51df07bcc7f6cf78bd90ce0" |
| 12 | SRC_URI[sha256sum] = "4a3bd7ddb51072c3dd898a8de158cde204a2d8fd0b84e8ac806b84c074348637" | 15 | SRC_URI[sha256sum] = "4a3bd7ddb51072c3dd898a8de158cde204a2d8fd0b84e8ac806b84c074348637" |
