David Golden wrote:
On Thu, Feb 4, 2010 at 9:25 AM, Barbie <bar...@missbarbell.co.uk> wrote:
It might be worth using a different email address for each VM. Currently
I have 'apo...@cpan.org' blacklisted. I'll lift that ban now that you've
stopped the smokers and can investigate the problem. However, if it
happens again, being able to blacklist based on an email address (or a
Metabase userid in the future), means we can reduce the impact of a
specific runaway smoker, rather than them all.
That's an interesting point. What would be some good ways to uniquely
identify particular smokers in the future?
It would be convenient to get that into the CT2.0 plan *now* before we go live.
-- David
The email idea is great, but I am constrainted by my email server and
don't want to screw it up by adding more addresses. What I did in
Test::Reporter::POEGateway was to add a header identifying my smoker. It
requires work on the end-user but I believe the same concept could be
applied to CT2.0?
http://search.cpan.org/~apocal/Test-Reporter-POEGateway-0.03/lib/Test/Reporter/POEGateway/Mailer.pm#host_aliases
You can see it in action here ( and pretty much all of my reports,
except the oldest ones where I didn't have this idea hah ):
http://www.nntp.perl.org/group/perl.cpan.testers/2010/01/msg6687441.html
Here's a little explanation of the idea, so you guys can wrap your head
around it and see if it can be applied to CT2.0...
Each smoker runs in a VM, assigned a dedicated IP to each. To reduce
configuration of the email client ( I hate hate hate email software! )
and to escape my ISP's brain-dead restrictions on email, I have to use
the HTTPGateway trick to send reports. What I do is run postfix on a
server hosted in the cloud, and use a single VM on my machine to
"collate" reports and submit them. At first, HTTPGateway did the trick
but I needed to add extra features, hence my starting the
Test::Reporter::POEGateway fork. Then I realized that each smoker
submits reports to a central POEGateway, which submits them to my
postfix server, and finally it hits the perl email servers. At first I
tried to do my modifications "locally" but it would be too much work to
dig into the guts of Test::Reporter to add the uname of each smoker.
In the end I went with the easiest route, make the POEGateway do the
modifications. What I do is supply a hash of IP => "identifier" to the
emailer. When the emailer sends the report, it checks to see if the
sender IP matches against an entry in the hash, and adds the CPAN_SMOKER
env var. Yes, I'm awful but my hackish regex code to do that works for
CPANPLUS::YACSmoke, and I haven't tested it against CPAN/CPAN::* modules!
Blabbering aside, the gist is that you add an unique env var that is
easily parsed which gives you the smoker's identification. It can be
just an IP address, or the uname of the box, or a description, or...
Offtopic, I hope I didn't make a bad choice by picking "CPAN_SMOKER" heh!
Thinking about CT2.0 and the metabase, I assume the simplest way
would be to add some extra data to the report. It could leak "sensitive"
information so I would recommend they be optional and turned on only if
the end-user configured it in CPAN/CPANPLUS. I don't grok the entire
Metabase concept but I think it can be added to Metabase::User::Profile?
Maybe a GUID for a machine, so you can easily search/ban/manage reports
per smoker?