Issue #2719 has been updated by Peter Meier.

> The end result is that I had to run puppet twice, to have the package 
> "site-utility" installed again.
> 
> Or perhaps there's some way to setup a correct dependency so this wouldn't 
> happen, and I'm the bug?

if you don't specify the exact order of resources, the way they're applied is 
completely random.

what do you get if you do:
<pre>
  package{"site-test":
     ensure => absent
   }
   @package{"site-prod":
     ensure => present,
     ensure => $sitever,
     require  => [Exec["apt-update"], Package["site-test"]]
   }
   @package{"site-utility":
     ensure => present,
     ensure => $sitever,
     require  => Exec["apt-update"], Package['site-test']
   }
</pre>
----------------------------------------
Bug #2719: package handling bug
http://projects.reductivelabs.com/issues/2719

Author: Klavs Klavsen
Status: Unreviewed
Priority: Normal
Assigned to: 
Category: 
Target version: 
Affected version: 0.24.8
Keywords: 
Branch: 


I just found, that if remove a package, which has packages that depend on it 
(and are thusly removed when you remove the package) puppet doesn't notice, 
even though it is supposed to ensure the relevant packages are installed.

My case where I found it, envolves these rules:
 package{"site-test":
    ensure => absent
  }
  @package{"site-prod":
    ensure => present,
    ensure => $sitever,
    require  => [Exec["apt-update"], Package["site-test"]]
  }
  @package{"site-utility":
    ensure => present,
    ensure => $sitever,
  require  => Exec["apt-update"]
  }

(and then realize site-prod and site-utility somewhere).

I'm guessing that puppet checks for the existence of Package["site-utility"] 
before installing site-prod, and before removing "site-test" - and thus doesn't 
notice that the package system removes it when uninstalling "site-test".

The end result is that I had to run puppet twice, to have the package 
"site-utility" installed again.

Or perhaps there's some way to setup a correct dependency so this wouldn't 
happen, and I'm the bug?


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://reductivelabs.com/redmine/my/account

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Puppet Bugs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/puppet-bugs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to