I have been playing woth Phantomas and was really interested in being able to track the stats via statsd and Graphite. Beacause I have also been playing with vagrant I thought it would be useful to get this up and running on vagrant.
My intent was to set up a vagrant box to just do the monitoring, so it will just be a pre-configured box with statsd and Graphie with some basic settings. Theere were some older boxes available but they did not seem as straight forward as I wanted.
- Clone the repository
- cd into the statsd sirectory
- Run
vagrant up
- Point your brower to http://localhost:18080 - You should see the Grapite welcome screen
- Run phantomas with the appropriate settings (See below)
- On Graphite add data to the graph - the timings from the example below will be under Graphite stata.timings.google.home
phantomas --no-externals --url http://google.com --format statsd --statsd-host localhost --statsd-port 18125 --statsd-prefix "google.home."
You could optionally install phantomas on the virtual box but I prefer to manage this on my main system - I have soem basic auth unformation in mine for some testing that I am doing.
To run phantomas in debug mode, just prefix the command with DEBUG=*
DEBUG=* phantomas --no-externals --url http://google.com --format statsd --statsd-host localhost --statsd-port 18125 --statsd-prefix "google.home."
Thanks to This article on elao.com and Nam Nguyen's script