Bug #4345
pluginsync removes $libdir/puppet/reports/puppet_dashboard.rb
| Status: | Closed | Start date: | 07/23/2010 | |
|---|---|---|---|---|
| Priority: | High | Due date: | ||
| Assignee: | % Done: | 0% |
||
| Category: | - | |||
| Target version: | 1.1.0 | |||
| Keywords: | pluginsync, roadmapped | Affected URL: | ||
| Branch: | https://github.com/stereotype441/puppet-dashboard/tree/ticket/next/4345 | Affected Dashboard version: | ||
| Votes: | 0 |
Description
According to http://github.com/reductivelabs/puppet-dashboard/blob/master/README.markdown for puppet 0.25.x and earlier, the http://github.com/reductivelabs/puppet-dashboard/blob/master/lib/puppet/puppet_dashboard.rb file is to be installed in $libdir/puppet/reports/.
If you are running puppet on your puppetmaster, and you have pluginsync = true then it appears all items under $libdir/puppet are managed by pluginsync.
The result is that the puppet_dashboard.rb file is removed every time puppet runs on the puppetmaster.
My current solution is to install puppet_dashboard.rb as plugin itself. The problem with this, is that it cannot be templatized in a puppet recipe.
% rpm -qa | grep puppet puppet-server-0.25.4-1.el5 puppet-0.25.4-1.el5 puppet-dashboard-1.0.1-2
Related issues
History
Updated by Igal Koshevoy almost 2 years ago
- Status changed from Unreviewed to Accepted
- Assignee set to James Turnbull
- Priority changed from Normal to High
Jeremy: I really appreciate your detailed bug report.
James: What are your suggestions for resolving this?
Updated by James Turnbull almost 2 years ago
Argh. I don’t see this behaviour at all. I’m going to have to take a deeper look.
Updated by Rein Henrichs almost 2 years ago
As an aside, would it be useful to release a plugin for the puppet_dashboard.rb report processor to make installation easier for those still running Puppet 0.25.x?
Updated by Jeremy Hinegardner almost 2 years ago
Rein Henrichs wrote:
As an aside, would it be useful to release a plugin for the puppet_dashboard.rb report processor to make installation easier for those still running Puppet 0.25.x?
personall, I have no opinion on this. I wasn’t using puppet-dashboard yet. I just saw the new release and thought I would give it a whirl and make my life a tad bit easier.
Updated by Luke Kanies almost 2 years ago
I think a module makes sense for ease of installation, since I think this pluginsync conflict is essentially endemic – purging is enabled when pluginsync is running, so it will always purge this kind of thing.
$libdir should actually support more than one path, like most of these apps do (e.g., $PATH), but it doesn’t for some reason, so the only reasonable solution is to put it into a module or a separate Ruby search path which you add separately, unfortunately.
Updated by Igal Koshevoy almost 2 years ago
- Status changed from Accepted to Investigating
- Target version set to 61
Luke or James:
Can one of you please confirm what I think was said in the above discussion: 1. The current approach of asking people to install the library into $libdir is wrong because this directory is owned exclusively by pluginsync. 2. The desired approach is to ask people to install a module with a plugin, which would load it at the right time on the server, but also have the unfortunate side-effect of distributing the file to all the clients during the pluginsync.
Updated by Luke Kanies almost 2 years ago
Hmm. I think you are correct.
That is, yes – if pluginsync is enabled on the server, then pluginsync owns the destination $libdir, and it will purge anything it doesn’t get.
Additionally, if it’s in a place where pluginsync will find it, then all clients will get it.
The only other option I can think of in the short term is to install it in Ruby’s load path, rather than Puppet’s. In the long term, the right option, I think, is to support the libdir being multiple directories, so you could just add the Dashboard’s libdir to Puppet’s, or something similar.
Updated by Ian Ward Comfort almost 2 years ago
FWIW, my current hack around this problem (on 0.25.5) is as follows:
[main]
vardir = /var/lib/puppet
[puppetd]
pluginsync = true
libdir = $vardir/lib
[puppetmasterd]
libdir = $vardir/masterlib
reports = puppet_dashboard
And I install $vardir/masterlib/puppet/reports/puppet_dashboard.rb via some method besides pluginsync (manual, local RPM, File resource).
Updated by James Turnbull over 1 year ago
- Status changed from Investigating to Accepted
- Assignee deleted (
James Turnbull)
Updated by James Turnbull over 1 year ago
- Target version changed from 61 to 1.0.5
Updated by Nigel Kersten over 1 year ago
- Keywords changed from pluginsync to pluginsync, roadmapped
Updated by Paul Berry over 1 year ago
- Status changed from Accepted to Merged - Pending Release
- Branch set to https://github.com/stereotype441/puppet-dashboard/tree/ticket/next/4345
On discussion with Dan Bode, we determined that this is a consequence of a Puppet bug (#5244). Updated the README for Dashboard to include a workaround for it.
Pushed to next as commit:f6501018c529dea429bcfa10ce4de7ac2d4bfc4b
Updated by Dan Bode over 1 year ago
two comments on the README notes:
the fix is only suggested for puppet 0.25.x, it is also required for 2.6.x
the fix says only to use if ‘puppetd —configprint pluginsync’ is true. I would recommend it for all cases. With the current recommendation, if the pluginsync is enabled, then the file could be destroyed.
Updated by Matt Robinson over 1 year ago
- Assignee set to Dan Bode
Why is the fix required for 2.6.x?
It seems silly to tell the user to do the workaround to avoid a problem they might run into one day. If they run into this problem one day, chances are, they won’t have implemented the work around in the first place.
Updated by Jesse Wolfe over 1 year ago
- Status changed from Merged - Pending Release to Needs More Information
Updated by Jesse Wolfe over 1 year ago
This was merged into master in commit:308dcbbfc892ccbaf13b3be4d997c6cdcb6b44af as part of Iteration-2010-11-10, but I’m assigning it to Dan for clarification about his concerns.
Updated by Dan Bode over 1 year ago
an update for this ticket (although I still need to check the patch)
As far as I am concerned, this is fixed in 2.6.x with the http report handler.
Updated by Jacob Helwig about 1 year ago
- Status changed from Needs More Information to Closed
Dan seemed satisfied this was closed given his comment in update 17 Closing ticket. We can always re-open later if needed.
Updated by James Turnbull about 1 year ago
- Target version changed from 1.0.5 to 1.1.0