puppet 7.18.0-universal-darwin → 7.20.0-universal-darwin

Sign up to get free protection for your applications and to get access to all the features.
Files changed (46) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +25 -25
  3. data/ext/systemd/puppet.service +1 -0
  4. data/lib/puppet/face/help.rb +1 -1
  5. data/lib/puppet/face/module/list.rb +16 -7
  6. data/lib/puppet/functions/capitalize.rb +1 -1
  7. data/lib/puppet/generate/type.rb +1 -1
  8. data/lib/puppet/module/task.rb +6 -1
  9. data/lib/puppet/parser/templatewrapper.rb +1 -1
  10. data/lib/puppet/reference/configuration.rb +2 -0
  11. data/lib/puppet/type/tidy.rb +1 -1
  12. data/lib/puppet/util/json.rb +5 -2
  13. data/lib/puppet/util/resource_template.rb +1 -1
  14. data/lib/puppet/util/selinux.rb +1 -1
  15. data/lib/puppet/util.rb +12 -1
  16. data/lib/puppet/version.rb +1 -1
  17. data/man/man5/puppet.conf.5 +3 -3
  18. data/man/man8/puppet-agent.8 +1 -1
  19. data/man/man8/puppet-apply.8 +1 -1
  20. data/man/man8/puppet-catalog.8 +1 -1
  21. data/man/man8/puppet-config.8 +1 -1
  22. data/man/man8/puppet-describe.8 +1 -1
  23. data/man/man8/puppet-device.8 +1 -1
  24. data/man/man8/puppet-doc.8 +1 -1
  25. data/man/man8/puppet-epp.8 +1 -1
  26. data/man/man8/puppet-facts.8 +1 -1
  27. data/man/man8/puppet-filebucket.8 +1 -1
  28. data/man/man8/puppet-generate.8 +1 -1
  29. data/man/man8/puppet-help.8 +1 -1
  30. data/man/man8/puppet-lookup.8 +1 -1
  31. data/man/man8/puppet-module.8 +1 -1
  32. data/man/man8/puppet-node.8 +1 -1
  33. data/man/man8/puppet-parser.8 +1 -1
  34. data/man/man8/puppet-plugin.8 +1 -1
  35. data/man/man8/puppet-report.8 +1 -1
  36. data/man/man8/puppet-resource.8 +1 -1
  37. data/man/man8/puppet-script.8 +1 -1
  38. data/man/man8/puppet-ssl.8 +1 -1
  39. data/man/man8/puppet.8 +2 -2
  40. data/spec/unit/face/module/list_spec.rb +26 -0
  41. data/spec/unit/task_spec.rb +11 -0
  42. data/spec/unit/util/resource_template_spec.rb +1 -1
  43. data/spec/unit/util/selinux_spec.rb +5 -0
  44. data/spec/unit/util_spec.rb +11 -1
  45. data/tasks/manpages.rake +5 -0
  46. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f02b218f68ea2bf1606b235052f249cc0ecd367b49dfeb2b7b89c893f410ce24
4
- data.tar.gz: 439e9ec7147b6762286c967e20891056a6cac3f8924aaba80232964de8f32f01
3
+ metadata.gz: cbf13c9ad3cd1e67bca2ac2b0668e1937f16d57dcad406d9cdc108b3b6303dd5
4
+ data.tar.gz: f5ef5169468e86e6f9b2b5742027756349b9cb75dfe221f06ea4c1a8a7b9c588
5
5
  SHA512:
6
- metadata.gz: 35179f7ef29d938a4c4e8c80ef5b9f66b843e892ee0817a7303c2de5a9e20e39401019aa597fa7d7f919619f00cee7da230978921bad8a4b88471cf96d13cb70
7
- data.tar.gz: 149c2d818067d98dc89341854c608f9e45c02c62eaea024a92cf804895c455229a3f3cf7975344e1ab5334b17d7917faa903769ac1b39abc9d44f2938579d34e
6
+ metadata.gz: 505af39a6f46979710e1510f0aa9454b9d98dfe13abf0fd3baa25da3f4cd80c1da4ad8f450488490d20f8159ec49f49b00a6ea5776e2b22bfdd869ff8d3edc77
7
+ data.tar.gz: 7f478222ecc5871c1166c5a329720f92c890638369894bc6d32196b64fc0b2d0b06d79ee4b653d0b05b18c08abe302a2163024ab38c05cd1aa63e60c17746d67
data/Gemfile.lock CHANGED
@@ -1,9 +1,9 @@
1
1
  GIT
2
2
  remote: https://github.com/puppetlabs/packaging
3
- revision: 6edc2f8e4ebe3cbea96c3af9c294bcd6e2953648
3
+ revision: 43e14adf3cc3756bb5a776db9bc245c685c11f71
4
4
  branch: 1.0.x
5
5
  specs:
6
- packaging (0.107.0.9.g6edc2f8)
6
+ packaging (0.108.0)
7
7
  apt_stage_artifacts
8
8
  artifactory (~> 3)
9
9
  csv (= 3.1.5)
@@ -15,7 +15,7 @@ GIT
15
15
  PATH
16
16
  remote: .
17
17
  specs:
18
- puppet (7.18.0)
18
+ puppet (7.20.0)
19
19
  CFPropertyList (~> 2.2)
20
20
  concurrent-ruby (~> 1.0)
21
21
  deep_merge (~> 1.0)
@@ -31,8 +31,8 @@ GEM
31
31
  remote: https://artifactory.delivery.puppetlabs.net/artifactory/api/gems/rubygems/
32
32
  specs:
33
33
  CFPropertyList (2.3.6)
34
- addressable (2.8.0)
35
- public_suffix (>= 2.0.2, < 5.0)
34
+ addressable (2.8.1)
35
+ public_suffix (>= 2.0.2, < 6.0)
36
36
  apt_stage_artifacts (0.11.0)
37
37
  docopt
38
38
  artifactory (3.0.15)
@@ -48,13 +48,13 @@ GEM
48
48
  digest-crc (0.6.4)
49
49
  rake (>= 12.0.0, < 14.0.0)
50
50
  docopt (0.6.1)
51
- facter (4.2.10)
51
+ facter (4.2.12)
52
52
  hocon (~> 1.3)
53
53
  thor (>= 1.0.1, < 2.0)
54
- faraday (2.3.0)
55
- faraday-net_http (~> 2.0)
54
+ faraday (2.6.0)
55
+ faraday-net_http (>= 2.0, < 3.1)
56
56
  ruby2_keywords (>= 0.0.4)
57
- faraday-net_http (2.0.3)
57
+ faraday-net_http (3.0.0)
58
58
  fast_gettext (1.1.2)
59
59
  ffi (1.15.5)
60
60
  gettext (3.2.9)
@@ -64,7 +64,7 @@ GEM
64
64
  fast_gettext (~> 1.1.0)
65
65
  gettext (>= 3.0.2, < 3.3.0)
66
66
  locale
67
- google-apis-core (0.7.0)
67
+ google-apis-core (0.9.0)
68
68
  addressable (~> 2.5, >= 2.5.1)
69
69
  googleauth (>= 0.16.2, < 2.a)
70
70
  httpclient (>= 2.8.1, < 3.a)
@@ -73,21 +73,21 @@ GEM
73
73
  retriable (>= 2.0, < 4.a)
74
74
  rexml
75
75
  webrick
76
- google-apis-iamcredentials_v1 (0.13.0)
77
- google-apis-core (>= 0.7, < 2.a)
78
- google-apis-storage_v1 (0.18.0)
79
- google-apis-core (>= 0.7, < 2.a)
76
+ google-apis-iamcredentials_v1 (0.15.0)
77
+ google-apis-core (>= 0.9.0, < 2.a)
78
+ google-apis-storage_v1 (0.19.0)
79
+ google-apis-core (>= 0.9.0, < 2.a)
80
80
  google-cloud-core (1.6.0)
81
81
  google-cloud-env (~> 1.0)
82
82
  google-cloud-errors (~> 1.0)
83
83
  google-cloud-env (1.6.0)
84
84
  faraday (>= 0.17.3, < 3.0)
85
- google-cloud-errors (1.2.0)
86
- google-cloud-storage (1.37.0)
85
+ google-cloud-errors (1.3.0)
86
+ google-cloud-storage (1.43.0)
87
87
  addressable (~> 2.8)
88
88
  digest-crc (~> 0.4)
89
89
  google-apis-iamcredentials_v1 (~> 0.1)
90
- google-apis-storage_v1 (~> 0.1)
90
+ google-apis-storage_v1 (~> 0.19.0)
91
91
  google-cloud-core (~> 1.6)
92
92
  googleauth (>= 0.16.2, < 2.a)
93
93
  mini_mime (~> 1.0)
@@ -99,7 +99,7 @@ GEM
99
99
  os (>= 0.9, < 2.0)
100
100
  signet (>= 0.16, < 2.a)
101
101
  hashdiff (1.0.1)
102
- hiera (3.9.0)
102
+ hiera (3.10.0)
103
103
  hiera-eyaml (3.3.0)
104
104
  highline
105
105
  optimist
@@ -109,14 +109,14 @@ GEM
109
109
  httpclient (2.8.3)
110
110
  json-schema (2.8.1)
111
111
  addressable (>= 2.4)
112
- jwt (2.4.1)
112
+ jwt (2.5.0)
113
113
  locale (2.1.3)
114
114
  memoist (0.16.2)
115
115
  memory_profiler (1.0.0)
116
116
  method_source (1.0.0)
117
117
  mini_mime (1.1.2)
118
118
  minitar (0.9)
119
- msgpack (1.5.3)
119
+ msgpack (1.6.0)
120
120
  multi_json (1.15.0)
121
121
  mustache (1.1.1)
122
122
  optimist (3.0.1)
@@ -128,7 +128,7 @@ GEM
128
128
  pry (0.14.1)
129
129
  coderay (~> 1.1)
130
130
  method_source (~> 1.0)
131
- public_suffix (4.0.7)
131
+ public_suffix (5.0.0)
132
132
  puppet-resource_api (1.8.14)
133
133
  hocon (>= 1.0)
134
134
  puppetserver-ca (2.3.6)
@@ -158,7 +158,7 @@ GEM
158
158
  rspec-mocks (~> 3.11.0)
159
159
  rspec-core (3.11.0)
160
160
  rspec-support (~> 3.11.0)
161
- rspec-expectations (3.11.0)
161
+ rspec-expectations (3.11.1)
162
162
  diff-lcs (>= 1.2.0, < 2.0)
163
163
  rspec-support (~> 3.11.0)
164
164
  rspec-its (1.3.0)
@@ -167,7 +167,7 @@ GEM
167
167
  rspec-mocks (3.11.1)
168
168
  diff-lcs (>= 1.2.0, < 2.0)
169
169
  rspec-support (~> 3.11.0)
170
- rspec-support (3.11.0)
170
+ rspec-support (3.11.1)
171
171
  rubocop (0.49.1)
172
172
  parallel (~> 1.10)
173
173
  parser (>= 2.3.3.1, < 3.0)
@@ -193,7 +193,7 @@ GEM
193
193
  uber (0.1.0)
194
194
  unicode-display_width (1.8.0)
195
195
  vcr (5.1.0)
196
- webmock (3.14.0)
196
+ webmock (3.18.1)
197
197
  addressable (>= 2.8.0)
198
198
  crack (>= 0.3.2)
199
199
  hashdiff (>= 0.4.0, < 2.0.0)
@@ -235,4 +235,4 @@ DEPENDENCIES
235
235
  yard
236
236
 
237
237
  BUNDLED WITH
238
- 2.3.10
238
+ 2.3.22
@@ -10,6 +10,7 @@
10
10
  #
11
11
  [Unit]
12
12
  Description=Puppet agent
13
+ Documentation=man:puppet-agent(8)
13
14
  Wants=basic.target
14
15
  After=basic.target network.target network-online.target
15
16
 
@@ -140,7 +140,7 @@ Puppet::Face.define(:help, '0.0.1') do
140
140
 
141
141
  def erb(name)
142
142
  template = (Pathname(__FILE__).dirname + "help" + name)
143
- erb = ERB.new(template.read, nil, '-')
143
+ erb = Puppet::Util.create_erb(template.read)
144
144
  erb.filename = template.to_s
145
145
  return erb
146
146
  end
@@ -60,10 +60,12 @@ Puppet::Face.define(:module, '1.0.0') do
60
60
  when_invoked do |options|
61
61
  Puppet::ModuleTool.set_option_defaults(options)
62
62
  environment = options[:environment_instance]
63
+ modules_by_path = environment.modules_by_path
63
64
 
64
65
  {
65
66
  :environment => environment,
66
- :modules_by_path => environment.modules_by_path,
67
+ :modules_by_path => modules_by_path,
68
+ :unmet_dependencies => unmet_dependencies(environment),
67
69
  }
68
70
  end
69
71
 
@@ -103,12 +105,13 @@ Puppet::Face.define(:module, '1.0.0') do
103
105
  end
104
106
  end
105
107
 
106
- def warn_unmet_dependencies(environment)
108
+
109
+ def unmet_dependencies(environment)
107
110
  error_types = [:non_semantic_version, :version_mismatch, :missing]
108
111
 
109
- @unmet_deps = {}
112
+ unmet_deps = {}
110
113
  error_types.each do |type|
111
- @unmet_deps[type] = Hash.new do |hash, key|
114
+ unmet_deps[type] = Hash.new do |hash, key|
112
115
  hash[key] = { :errors => [], :parent => nil }
113
116
  end
114
117
  end
@@ -130,16 +133,22 @@ Puppet::Face.define(:module, '1.0.0') do
130
133
  parent_version = dep[:parent][:version]
131
134
 
132
135
  msg = _("'%{parent_name}' (%{parent_version}) requires '%{dependency_name}' (%{dependency_version})") % { parent_name: parent_name, parent_version: parent_version, dependency_name: dep_name, dependency_version: version_constraint }
133
- @unmet_deps[type][dep[:name]][:errors] << msg
134
- @unmet_deps[type][dep[:name]][:parent] = {
136
+ unmet_deps[type][dep[:name]][:errors] << msg
137
+ unmet_deps[type][dep[:name]][:parent] = {
135
138
  :name => dep[:parent][:name],
136
139
  :version => parent_version
137
140
  }
138
- @unmet_deps[type][dep[:name]][:version] = installed_version
141
+ unmet_deps[type][dep[:name]][:version] = installed_version
139
142
  end
140
143
  end
141
144
  end
142
145
  end
146
+ unmet_deps
147
+ end
148
+
149
+
150
+ def warn_unmet_dependencies(environment)
151
+ @unmet_deps = unmet_dependencies(environment)
143
152
 
144
153
  # Display unmet dependencies by category.
145
154
  error_display_order = [:non_semantic_version, :version_mismatch, :missing]
@@ -16,7 +16,7 @@
16
16
  # @example Capitalizing a String
17
17
  # ```puppet
18
18
  # 'hello'.capitalize()
19
- # upcase('hello')
19
+ # capitalize('hello')
20
20
  # ```
21
21
  # Would both result in `"Hello"`
22
22
  #
@@ -167,7 +167,7 @@ module Puppet
167
167
  templates = {}
168
168
  templates.default_proc = lambda { |hash, key|
169
169
  raise _("template was not found at '%{key}'.") % { key: key } unless Puppet::FileSystem.file?(key)
170
- template = ERB.new(File.read(key), nil, '-')
170
+ template = Puppet::Util.create_erb(File.read(key))
171
171
  template.filename = key
172
172
  template
173
173
  }
@@ -232,7 +232,12 @@ class Puppet::Module
232
232
  end
233
233
 
234
234
  def self.read_metadata(file)
235
- Puppet::Util::Json.load(Puppet::FileSystem.read(file, :encoding => 'utf-8')) if file
235
+ # MultiJSON has a bug that improperly errors when loading an empty string
236
+ # so we handle it here for now. See: PUP-11629
237
+ if file
238
+ content = Puppet::FileSystem.read(file, :encoding => 'utf-8')
239
+ content.empty? ? {} : Puppet::Util::Json.load(content)
240
+ end
236
241
  rescue SystemCallError, IOError => err
237
242
  msg = _("Error reading metadata: %{message}" % {message: err.message})
238
243
  raise InvalidMetadata.new(msg, 'puppet.tasks/unreadable-metadata')
@@ -90,7 +90,7 @@ class Puppet::Parser::TemplateWrapper
90
90
 
91
91
  result = nil
92
92
  benchmark(:debug, _("Interpolated template %{template_source} in %%{seconds} seconds") % { template_source: escaped_template_source }) do
93
- template = ERB.new(string, 0, "-")
93
+ template = Puppet::Util.create_erb(string)
94
94
  template.filename = @__file__
95
95
  result = template.result(binding)
96
96
  end
@@ -38,6 +38,8 @@ config = Puppet::Util::Reference.newreference(:configuration, :depth => 1, :doc
38
38
  val = '$confdir/hiera.yaml. However, for backwards compatibility, if a file exists at $codedir/hiera.yaml, Puppet uses that instead.'
39
39
  elsif name.to_s == 'certname'
40
40
  val = "the Host's fully qualified domain name, as determined by Facter"
41
+ elsif name.to_s == 'srv_domain'
42
+ val = 'example.com'
41
43
  end
42
44
 
43
45
  # Leave out the section information; it was apparently confusing people.
@@ -6,7 +6,7 @@ Puppet::Type.newtype(:tidy) do
6
6
 
7
7
  @doc = "Remove unwanted files based on specific criteria. Multiple
8
8
  criteria are OR'd together, so a file that is too large but is not
9
- old enough will still get tidied.
9
+ old enough will still get tidied. Ignores managed resources.
10
10
 
11
11
  If you don't specify either `age` or `size`, then all files will
12
12
  be removed.
@@ -49,13 +49,16 @@ module Puppet::Util
49
49
  def self.load(string, options = {})
50
50
  if defined? MultiJson
51
51
  begin
52
- # This ensures that JrJackson will parse very large or very small
52
+ # This ensures that JrJackson and Oj will parse very large or very small
53
53
  # numbers as floats rather than BigDecimals, which are serialized as
54
54
  # strings by the built-in JSON gem and therefore can cause schema errors,
55
55
  # for example, when we are rendering reports to JSON using `to_pson` in
56
56
  # PuppetDB.
57
- if MultiJson.adapter.name == "MultiJson::Adapters::JrJackson"
57
+ case MultiJson.adapter.name
58
+ when "MultiJson::Adapters::JrJackson"
58
59
  options[:use_bigdecimal] = false
60
+ when "MultiJson::Adapters::Oj"
61
+ options[:bigdecimal_load] = :float
59
62
  end
60
63
 
61
64
  MultiJson.load(string, options)
@@ -40,7 +40,7 @@ class Puppet::Util::ResourceTemplate
40
40
 
41
41
  def evaluate
42
42
  set_resource_variables
43
- ERB.new(Puppet::FileSystem.read(@file, :encoding => 'utf-8'), 0, "-").result(binding)
43
+ Puppet::Util.create_erb(Puppet::FileSystem.read(@file, :encoding => 'utf-8')).result(binding)
44
44
  end
45
45
 
46
46
  def initialize(file, resource)
@@ -204,7 +204,7 @@ module Puppet::Util::SELinux
204
204
  def selinux_label_support?(file)
205
205
  fstype = find_fs(file)
206
206
  return false if fstype.nil?
207
- filesystems = ['ext2', 'ext3', 'ext4', 'gfs', 'gfs2', 'xfs', 'jfs', 'btrfs', 'tmpfs']
207
+ filesystems = ['ext2', 'ext3', 'ext4', 'gfs', 'gfs2', 'xfs', 'jfs', 'btrfs', 'tmpfs', 'zfs']
208
208
  filesystems.include?(fstype)
209
209
  end
210
210
 
data/lib/puppet/util.rb CHANGED
@@ -34,6 +34,17 @@ module Util
34
34
  end
35
35
  module_function :default_env
36
36
 
37
+ if RUBY_VERSION >= "2.6"
38
+ def create_erb(content)
39
+ ERB.new(content, trim_mode: '-')
40
+ end
41
+ else
42
+ def create_erb(content)
43
+ ERB.new(content, 0, '-')
44
+ end
45
+ end
46
+ module_function :create_erb
47
+
37
48
  # @param name [String] The name of the environment variable to retrieve
38
49
  # @param mode [Symbol] Which operating system mode to use e.g. :posix or :windows. Use nil to autodetect
39
50
  # @return [String] Value of the specified environment variable. nil if it does not exist
@@ -530,7 +541,7 @@ module Util
530
541
  IO::new(f.to_i).close rescue nil
531
542
  end
532
543
  end
533
- rescue Errno::ENOENT # /proc/self/fd not found
544
+ rescue Errno::ENOENT, Errno::ENOTDIR # /proc/self/fd not found, /proc/self not a dir
534
545
  3.upto(256){|fd| IO::new(fd).close rescue nil}
535
546
  end
536
547
 
@@ -6,7 +6,7 @@
6
6
  # Raketasks and such to set the version based on the output of `git describe`
7
7
 
8
8
  module Puppet
9
- PUPPETVERSION = '7.18.0'
9
+ PUPPETVERSION = '7.20.0'
10
10
 
11
11
  ##
12
12
  # version is a public API method intended to always provide a fast and
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPETCONF" "5" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPETCONF" "5" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  \fBThis page is autogenerated; any changes will get overwritten\fR
6
6
  .
7
7
  .SH "Configuration settings"
@@ -929,7 +929,7 @@ The time to wait for data to be read from an HTTP connection\. If nothing is rea
929
929
  The HTTP User\-Agent string to send when making network requests\.
930
930
  .
931
931
  .IP "\(bu" 4
932
- \fIDefault\fR: \fBPuppet/7\.18\.0 Ruby/2\.7\.5\-p203 (x86_64\-linux)\fR
932
+ \fIDefault\fR: \fBPuppet/7\.20\.0 Ruby/2\.7\.5\-p203 (x86_64\-linux)\fR
933
933
  .
934
934
  .IP "" 0
935
935
  .
@@ -1808,7 +1808,7 @@ The maximum time to delay before an agent\'s first run when \fBsplay\fR is enabl
1808
1808
  The domain which will be queried to find the SRV records of servers to use\.
1809
1809
  .
1810
1810
  .IP "\(bu" 4
1811
- \fIDefault\fR: \fBci\-jenkins\-setup\-platform\.svc\.cluster\.local\fR
1811
+ \fIDefault\fR: \fBexample\.com\fR
1812
1812
  .
1813
1813
  .IP "" 0
1814
1814
  .
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-AGENT" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-AGENT" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-agent\fR \- The puppet agent daemon
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-APPLY" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-APPLY" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-apply\fR \- Apply Puppet manifests locally
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-CATALOG" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-CATALOG" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-catalog\fR \- Compile, save, view, and convert catalogs\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-CONFIG" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-CONFIG" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-config\fR \- Interact with Puppet\'s settings\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-DESCRIBE" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-DESCRIBE" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-describe\fR \- Display help about resource types
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-DEVICE" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-DEVICE" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-device\fR \- Manage remote network devices
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-DOC" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-DOC" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-doc\fR \- Generate Puppet references
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-EPP" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-EPP" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-epp\fR \- Interact directly with the EPP template parser/renderer\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-FACTS" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-FACTS" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-facts\fR \- Retrieve and store facts\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-FILEBUCKET" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-FILEBUCKET" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-filebucket\fR \- Store and retrieve files in a filebucket
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-GENERATE" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-GENERATE" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-generate\fR \- Generates Puppet code from Ruby definitions\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-HELP" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-HELP" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-help\fR \- Display Puppet help\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-LOOKUP" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-LOOKUP" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-lookup\fR \- Interactive Hiera lookup
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-MODULE" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-MODULE" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-module\fR \- Creates, installs and searches for modules on the Puppet Forge\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-NODE" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-NODE" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-node\fR \- View and manage node definitions\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-PARSER" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-PARSER" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-parser\fR \- Interact directly with the parser\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-PLUGIN" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-PLUGIN" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-plugin\fR \- Interact with the Puppet plugin system\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-REPORT" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-REPORT" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-report\fR \- Create, display, and submit reports\.
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-RESOURCE" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-RESOURCE" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-resource\fR \- The resource abstraction layer shell
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-SCRIPT" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-SCRIPT" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-script\fR \- Run a puppet manifests as a script without compiling a catalog
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET\-SSL" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET\-SSL" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\-ssl\fR \- Manage SSL keys and certificates for puppet SSL clients
data/man/man8/puppet.8 CHANGED
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "PUPPET" "8" "July 2022" "Puppet, Inc." "Puppet manual"
4
+ .TH "PUPPET" "8" "October 2022" "Puppet, Inc." "Puppet manual"
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBpuppet\fR
@@ -25,4 +25,4 @@ Specialized:
25
25
  catalog Compile, save, view, and convert catalogs\. describe Display help about resource types device Manage remote network devices doc Generate Puppet references epp Interact directly with the EPP template parser/renderer\. facts Retrieve and store facts\. filebucket Store and retrieve files in a filebucket generate Generates Puppet code from Ruby definitions\. node View and manage node definitions\. parser Interact directly with the parser\. plugin Interact with the Puppet plugin system\. script Run a puppet manifests as a script without compiling a catalog ssl Manage SSL keys and certificates for puppet SSL clients
26
26
  .
27
27
  .P
28
- See \'puppet help \fIsubcommand\fR \fIaction\fR\' for help on a specific subcommand action\. See \'puppet help \fIsubcommand\fR\' for help on a specific subcommand\. Puppet v7\.18\.0
28
+ See \'puppet help \fIsubcommand\fR \fIaction\fR\' for help on a specific subcommand action\. See \'puppet help \fIsubcommand\fR\' for help on a specific subcommand\. Puppet v7\.20\.0
@@ -227,4 +227,30 @@ describe "puppet module list" do
227
227
  console_output(:tree => true)
228
228
  end
229
229
  end
230
+
231
+ describe "when rendering as json" do
232
+ let(:face) { Puppet::Face[:module, :current] }
233
+ let(:action) { face.get_action(:list) }
234
+
235
+ it "should warn about missing dependencies" do
236
+ PuppetSpec::Modules.create('depender', @modpath1, :metadata => {
237
+ :version => '1.0.0',
238
+ :dependencies => [{
239
+ "version_requirement" => ">= 0.0.5",
240
+ "name" => "puppetlabs/dependable"
241
+ }]
242
+ })
243
+
244
+ result = face.list
245
+ expect(result.dig(:unmet_dependencies, :missing)).to include(
246
+ "puppetlabs/dependable" => {
247
+ errors: ["'puppetlabs-depender' (v1.0.0) requires 'puppetlabs-dependable' (>= 0.0.5)"],
248
+ parent: {
249
+ name: "puppetlabs/depender", :version=>"v1.0.0"
250
+ },
251
+ version: nil
252
+ }
253
+ )
254
+ end
255
+ end
230
256
  end
@@ -235,6 +235,17 @@ describe Puppet::Module::Task do
235
235
  tasks[0].metadata
236
236
  }.to raise_error(Puppet::Module::Task::InvalidMetadata, /whoops/)
237
237
  end
238
+
239
+ it 'returns empty hash for metadata when json metadata file is empty' do
240
+ FileUtils.mkdir_p(tasks_path)
241
+ FileUtils.touch(File.join(tasks_path, 'task.json'))
242
+ FileUtils.touch(File.join(tasks_path, 'task'))
243
+
244
+ tasks = Puppet::Module::Task.tasks_in_module(mymod)
245
+
246
+ expect(tasks.count).to eq(1)
247
+ expect(tasks[0].metadata).to eq({})
248
+ end
238
249
  end
239
250
 
240
251
  describe :validate do
@@ -39,7 +39,7 @@ describe Puppet::Util::ResourceTemplate do
39
39
 
40
40
  it "should create a template instance with the contents of the file" do
41
41
  expect(Puppet::FileSystem).to receive(:read).with("/my/template", :encoding => 'utf-8').and_return("yay")
42
- expect(ERB).to receive(:new).with("yay", 0, "-").and_return(@template)
42
+ expect(Puppet::Util).to receive(:create_erb).with("yay").and_return(@template)
43
43
 
44
44
  allow(@wrapper).to receive(:set_resource_variables)
45
45
 
@@ -65,6 +65,7 @@ describe Puppet::Util::SELinux do
65
65
  '/' => 'ext3',
66
66
  '/sys' => 'sysfs',
67
67
  '/mnt/nfs' => 'nfs',
68
+ '/mnt/zfs' => 'zfs',
68
69
  '/proc' => 'proc',
69
70
  '/dev' => 'tmpfs' })
70
71
  end
@@ -85,6 +86,10 @@ describe Puppet::Util::SELinux do
85
86
  expect(selinux_label_support?('/dev/shm/testfile')).to be_truthy
86
87
  end
87
88
 
89
+ it "should return true if zfs" do
90
+ expect(selinux_label_support?('/mnt/zfs/testfile')).to be_truthy
91
+ end
92
+
88
93
  it "should return false for a noncapable filesystem" do
89
94
  expect(selinux_label_support?('/mnt/nfs/testfile')).to be_falsey
90
95
  end
@@ -625,7 +625,7 @@ describe Puppet::Util do
625
625
  Puppet::Util.safe_posix_fork
626
626
  end
627
627
 
628
- it "should close all open file descriptors except stdin/stdout/stderr when /proc/self/fd doesn't exists" do
628
+ it "should close all open file descriptors except stdin/stdout/stderr when /proc/self/fd doesn't exist" do
629
629
  # This is ugly, but I can't really think of a better way to do it without
630
630
  # letting it actually close fds, which seems risky
631
631
  (0..2).each {|n| expect(IO).not_to receive(:new).with(n)}
@@ -635,6 +635,16 @@ describe Puppet::Util do
635
635
  Puppet::Util.safe_posix_fork
636
636
  end
637
637
 
638
+ it "should close all open file descriptors except stdin/stdout/stderr when /proc/self is not a directory" do
639
+ # This is ugly, but I can't really think of a better way to do it without
640
+ # letting it actually close fds, which seems risky
641
+ (0..2).each {|n| expect(IO).not_to receive(:new).with(n)}
642
+ (3..256).each {|n| expect(IO).to receive(:new).with(n).and_return(double('io', close: nil)) }
643
+ allow(Dir).to receive(:foreach).with('/proc/self/fd').and_raise(Errno::ENOTDIR)
644
+
645
+ Puppet::Util.safe_posix_fork
646
+ end
647
+
638
648
  it "should fork a child process to execute the block" do
639
649
  expect(Kernel).to receive(:fork).and_return(pid).and_yield
640
650
 
data/tasks/manpages.rake CHANGED
@@ -13,6 +13,11 @@ task :gen_manpages do
13
13
 
14
14
  ronn_args = '--manual="Puppet manual" --organization="Puppet, Inc." --roff'
15
15
 
16
+ unless ENV['SOURCE_DATE_EPOCH'].nil?
17
+ source_date = Time.at(ENV['SOURCE_DATE_EPOCH'].to_i).strftime('%Y-%m-%d')
18
+ ronn_args += " --date=#{source_date}"
19
+ end
20
+
16
21
  # Locate ronn
17
22
  begin
18
23
  require 'ronn'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: puppet
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.18.0
4
+ version: 7.20.0
5
5
  platform: universal-darwin
6
6
  authors:
7
7
  - Puppet Labs
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-07-22 00:00:00.000000000 Z
11
+ date: 2022-10-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: facter