ongoing puppet dashboard frustration

53 views
Skip to first unread message

Fine, Thomas

unread,
Jun 2, 2014, 5:43:03 PM6/2/14
to puppet...@googlegroups.com
Hi,

My problem is that the CSS formatting in puppet dashboard does not show up under apache, but works fine under webrick.  This SOUNDS exactly like some old bugs (9676, 9767), but I've applied all the recommended fixes to no avail, and at an rate the symptoms are only the same on the surface.

My apache/passenger setup correctly generates all.css with the correct permissions.  It generates the identical file that the webrick server generates, and with the same file permissions and ownership.  When I explicitly download this file, apache correctly serves the right all.css file.

BUT it still doesn't work!  I get an unformatted web page.  My only guess at this point is that some sort of race condition occurs between the creation and serving of the file, and the webserver is correctly serving an empty file, which is then filled in with data several microseconds later.  And when I say "empty", I mean a 66093 byte file with nothing but nulls in it, because the web logs always indicate that the correct file size is being served.  But at the same time Safari's web inspector shows that all.css is totally empty.  (Note that firefox and chrome show the same problem so it's not browser-specific).

I've googled around for ruby/rails/rake/passenger race conditions with apache and haven't found anything.

The insane part here is that (as far as I can tell) this dynamically generated file never ever ever actually needs to change unless I reconfigure or re-install puppet-dashboard.  So alternatively if you can tell me how to just serve this as a plain file not generated by passenger, that'd make me totally happy right now.

Thanks,

       tom

Felix Frank

unread,
Jun 3, 2014, 5:57:46 AM6/3/14
to puppet...@googlegroups.com
On 06/02/2014 11:42 PM, Fine, Thomas wrote:
> The insane part here is that (as far as I can tell) this dynamically
> generated file never ever ever actually needs to change unless I
> reconfigure or re-install puppet-dashboard. So alternatively if you can
> tell me how to just serve this as a plain file not generated by
> passenger, that'd make me totally happy right now.

Did someone say "silly workaround"? :)

How about a caching (nginx) proxy in front of Apache that serves the CSS
for you, while passing all other requests through to Apache?

Fine, Thomas

unread,
Jun 3, 2014, 3:38:26 PM6/3/14
to puppet...@googlegroups.com
SOLVED.

My Apache installation was being crippled by an incomplete mime.types that had no entry for css files.  They were being served as text/plain, and hence were being ignored by the browsers.

This is the most time I have ever wasted on a trivially stupid bug.  I didn't find the problem until I resorted to studying tcpdumps of the browser traffic to see the css file being transmitted over the wire.

         tom




--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/538D9C0D.7030206%40alumni.tu-berlin.de.
For more options, visit https://groups.google.com/d/optout.

Ken Barber

unread,
Jun 3, 2014, 3:50:01 PM6/3/14
to Puppet Users
> I didn't find the problem until I resorted to studying tcpdumps of the browser
> traffic to see the css file being transmitted over the wire.

FYI the developer tools in Chrome (or equivalents in firefox etc.)
also help tracking these kinds of issues, probably a little faster
then analyzing tcpdumps.

ken.

Fine, Thomas

unread,
Jun 3, 2014, 3:58:46 PM6/3/14
to puppet...@googlegroups.com
I was using the development tools in Safari.  I suspect it would've reported an error, had I actually looked at the error console.  Instead I was looking everywhere but there.  Sometimes when you miss the obvious, it becomes increasingly more difficult to find it again.

    tom



--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages