What with the impending release and a now fixed bug nagging me, I''m testing puppet [2556] from subversion. There have been changes in packages, I used to have Package { provider => "aptitude", } in my default.pp, but that doesn''t work anymore, and changing package to type or removing the declaration doesn''t help. How do package providers work now? Here are the error messages: # with provider => aptitude err: Could not create openssh-server: Invalid parameter provider err: Invalid parameter provider # with type => aptitude warning: /Package[openssh-server]/type: ''type'' is deprecated; use ''provider'' instead err: Could not create openssh-server: Parameter type failed: Munging failed for value ["aptitude"] in class type: Invalid parameter provider err: Parameter type failed: Munging failed for value ["aptitude"] in class type: Invalid parameter provider # with nothing err: Could not create openssh-server: No package type set err: No package type set Should I wait? What changes should I make?
On 11 June , 2007, at 05:46, Gabriel de Perthuis wrote:> Package { > provider => "aptitude", > } > in my default.pp, but that doesn''t work anymore, and changing > package to > type or removing the declaration doesn''t help. > > How do package providers work now?I would probably use something like this, if I correctly understand your aim: package {"openssh-server: provider => "aptitude", ensure => latest }
* Benjamin C. Kite:> On 11 June , 2007, at 05:46, Gabriel de Perthuis wrote: > >> Package { >> provider => "aptitude", >> } >> in my default.pp, but that doesn''t work anymore, and changing >> package to >> type or removing the declaration doesn''t help. >> >> How do package providers work now? > > I would probably use something like this, if I correctly understand > your aim: > > package {"openssh-server: > provider => "aptitude", > ensure => latest > }"provider" seems to be broken right now, because this fails too. Invalid parameter ''"provider"'' for type ''package'' at /etc/puppet/manifests/site.pp:101 Maybe I''ll go looking for another snapshot, I really must fill the gap...
On Jun 11, 2007, at 4:46 AM, Gabriel de Perthuis wrote:> What with the impending release and a now fixed bug nagging me, > I''m testing puppet [2556] from subversion. > There have been changes in packages, I used to have > Package { > provider => "aptitude", > } > in my default.pp, but that doesn''t work anymore, and changing > package to > type or removing the declaration doesn''t help. > > How do package providers work now? > > Here are the error messages: > # with provider => aptitude > err: Could not create openssh-server: Invalid parameter provider > err: Invalid parameter provider > > # with type => aptitude > warning: /Package[openssh-server]/type: ''type'' is deprecated; use > ''provider'' instead > err: Could not create openssh-server: Parameter type failed: Munging > failed for value ["aptitude"] in class type: Invalid parameter > provider > err: Parameter type failed: Munging failed for value ["aptitude"] in > class type: Invalid parameter provider > > > # with nothing > err: Could not create openssh-server: No package type set > err: No package type set > > Should I wait? What changes should I make?Huh, I don''t get this behaviour at all. The following script works fine for me on Debian: Package { provider => aptitude } package { zinf-extras: ensure => installed; xterm: ensure => installed; } It works whether I use apt or aptitude. Can you rerun with --trace and send the resulting stack trace? Also, can you make sure you''re setting RUBYLIB correctly, so that ruby is looking at the svn checkout, not the existing code? -- Kai''s Example Dilemma: A good analogy is like a diagonal frog. --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com
* Luke Kanies:> On Jun 11, 2007, at 4:46 AM, Gabriel de Perthuis wrote: > Huh, I don''t get this behaviour at all. The following script works > fine for me on Debian: > > Package { provider => aptitude } > package { > zinf-extras: ensure => installed; > xterm: ensure => installed; > } > > It works whether I use apt or aptitude. > > Can you rerun with --trace and send the resulting stack trace?sudo puppet --trace test.pp /usr/lib/ruby/1.8/puppet/type/package.rb:411:in `initialize'' /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `new'' /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `create'' /usr/lib/ruby/1.8/puppet/transportable.rb:72:in `to_type'' /usr/lib/ruby/1.8/puppet/transportable.rb:268:in `to_type'' /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' /usr/lib/ruby/1.8/puppet/transportable.rb:255:in `to_type'' /usr/lib/ruby/1.8/puppet/network/client/master.rb:227:in `getconfig'' /usr/bin/puppet:192 err: Could not create screen: No package type set err: No package type set /usr/lib/ruby/1.8/puppet/type/package.rb:411:in `initialize'' /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `new'' /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `create'' /usr/lib/ruby/1.8/puppet/transportable.rb:72:in `to_type'' /usr/lib/ruby/1.8/puppet/transportable.rb:268:in `to_type'' /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' /usr/lib/ruby/1.8/puppet/transportable.rb:255:in `to_type'' /usr/lib/ruby/1.8/puppet/network/client/master.rb:227:in `getconfig'' /usr/bin/puppet:192 err: Could not create bash: No package type set err: No package type set It''s on debian 4.0. Maybe it has to do with platform detection, to choose the default provider?> Also, can you make sure you''re setting RUBYLIB correctly, so that > ruby is looking at the svn checkout, not the existing code?I''ve built an updated debian package, I''m pretty sure it''s the right code because it makes a difference when I install one version or the other. I''ve just checked direct from svn with the small test you gave.
On Jun 11, 2007, at 3:00 PM, tobutaz at gmail wrote:> > sudo puppet --trace test.pp > /usr/lib/ruby/1.8/puppet/type/package.rb:411:in `initialize'' > /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `new'' > /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `create'' > /usr/lib/ruby/1.8/puppet/transportable.rb:72:in `to_type'' > /usr/lib/ruby/1.8/puppet/transportable.rb:268:in `to_type'' > /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' > /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' > /usr/lib/ruby/1.8/puppet/transportable.rb:255:in `to_type'' > /usr/lib/ruby/1.8/puppet/network/client/master.rb:227:in `getconfig'' > /usr/bin/puppet:192 > err: Could not create screen: No package type set > err: No package type set/me smacks self I figured out why it worked for me but not you -- I forgot to add a critical file to svn. Do an svn update and try it now; I bet it works. -- That was just a drill of the emergency y2k system. Had this been a real emergency, we would''ve also dumped a bucket of spiders on you and yelled out "civilization is collapsing!" --------------------------------------------------------------------- Luke Kanies | http://reductivelabs.com | http://madstop.com
* Luke Kanies:> On Jun 11, 2007, at 3:00 PM, tobutaz at gmail wrote: >> sudo puppet --trace test.pp >> /usr/lib/ruby/1.8/puppet/type/package.rb:411:in `initialize'' >> /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `new'' >> /usr/lib/ruby/1.8/puppet/metatype/instances.rb:163:in `create'' >> /usr/lib/ruby/1.8/puppet/transportable.rb:72:in `to_type'' >> /usr/lib/ruby/1.8/puppet/transportable.rb:268:in `to_type'' >> /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' >> /usr/lib/ruby/1.8/puppet/transportable.rb:130:in `each'' >> /usr/lib/ruby/1.8/puppet/transportable.rb:255:in `to_type'' >> /usr/lib/ruby/1.8/puppet/network/client/master.rb:227:in `getconfig'' >> /usr/bin/puppet:192 >> err: Could not create screen: No package type set >> err: No package type set > > /me smacks self > > I figured out why it worked for me but not you -- I forgot to add a > critical file to svn. > > Do an svn update and try it now; I bet it works.Like a charm. Thank you!