Skip to content

ilons/newrelic_varnish_plugin

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

54 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

New Relic Varnish Extension

This is a fork of the original which no longer seems to be maintained

This runs on the Varnish server and reports the values from varnishstat back into New Relic.

Tested with Varnish version 3.

Instructions for running the Varnish extension agent

  1. Download (or clone) and uncompress the latest release, currently v0.2: RELEASE="v0.2" && wget "https://github.com/ilons/newrelic_varnish_plugin/archive/${RELEASE}.tar.gz" -O - | tar -zxvz && cd "newrelic_varnish_plugin-${RELEASE}"
  2. Install required Ruby gems (json, newrelic_plugin, bundler): bundle install
  3. Copy the config config/template_newrelic_plugin.yml to the appropriate place, for example /etc/newrelic/newrelic_varnish_plugin.yml cp config/template_newrelic_plugin.yml /etc/newrelic/newrelic_varnish_plugin.yml
  4. Edit the configuration file and fill in your New Relic license key (and any other desired options)
  5. Copy the executable newrelic_varnish_plugin to an appropriate place, e.g. /usr/local/bin/newrelic_varnish_plugin
  6. Optionally, Install daemon: cp config/newrelic_varnish_plugin_daemon.sh /etc/init.d/newrelic-varnish.sh && chmod +x /etc/init.d/newrelic-varnish. If so, update the values of DAEMON and CONFIG to the locations you used in step 5 and step 3 respectively.
  7. Execute plugin agent (use -h for usage hints) /usr/local/bin/newrelic_varnish_plugin -c /etc/newrelic/newrelic_varnish.yml -p /var/run/newrelic_varnish.pid && service newrelic-varnish start
  8. Go back to the Extensions list and after a brief period you will see an entry for your extension

Data should now get reported to your New Relic account

Testing / Development

To build install the plugin in an isolated environment:

  1. Install docker
  2. docker build .
  3. docker run --rm -it <build image id>

About

Integration plugin between Varnish and New Relic

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 77.6%
  • Shell 22.4%