meteorhacks/docker-librato

Name: docker-librato

Owner: meteorhacks

Description: Forward all stats from all running docker containers to Librato

Created: 2015-03-26 10:24:55.0

Updated: 2017-05-17 18:41:08.0

Pushed: 2015-03-26 11:22:36.0

Homepage:

Size: 324

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

docker-librato

Forward all your stats to Librato Metrics, like a breeze.

Usage as a Container

The simplest way to forward all your container's log to Librato Metrics is to run this repository as a container, with:

er run \
 /var/run/docker.sock:/var/run/docker.sock \
 LIBRATO_EMAIL="" \
 LIBRATO_TOKEN="" \
teorhacks/docker-librato

You can also use two different tokens for logging and stats:

er run \
 /var/run/docker.sock:/var/run/docker.sock \
 LIBRATO_EMAIL="" \
 LIBRATO_TOKEN="" \
teorhacks/docker-librato
Running container in a restricted environment.

Some environments(such as Google Compute Engine) does not allow to access the docker socket without special privileges. You will get EACCES(Error: read EACCES) error if you try to run the container. To run the container in such environments add –privileged to the docker run command.

Example:

er run --privileged \
 /var/run/docker.sock:/var/run/docker.sock \
 LIBRATO_EMAIL="" \
 LIBRATO_TOKEN="" \
teorhacks/docker-librato
Building a docker repo from this repository

First clone this repository, then:

er build -t librato .
er run \
 /var/run/docker.sock:/var/run/docker.sock \
brato
How it works

This module wraps four Docker APIs:

This module wraps docker-loghose and docker-stats to fetch the logs and the stats as a never ending stream of data.

All the originating requests are wrapped in a never-ending-stream.

Credits

This app is based on nearform/docker-logentries.

License

MIT


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.