puppet 0.23.0 → 0.23.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of puppet might be problematic. Click here for more details.

Files changed (125) hide show
  1. data/CHANGELOG +58 -0
  2. data/Rakefile +1 -1
  3. data/bin/filebucket +6 -6
  4. data/bin/puppetca +11 -1
  5. data/bin/puppetmasterd +7 -6
  6. data/conf/redhat/client.init +1 -0
  7. data/conf/redhat/{puppetd.conf → puppet.conf} +1 -1
  8. data/conf/redhat/puppet.spec +43 -31
  9. data/conf/redhat/server.init +1 -0
  10. data/lib/puppet.rb +3 -3
  11. data/lib/puppet/configuration.rb +16 -5
  12. data/lib/puppet/metatype/attributes.rb +12 -19
  13. data/lib/puppet/metatype/evaluation.rb +10 -1
  14. data/lib/puppet/metatype/instances.rb +39 -15
  15. data/lib/puppet/metatype/manager.rb +1 -28
  16. data/lib/puppet/metatype/metaparams.rb +20 -16
  17. data/lib/puppet/metatype/providers.rb +8 -2
  18. data/lib/puppet/metatype/schedules.rb +14 -19
  19. data/lib/puppet/{modules.rb → module.rb} +2 -0
  20. data/lib/puppet/network/authstore.rb +5 -1
  21. data/lib/puppet/network/client/dipper.rb +2 -2
  22. data/lib/puppet/network/client/master.rb +18 -9
  23. data/lib/puppet/network/handler/fileserver.rb +3 -6
  24. data/lib/puppet/network/handler/report.rb +2 -1
  25. data/lib/puppet/network/server/mongrel.rb +4 -2
  26. data/lib/puppet/network/xmlrpc/client.rb +10 -3
  27. data/lib/puppet/parameter.rb +11 -4
  28. data/lib/puppet/parser/ast/collexpr.rb +10 -10
  29. data/lib/puppet/parser/ast/hostclass.rb +2 -2
  30. data/lib/puppet/parser/ast/resourceparam.rb +4 -3
  31. data/lib/puppet/parser/ast/resourceref.rb +16 -2
  32. data/lib/puppet/parser/collector.rb +8 -4
  33. data/lib/puppet/parser/functions.rb +5 -2
  34. data/lib/puppet/parser/interpreter.rb +48 -9
  35. data/lib/puppet/parser/lexer.rb +2 -1
  36. data/lib/puppet/parser/parser.rb +669 -589
  37. data/lib/puppet/parser/resource.rb +20 -11
  38. data/lib/puppet/parser/resource/param.rb +21 -10
  39. data/lib/puppet/parser/resource/reference.rb +2 -2
  40. data/lib/puppet/parser/scope.rb +22 -10
  41. data/lib/puppet/{type/property.rb → property.rb} +48 -15
  42. data/lib/puppet/propertychange.rb +3 -3
  43. data/lib/puppet/provider/cron/crontab.rb +38 -36
  44. data/lib/puppet/provider/host/netinfo.rb +1 -2
  45. data/lib/puppet/provider/mailalias/aliases.rb +31 -0
  46. data/lib/puppet/provider/maillist/mailman.rb +113 -0
  47. data/lib/puppet/provider/mount.rb +5 -11
  48. data/lib/puppet/provider/mount/parsed.rb +2 -2
  49. data/lib/puppet/provider/package/appdmg.rb +1 -2
  50. data/lib/puppet/provider/package/apt.rb +3 -1
  51. data/lib/puppet/provider/package/aptrpm.rb +14 -4
  52. data/lib/puppet/provider/package/blastwave.rb +6 -4
  53. data/lib/puppet/provider/package/dpkg.rb +12 -4
  54. data/lib/puppet/provider/package/pkgdmg.rb +2 -2
  55. data/lib/puppet/provider/package/rpm.rb +11 -1
  56. data/lib/puppet/provider/package/rug.rb +1 -0
  57. data/lib/puppet/provider/package/urpmi.rb +11 -1
  58. data/lib/puppet/provider/package/yum.rb +12 -2
  59. data/lib/puppet/provider/parsedfile.rb +36 -6
  60. data/lib/puppet/rails.rb +9 -2
  61. data/lib/puppet/rails/param_name.rb +2 -3
  62. data/lib/puppet/rails/param_value.rb +20 -1
  63. data/lib/puppet/rails/resource.rb +8 -2
  64. data/lib/puppet/reference/configuration.rb +14 -16
  65. data/lib/puppet/reference/type.rb +4 -4
  66. data/lib/puppet/transaction.rb +4 -4
  67. data/lib/puppet/type.rb +19 -6
  68. data/lib/puppet/type/component.rb +9 -3
  69. data/lib/puppet/type/cron.rb +10 -4
  70. data/lib/puppet/type/exec.rb +9 -5
  71. data/lib/puppet/type/group.rb +2 -3
  72. data/lib/puppet/type/mailalias.rb +50 -0
  73. data/lib/puppet/type/maillist.rb +57 -0
  74. data/lib/puppet/type/mount.rb +25 -11
  75. data/lib/puppet/type/package.rb +6 -27
  76. data/lib/puppet/type/pfile.rb +5 -6
  77. data/lib/puppet/type/pfile/source.rb +8 -2
  78. data/lib/puppet/type/pfilebucket.rb +4 -3
  79. data/lib/puppet/type/resources.rb +1 -3
  80. data/lib/puppet/type/schedule.rb +16 -16
  81. data/lib/puppet/type/service.rb +4 -1
  82. data/lib/puppet/type/tidy.rb +1 -2
  83. data/lib/puppet/type/user.rb +2 -3
  84. data/lib/puppet/type/yumrepo.rb +2 -2
  85. data/lib/puppet/util.rb +29 -4
  86. data/lib/puppet/util/autoload.rb +45 -16
  87. data/lib/puppet/util/fileparsing.rb +23 -6
  88. data/lib/puppet/util/filetype.rb +12 -1
  89. data/lib/puppet/util/log.rb +2 -2
  90. data/lib/puppet/util/log_paths.rb +16 -0
  91. data/lib/puppet/util/reference.rb +2 -2
  92. data/test/language/ast/hostclass.rb +21 -4
  93. data/test/language/ast/resourceref.rb +95 -0
  94. data/test/language/functions.rb +5 -5
  95. data/test/language/interpreter.rb +129 -1
  96. data/test/language/node.rb +13 -2
  97. data/test/language/resource.rb +26 -1
  98. data/test/language/scope.rb +25 -5
  99. data/test/lib/puppettest/support/collection.rb +2 -2
  100. data/test/network/client/master.rb +28 -42
  101. data/test/network/server/mongrel_test.rb +7 -1
  102. data/test/other/propertychange.rb +2 -2
  103. data/test/other/transactions.rb +44 -5
  104. data/test/puppet/modules.rb +2 -1
  105. data/test/rails/ast.rb +7 -8
  106. data/test/rails/collection.rb +2 -2
  107. data/test/rails/railsresource.rb +21 -5
  108. data/test/ral/manager/attributes.rb +33 -1
  109. data/test/ral/manager/instances.rb +33 -6
  110. data/test/ral/manager/type.rb +29 -49
  111. data/test/ral/providers/cron/crontab.rb +61 -13
  112. data/test/ral/providers/mailalias/aliases.rb +57 -0
  113. data/test/ral/providers/mount/parsed.rb +4 -4
  114. data/test/ral/providers/package/apt.rb +13 -1
  115. data/test/ral/providers/parsedfile.rb +20 -7
  116. data/test/ral/types/cron.rb +17 -1
  117. data/test/ral/types/mailalias.rb +50 -0
  118. data/test/ral/types/mount.rb +35 -2
  119. data/test/ral/types/package.rb +10 -2
  120. data/test/ral/types/parameter.rb +4 -4
  121. data/test/ral/types/property.rb +39 -1
  122. data/test/util/autoload.rb +33 -18
  123. data/test/util/filetype.rb +49 -3
  124. metadata +13 -6
  125. data/lib/puppet/element.rb +0 -52
data/CHANGELOG CHANGED
@@ -1,3 +1,61 @@
1
+ You can now specify relationships to classes, which work
2
+ exactly like relationships to defined types:
3
+ require => Class[myclass]
4
+ This works with qualified classes, too.
5
+
6
+ You can now do simple queries in a collection of
7
+ exported resources. You still cannot do multi-condition queries,
8
+ though. (#703)
9
+
10
+ puppetca now exits with a non-zero code if it cannot
11
+ find any host certificates to clean. (Patch by Dean
12
+ Wilson.)
13
+
14
+ Fully-qualified resources can now have defaults. (#589)
15
+
16
+ Resource references can now be fully-qualified names,
17
+ meaning you can list definitions with a namespace as
18
+ dependencies. (#468)
19
+
20
+ Files modified using a FileType instance, as ParsedFile
21
+ does, will now automatically get backed up to the filebucket
22
+ named "puppet".
23
+
24
+ Added a 'maillist' type for managing mailing lists.
25
+
26
+ Added a 'mailalias' type for managing mail aliases.
27
+
28
+ Added patch by Valentin Vidic that adds the '+>' syntax to
29
+ resources, so parameter values can be added to.
30
+
31
+ The configuration client now pulls libraries down to $libdir,
32
+ and all autoloading is done from there with full support
33
+ for any reloadable file, such as types and providers. (#621)
34
+ Note that this is not backward compatible -- if you're using
35
+ pluginsync right now, you'll need to disable it on your clients
36
+ until you can upgrade them.
37
+
38
+ The Rails log level can now be set via (shockingly!) the
39
+ 'rails_loglevel' parameter (#710). Note that this isn't
40
+ exactly the feature asked for, but I could not find a
41
+ way to directly copy ActiveRecord's concept of an environment.
42
+
43
+ External node sources can now return undefined classes (#687).
44
+
45
+ Puppet clients now have http proxy support (#701).
46
+
47
+ The parser now throws an error when a resource reference
48
+ is created for an unknown type. Also, resource references
49
+ look up defined types and translate their type accordingly. (#706)
50
+
51
+ Hostnames can now be double quoted.
52
+
53
+ Adding module autoloading (#596) -- you can now 'include' classes
54
+ from modules without ever needing to specifically load them.
55
+
56
+ Class names and node names now conflict (#620).
57
+
58
+ 0.23.0
1
59
  Modified the fileserver to cache file information, so that
2
60
  each file isn't being read on every connection. Also,
3
61
  added londo's patch from #678 to avoid reading entire files
data/Rakefile CHANGED
@@ -138,4 +138,4 @@ task :dailyclean do
138
138
  end
139
139
  end
140
140
 
141
- # $Id: Rakefile 2630 2007-06-19 23:11:10Z luke $
141
+ # $Id: Rakefile 2635 2007-06-19 23:44:20Z luke $
@@ -7,7 +7,7 @@
7
7
  #
8
8
  # = Usage
9
9
  #
10
- # pbucket [-h|--help] [-V|--version] [-d|--debug] [-v|--verbose]
10
+ # filebucket [-h|--help] [-V|--version] [-d|--debug] [-v|--verbose]
11
11
  # [-l|--local] [-r|--remote]
12
12
  # [-s|--server <server>] [-b|--bucket <directory>] <file> <file> ...
13
13
  #
@@ -34,16 +34,16 @@
34
34
  # to this argument; you are not restricted to restoring the content to its
35
35
  # original location.
36
36
  #
37
- # Note that +pbucket+ defaults to using a network-based filebucket available on
37
+ # Note that +filebucket+ defaults to using a network-based filebucket available on
38
38
  # the server named +puppet+. To use this, you'll have to be running as a user
39
39
  # with valid Puppet certificates. Alternatively, you can use your local file bucket
40
40
  # by specifying +--local+.
41
41
  #
42
42
  # = Example
43
43
  #
44
- # $ pbucket backup /etc/passwd
44
+ # $ filebucket backup /etc/passwd
45
45
  # /etc/passwd: 429b225650b912a2ee067b0a4cf1e949
46
- # $ pbucket restore /tmp/passwd 429b225650b912a2ee067b0a4cf1e949
46
+ # $ filebucket restore /tmp/passwd 429b225650b912a2ee067b0a4cf1e949
47
47
  # $
48
48
  #
49
49
  # = Options
@@ -83,7 +83,7 @@
83
83
  #
84
84
  # = Example
85
85
  #
86
- # pbucket -b /tmp/filebucket /my/file
86
+ # filebucket -b /tmp/filebucket /my/file
87
87
  #
88
88
  # = Author
89
89
  #
@@ -209,4 +209,4 @@ else
209
209
  raise "Invalid mode %s" % mode
210
210
  end
211
211
 
212
- # $Id: filebucket 2464 2007-05-06 05:42:53Z luke $
212
+ # $Id: filebucket 2704 2007-07-18 16:41:15Z luke $
@@ -195,8 +195,18 @@ when :clean
195
195
  $stderr.puts "You must specify one or more hosts to clean"
196
196
  exit(24)
197
197
  end
198
+ cleaned = false
198
199
  hosts.each do |host|
200
+ cert = ca.getclientcert(host)[0]
201
+ if cert.nil?
202
+ $stderr.puts "Could not find client certificate for %s" % host
203
+ next
204
+ end
199
205
  ca.clean(host)
206
+ cleaned = true
207
+ end
208
+ unless cleaned
209
+ exit(27)
200
210
  end
201
211
  when :sign
202
212
  unless to_sign.length > 0 or all
@@ -276,4 +286,4 @@ else
276
286
  exit(42)
277
287
  end
278
288
 
279
- # $Id: puppetca 2464 2007-05-06 05:42:53Z luke $
289
+ # $Id: puppetca 2702 2007-07-17 14:00:29Z luke $
@@ -242,21 +242,22 @@ if fs.include?(:Config)
242
242
  handlers[:FileServer] = fs
243
243
  end
244
244
 
245
+ webserver = server = nil
245
246
  begin
246
247
  case Puppet[:servertype]
247
248
  when "webrick"
248
249
  # use the default, um, everything
249
250
  require 'puppet/network/server/webrick'
250
- server = Puppet::Network::Server::WEBrick.new(:Handlers => handlers)
251
+ webserver = server = Puppet::Network::Server::WEBrick.new(:Handlers => handlers)
251
252
  when "mongrel":
252
253
  require 'puppet/network/server/mongrel'
253
- handler = Puppet::Network::Server::Mongrel.new(handlers)
254
+ server = Puppet::Network::Server::Mongrel.new(handlers)
254
255
  addr = Puppet[:bindaddress]
255
256
  if addr == ""
256
257
  addr = "127.0.0.1"
257
258
  end
258
- server = Mongrel::HttpServer.new(addr, Puppet[:masterport])
259
- server.register("/", handler)
259
+ webserver = Mongrel::HttpServer.new(addr, Puppet[:masterport])
260
+ webserver.register("/", server)
260
261
  else
261
262
  Puppet.err "Invalid server type %s" % Puppet[:servertype]
262
263
  exit(45)
@@ -296,7 +297,7 @@ case Puppet[:servertype]
296
297
  when "webrick"
297
298
  Puppet.start
298
299
  when "mongrel":
299
- server.run.join
300
+ webserver.run.join
300
301
  end
301
302
 
302
- # $Id: puppetmasterd 2594 2007-06-15 23:11:43Z luke $
303
+ # $Id: puppetmasterd 2659 2007-07-08 23:02:06Z luke $
@@ -80,6 +80,7 @@ case "$1" in
80
80
  ;;
81
81
  status)
82
82
  status $puppetd
83
+ RETVAL=$?
83
84
  ;;
84
85
  once)
85
86
  shift
@@ -1,4 +1,4 @@
1
- [puppet]
1
+ [main]
2
2
  # Where Puppet stores dynamic and growing data.
3
3
  # The default value is '/var/puppet'.
4
4
  vardir = /var/lib/puppet
@@ -7,7 +7,7 @@
7
7
 
8
8
  Summary: A network tool for managing many disparate systems
9
9
  Name: puppet
10
- Version: 0.23.0
10
+ Version: 0.23.1
11
11
  Release: 1%{?dist}
12
12
  License: GPL
13
13
  Group: System Environment/Base
@@ -43,6 +43,8 @@ The server can also function as a certificate authority and file server.
43
43
 
44
44
  %prep
45
45
  %setup -q
46
+ cp -p conf/redhat/puppetd.conf conf/redhat/puppet.conf
47
+ sed -i -e 's/^\[puppet\]$/[main]/' conf/redhat/puppet.conf
46
48
 
47
49
  %build
48
50
  for f in bin/* ; do
@@ -50,32 +52,33 @@ for f in bin/* ; do
50
52
  done
51
53
 
52
54
  %install
53
- %{__rm} -rf %{buildroot}
54
- %{__install} -d -m0755 %{buildroot}%{_sbindir}
55
- %{__install} -d -m0755 %{buildroot}%{_bindir}
56
- %{__install} -d -m0755 %{buildroot}%{ruby_sitelibdir}
57
- %{__install} -d -m0755 %{buildroot}%{_sysconfdir}/puppet/manifests
58
- %{__install} -d -m0755 %{buildroot}%{_docdir}/%{name}-%{version}
59
- %{__install} -d -m0755 %{buildroot}%{_localstatedir}/lib/puppet
60
- %{__install} -d -m0755 %{buildroot}%{_localstatedir}/run/puppet
61
- %{__install} -d -m0755 %{buildroot}%{_localstatedir}/log/puppet
62
- %{__install} -Dp -m0755 %{pbuild}/bin/* %{buildroot}%{_sbindir}
63
- %{__mv} %{buildroot}%{_sbindir}/puppet %{buildroot}%{_bindir}/puppet
64
- %{__mv} %{buildroot}%{_sbindir}/ralsh %{buildroot}%{_bindir}/ralsh
65
- %{__mv} %{buildroot}%{_sbindir}/filebucket %{buildroot}%{_bindir}/filebucket
66
- %{__mv} %{buildroot}%{_sbindir}/puppetrun %{buildroot}%{_bindir}/puppetrun
67
- %{__install} -Dp -m0644 %{pbuild}/lib/puppet.rb %{buildroot}%{ruby_sitelibdir}/puppet.rb
68
- %{__cp} -a %{pbuild}/lib/puppet %{buildroot}%{ruby_sitelibdir}
69
- find %{buildroot}%{ruby_sitelibdir} -type f -perm +ugo+x -print0 | xargs -0 -r %{__chmod} a-x
70
- %{__install} -Dp -m0644 %{confdir}/client.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/puppet
71
- %{__install} -Dp -m0755 %{confdir}/client.init %{buildroot}%{_initrddir}/puppet
72
- %{__install} -Dp -m0644 %{confdir}/server.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/puppetmaster
73
- %{__install} -Dp -m0755 %{confdir}/server.init %{buildroot}%{_initrddir}/puppetmaster
74
- %{__install} -Dp -m0644 %{confdir}/fileserver.conf %{buildroot}%{_sysconfdir}/puppet/fileserver.conf
75
- %{__install} -Dp -m0644 %{confdir}/puppetd.conf %{buildroot}%{_sysconfdir}/puppet/puppetd.conf
76
- %{__ln_s} puppetd.conf %{buildroot}%{_sysconfdir}/puppet/puppetmasterd.conf
77
- %{__ln_s} puppetd.conf %{buildroot}%{_sysconfdir}/puppet/puppetca.conf
78
- %{__install} -Dp -m0644 %{confdir}/logrotate %{buildroot}%{_sysconfdir}/logrotate.d/puppet
55
+ rm -rf %{buildroot}
56
+ install -d -m0755 %{buildroot}%{_sbindir}
57
+ install -d -m0755 %{buildroot}%{_bindir}
58
+ install -d -m0755 %{buildroot}%{ruby_sitelibdir}
59
+ install -d -m0755 %{buildroot}%{_sysconfdir}/puppet/manifests
60
+ install -d -m0755 %{buildroot}%{_docdir}/%{name}-%{version}
61
+ install -d -m0755 %{buildroot}%{_localstatedir}/lib/puppet
62
+ install -d -m0755 %{buildroot}%{_localstatedir}/run/puppet
63
+ install -d -m0755 %{buildroot}%{_localstatedir}/log/puppet
64
+ install -Dp -m0755 %{pbuild}/bin/* %{buildroot}%{_sbindir}
65
+ mv %{buildroot}%{_sbindir}/puppet %{buildroot}%{_bindir}/puppet
66
+ mv %{buildroot}%{_sbindir}/ralsh %{buildroot}%{_bindir}/ralsh
67
+ mv %{buildroot}%{_sbindir}/filebucket %{buildroot}%{_bindir}/filebucket
68
+ mv %{buildroot}%{_sbindir}/puppetrun %{buildroot}%{_bindir}/puppetrun
69
+ install -Dp -m0644 %{pbuild}/lib/puppet.rb %{buildroot}%{ruby_sitelibdir}/puppet.rb
70
+ cp -a %{pbuild}/lib/puppet %{buildroot}%{ruby_sitelibdir}
71
+ find %{buildroot}%{ruby_sitelibdir} -type f -perm +ugo+x -print0 | xargs -0 -r chmod a-x
72
+ install -Dp -m0644 %{confdir}/client.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/puppet
73
+ install -Dp -m0755 %{confdir}/client.init %{buildroot}%{_initrddir}/puppet
74
+ install -Dp -m0644 %{confdir}/server.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/puppetmaster
75
+ install -Dp -m0755 %{confdir}/server.init %{buildroot}%{_initrddir}/puppetmaster
76
+ install -Dp -m0644 %{confdir}/fileserver.conf %{buildroot}%{_sysconfdir}/puppet/fileserver.conf
77
+ install -Dp -m0644 %{confdir}/puppet.conf %{buildroot}%{_sysconfdir}/puppet/puppet.conf
78
+ ln -s puppetd.conf %{buildroot}%{_sysconfdir}/puppet/puppetmasterd.conf
79
+ ln -s puppetd.conf %{buildroot}%{_sysconfdir}/puppet/puppetca.conf
80
+ install -Dp -m0644 %{confdir}/puppetd.conf %{buildroot}%{_sysconfdir}/puppet/puppetd.conf
81
+ install -Dp -m0644 %{confdir}/logrotate %{buildroot}%{_sysconfdir}/logrotate.d/puppet
79
82
 
80
83
  %files
81
84
  %defattr(-, root, root, 0755)
@@ -87,8 +90,9 @@ find %{buildroot}%{ruby_sitelibdir} -type f -perm +ugo+x -print0 | xargs -0 -r %
87
90
  %{_initrddir}/puppet
88
91
  %dir %{_sysconfdir}/puppet
89
92
  %config(noreplace) %{_sysconfdir}/sysconfig/puppet
90
- %config(noreplace) %{_sysconfdir}/puppet/puppetd.conf
91
- %doc CHANGELOG COPYING LICENSE README TODO examples
93
+ %config(noreplace) %{_sysconfdir}/puppet/puppet.conf
94
+ %ghost %config(noreplace,missingok) %{_sysconfdir}/puppet/puppetd.conf
95
+ %doc CHANGELOG COPYING LICENSE README examples
92
96
  %exclude %{_sbindir}/puppetdoc
93
97
  %config(noreplace) %{_sysconfdir}/logrotate.d/puppet
94
98
  # These need to be owned by puppet so the server can
@@ -102,8 +106,11 @@ find %{buildroot}%{ruby_sitelibdir} -type f -perm +ugo+x -print0 | xargs -0 -r %
102
106
  %{_sbindir}/puppetmasterd
103
107
  %{_bindir}/puppetrun
104
108
  %{_initrddir}/puppetmaster
105
- %config(noreplace) %{_sysconfdir}/puppet/*
109
+ %config(noreplace) %{_sysconfdir}/puppet/fileserver.conf
110
+ %dir %{_sysconfdir}/puppet/manifests
106
111
  %config(noreplace) %{_sysconfdir}/sysconfig/puppetmaster
112
+ %ghost %config(noreplace,missingok) %{_sysconfdir}/puppet/puppetca.conf
113
+ %ghost %config(noreplace,missingok) %{_sysconfdir}/puppet/puppetmasterd.conf
107
114
  %{_sbindir}/puppetca
108
115
 
109
116
  %pre
@@ -138,9 +145,14 @@ if [ "$1" -ge 1 ]; then
138
145
  fi
139
146
 
140
147
  %clean
141
- %{__rm} -rf %{buildroot}
148
+ rm -rf %{buildroot}
142
149
 
143
150
  %changelog
151
+ * Wed Jun 20 2007 David Lutterkort <dlutter@redhat.com> - 0.23.0-1
152
+ - Install one puppet.conf instead of old config files, keep old configs
153
+ around to ease update
154
+ - Use plain shell commands in install instead of macros
155
+
144
156
  * Wed May 2 2007 David Lutterkort <dlutter@redhat.com> - 0.22.4-1
145
157
  - New version
146
158
 
@@ -78,6 +78,7 @@ case "$1" in
78
78
  ;;
79
79
  status)
80
80
  status $PUPPETMASTER
81
+ RETVAL=$?
81
82
  ;;
82
83
  *)
83
84
  echo $"Usage: $0 {start|stop|status|restart|reload|force-reload|condrestart}"
@@ -25,7 +25,7 @@ require 'puppet/util/suidmanager'
25
25
  # it's also a place to find top-level commands like 'debug'
26
26
 
27
27
  module Puppet
28
- PUPPETVERSION = '0.23.0'
28
+ PUPPETVERSION = '0.23.1'
29
29
 
30
30
  def Puppet.version
31
31
  return PUPPETVERSION
@@ -421,11 +421,11 @@ module Puppet
421
421
  end
422
422
 
423
423
  require 'puppet/type'
424
- require 'puppet/modules'
424
+ require 'puppet/module'
425
425
  require 'puppet/util/storage'
426
426
  require 'puppet/parser/interpreter'
427
427
  if Puppet[:storeconfigs]
428
428
  require 'puppet/rails'
429
429
  end
430
430
 
431
- # $Id: puppet.rb 2631 2007-06-19 23:12:23Z luke $
431
+ # $Id: puppet.rb 2724 2007-07-20 19:23:33Z luke $
@@ -339,6 +339,11 @@ module Puppet
339
339
  :mode => 0640,
340
340
  :desc => "Where the puppetd web server logs."
341
341
  },
342
+ :http_proxy_host => ["none",
343
+ "The HTTP proxy host to use for outgoing connections. Note: You
344
+ may need to use a FQDN for the server hostname when using a proxy."],
345
+ :http_proxy_port => [3128,
346
+ "The HTTP proxy port to use for outgoing connections"],
342
347
  :server => ["puppet",
343
348
  "The server to which server puppetd should connect"],
344
349
  :ignoreschedules => [false,
@@ -431,8 +436,10 @@ module Puppet
431
436
  self.setdefaults(:main,
432
437
  :pluginpath => ["$vardir/plugins",
433
438
  "Where Puppet should look for plugins. Multiple directories should
434
- be colon-separated, like normal PATH variables."],
435
- :plugindest => ["$vardir/plugins",
439
+ be colon-separated, like normal PATH variables. As of 0.23.1, this
440
+ option is deprecated; download your custom libraries to the $libdir
441
+ instead."],
442
+ :plugindest => ["$libdir",
436
443
  "Where Puppet should store plugins that it pulls down from the central
437
444
  server."],
438
445
  :pluginsource => ["puppet://$server/plugins",
@@ -506,7 +513,10 @@ module Puppet
506
513
  :owner => "$user",
507
514
  :group => "$group",
508
515
  :desc => "Where Rails-specific logs are sent"
509
- }
516
+ },
517
+ :rails_loglevel => ["info", "The log level for Rails connections. The value must be
518
+ a valid log level within Rails. Production environments normally use ``info``
519
+ and other environments normally use ``debug``."]
510
520
  )
511
521
 
512
522
  setdefaults(:graphing,
@@ -550,7 +560,8 @@ module Puppet
550
560
 
551
561
  setdefaults(:ldap,
552
562
  :ldapnodes => [false,
553
- "Whether to search for node configurations in LDAP."],
563
+ "Whether to search for node configurations in LDAP. See
564
+ `LdapNodes`:trac: for more information."],
554
565
  :ldapssl => [false,
555
566
  "Whether SSL should be used when searching for nodes.
556
567
  Defaults to false because SSL usually requires certificates
@@ -623,4 +634,4 @@ module Puppet
623
634
  )
624
635
  end
625
636
 
626
- # $Id: configuration.rb 2587 2007-06-15 02:40:20Z luke $
637
+ # $Id: configuration.rb 2669 2007-07-10 04:17:07Z luke $
@@ -236,7 +236,6 @@ class Puppet::Type
236
236
  # @parameters array, and does some basic checking on it.
237
237
  def self.newparam(name, options = {}, &block)
238
238
  options[:attributes] ||= {}
239
- options[:attributes][:element] = self
240
239
  param = genclass(name,
241
240
  :parent => options[:parent] || Puppet::Parameter,
242
241
  :attributes => options[:attributes],
@@ -296,13 +295,16 @@ class Puppet::Type
296
295
  [self.name, name]
297
296
  end
298
297
 
298
+ if parent = options[:parent]
299
+ options.delete(:parent)
300
+ else
301
+ parent = Puppet::Property
302
+ end
303
+
299
304
  # We have to create our own, new block here because we want to define
300
305
  # an initial :retrieve method, if told to, and then eval the passed
301
306
  # block if available.
302
- prop = genclass(name,
303
- :parent => options[:parent] || Puppet::Property,
304
- :hash => @validproperties
305
- ) do
307
+ prop = genclass(name, :parent => parent, :hash => @validproperties, :attributes => options) do
306
308
  # If they've passed a retrieve method, then override the retrieve
307
309
  # method on the class.
308
310
  if options[:retrieve]
@@ -323,15 +325,6 @@ class Puppet::Type
323
325
  @properties << prop
324
326
  end
325
327
 
326
- if options[:event]
327
- prop.event = options[:event]
328
- end
329
-
330
- # Grr.
331
- if options[:required_features]
332
- prop.required_features = options[:required_features]
333
- end
334
-
335
328
  # define_method(name) do
336
329
  # @parameters[name].should
337
330
  # end
@@ -485,7 +478,7 @@ class Puppet::Type
485
478
  if obj = @parameters[name]
486
479
  # We throw a failure here, because this method is too
487
480
  # ambiguous when used with properties.
488
- if obj.is_a?(Puppet::Type::Property)
481
+ if obj.is_a?(Puppet::Property)
489
482
  fail "[] called on a property"
490
483
  else
491
484
  return obj.value
@@ -544,7 +537,7 @@ class Puppet::Type
544
537
  # retrieve the 'should' value for a specified property
545
538
  def should(name)
546
539
  name = attr_alias(name)
547
- if prop = @parameters[name] and prop.is_a?(Puppet::Type::Property)
540
+ if prop = @parameters[name] and prop.is_a?(Puppet::Property)
548
541
  return prop.should
549
542
  else
550
543
  return nil
@@ -608,7 +601,7 @@ class Puppet::Type
608
601
  # return an actual type by name; to return the value, use 'inst[name]'
609
602
  # FIXME this method should go away
610
603
  def property(name)
611
- if obj = @parameters[symbolize(name)] and obj.is_a?(Puppet::Type::Property)
604
+ if obj = @parameters[symbolize(name)] and obj.is_a?(Puppet::Property)
612
605
  return obj
613
606
  else
614
607
  return nil
@@ -683,7 +676,7 @@ class Puppet::Type
683
676
  }.find_all { |p|
684
677
  ! p.nil?
685
678
  }.each do |prop|
686
- unless prop.is_a?(Puppet::Type::Property)
679
+ unless prop.is_a?(Puppet::Property)
687
680
  raise Puppet::DevError, "got a non-property %s(%s)" %
688
681
  [prop.class, prop.class.name]
689
682
  end
@@ -693,4 +686,4 @@ class Puppet::Type
693
686
  end
694
687
  end
695
688
 
696
- # $Id: attributes.rb 2513 2007-05-14 17:27:56Z luke $
689
+ # $Id: attributes.rb 2676 2007-07-10 23:24:34Z luke $