Closed Bug 1184969 Opened 11 years ago Closed 10 years ago

Update apache configs to point perfherder subdomains to right file

Categories

(Tree Management :: Perfherder, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: wlach, Assigned: fubar)

References

Details

Thanks to bug 1184957 we now have perfherder.mozilla.org and perfherder.allizom.org subdomains. :fubar, could you update the apache configs so that hits to these domains will load perf.html instead of index.html?
would it make more sense to break this out into a separate apache vhost? we could skip mucking with rewrite rules and proxypass stuff, plus get separate logging for the domain. but I'm not sure how the two sites are intertwined...
(In reply to Kendall Libby [:fubar] from comment #1) > would it make more sense to break this out into a separate apache vhost? we > could skip mucking with rewrite rules and proxypass stuff, plus get separate > logging for the domain. but I'm not sure how the two sites are intertwined... I think that could make sense, it would be nice to be able to monitor traffic / requests against perfherder seperately from the rest of treeherder. Basically I see them as being the exact site, with one difference: treeherder -> / points to index.html perfherder -> / points to perf.html
hrm, with the proxypass and alias wrangling, doing a separate vhost leads to too much duplication, imo. if there isn't a need for separate logs, I'll just go with a simple (ha) redirect. it's setup on staging currently. take a look and make sure I haven't broken anything?
Flags: needinfo?(wlachance)
(In reply to Kendall Libby [:fubar] from comment #3) > hrm, with the proxypass and alias wrangling, doing a separate vhost leads to > too much duplication, imo. if there isn't a need for separate logs, I'll > just go with a simple (ha) redirect. > > it's setup on staging currently. take a look and make sure I haven't broken > anything? Seems to work ok as long as you're just doing perf stuff. If you try to switch to treeherder (via the chevron) everything breaks. I'm also not crazy about the redirect. Let me think about this a bit over the weekend and see if I can't come up with a proposal.
wfm. I think you have access to the web heads if you want to see what's currently in the apache config, if that helps.
Gave this some thought over the weekend. I think it's easiest if we mostly make perfherder.mozilla.org and treeherder.mozilla.org mostly do the same thing. Here's what I think makes sense: * Rename index.html -> jobs.html. Make index.html a symbolic link to it, for backwards compatibility. * Change links in UI from '/' to '/jobs.html' * Update apache configs to index on perf.html if accessing http://perfherder.mozilla.org. Continue directing to index.html/jobs.html if accessing http://treeherder.mozilla.org I'm not sure what the exact apache configuration required for this is, but I don't think it should be too crazy? It looks like mod_rewrite should do what we need here. http://httpd.apache.org/docs/current/mod/mod_rewrite.html Thoughts?
Flags: needinfo?(wlachance) → needinfo?(klibby)
I'm not sure if this will be able to work with Heroku. I'm also not sure we want to add jobs.html into the URL for Treeherder.
Would a better solution be to just put perferder on some static files hosting solution (eg maybe even a CDN) and just point the DNS at that?
(Sorry multiple messages) The other thing to bear in mind is that if Perfherder ever wants to use treeherder's profile/login functionality, this is going to be more annoying if it's on another subdomain.
(In reply to Ed Morley [:emorley] from comment #7) > I'm not sure if this will be able to work with Heroku. I'm also not sure we > want to add jobs.html into the URL for Treeherder. Oh definitely no, I wasn't proposing changing the defaults on treeherder in any way. '/' should still serve up the current index, no redirects or anything. (In reply to Ed Morley [:emorley] from comment #9) > (Sorry multiple messages) The other thing to bear in mind is that if > Perfherder ever wants to use treeherder's profile/login functionality, this > is going to be more annoying if it's on another subdomain. Hmm. This is turning into a rather large can of worms. I can actually see us wanting to do that in the near future when we create a performance sheriffing workflow. I don't want to spend a lot of cycles on this (or force anyone else to). Maybe we ought to just direct perfherder.mozilla.org -> treeherder.mozilla.org/perf.html for now. We can always revisit this later after Heroku is enabled and we've figured out what our needs are for auth/identity.
(In reply to William Lachance (:wlach) from comment #10) > Oh definitely no, I wasn't proposing changing the defaults on treeherder in > any way. Ah, I misunderstood :-) > Maybe we ought to just direct perfherder.mozilla.org -> > treeherder.mozilla.org/perf.html for now. We can always revisit this later > after Heroku is enabled and we've figured out what our needs are for > auth/identity. wfm :-)
(In reply to Ed Morley [:emorley] from comment #11) > (In reply to William Lachance (:wlach) from comment #10) > > Maybe we ought to just direct perfherder.mozilla.org -> > > treeherder.mozilla.org/perf.html for now. We can always revisit this later > > after Heroku is enabled and we've figured out what our needs are for > > auth/identity. > > wfm :-) Ok, let's just do that. Fubar, could you take care of this? I guess the easiest way is probably just to make perfherder.mozilla.org a "site" which redirects to treeherder.mozilla.org, but whatever works. [resetting NI to make it clear the old question is no longer operative]
Flags: needinfo?(klibby)
The SSL certs are sorted as of bug 1184957. And https://perfherder.allizom.org/ redirects to https://perfherder.allizom.org/perf.html fine. So the final part is adding the same redirect as is on stage, to prod. The prod apache config will need: ServerName perfherder.mozilla.org ... RewriteEngine On # Bug 1184969 - redir perfherder to /perf.html RewriteCond %{HTTP_HOST} ^perfherder\.mozilla\.org$ RewriteRule ^/$ /perf.html [R=301] Thanks :-)
I think this somehow got lost. We really do need the behaviour in comment 12 implemented, the current configuration tripped :jmaher up earlier today. To recap, this just means *any* requests to perfherder.mozilla.org should redirect to treeherder.mozilla.org/perf.html There is no (current) need for url rewriting, symbolic links, or other exotic behaviour discussed elsewhere in this bug. Please remove any rewriting or other cleverness. :fubar, could you take care of this before it trips someone else up again? It should just take a few minutes.
Flags: needinfo?(klibby)
This just needs the config in comment 13 in the prod apache config, which is a copy pasta of the stage configs. It's worth noting that when Treeherder migrates to Heroku we will want to move these redirects to the dummy generic cluster app that handles redirects.
Apologies; carried the staging config over to prod; please verify it's doing what you expect.
Flags: needinfo?(klibby)
This is better, but it should redirect to treeherder.mozilla.org/perf.html not perfherder.mozilla.org/perf.html
Flags: needinfo?(klibby)
Done! All good?
Flags: needinfo?(klibby)
Yes! Thanks so much. :)
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.