All-in-one Docker with Grafana, InfluxDB, and cloudwatch-to-graphite for AWS/Beanstalk monitoring
Posted by Jakub Holý on May 7, 2015
I have derived the Docker container docker-grafana-influxdb-cloudwatch that bundles Grafana dashboards, InfluxDB for metrics storage, and runs cloudwatch-to-graphite as a cron job to fetch selected metrics from AWS CloudWatch and feed them into the InfluxDB using its Graphite input plugin. It is configured so that you can run it in AWS Elastic Beanstalk (the main problem being that only a single port can be exposed – I therefore use Nginx to expose the InfluxDB API needed by Grafana at :80/db/).
- It’s derived from kamon-io/docker-grafana-influxdb but based on phusion/baseimage rather than raw Ubuntu as this supports cron and presumably solves some deficiencies wrt. Docker
- InfluxDB API is exposed also at port 80 so that it can be easily run in Elastic BeanStalk
- It enables the Graphite InfluxDB plugin
- It runs cloudwatch-to-graphite’s leadbutt to fetch metrics from CloudWatch
- Grafana configuration fixed not to hardcode InfluxDB as locahost
I’ve created this to be able to run a monitoring dashboard on Elastic Beanstalk to get overview of our AWS infrastructure.
- CloudWatch only keeps metrics for the past 2 week, doesn’t provide customizable dashboards, and cannot be exposed without the need for authentication
- Beanstalk supports running docker containers – I just need to upload a .zip with the Dockerfile and files (it also supports multiple container setups but then I’d need to publish the images into a repository; the same holds for Amazon EC2 Container Service
- I haven’t managed yet to make the InfluxDB storage persistent (preferably stored on an EBS volume) though I’ve tried (ideas welcome!); a re-deployment results in loss of data
- You want to keep the number of metrics collected minimal as you have only 1M API calls free and it can get expensive for a large infrastructure
- This is likely not suitable for high load and large volumes of data
Sorry, the comment form is closed at this time.