A web interface for viewing historical and current statistics per docker container (cpu, mem, net i/o, block i/o) - in a docker container.
 
 
 
 
Go to file
Sergio Oller 6e556afede
Prevent database is locked errors
Since there are only SELECT statements, the database can be opened as read-only preventing:

Error: SQLITE_BUSY: database is locked
    at Error (native)
2019-06-17 11:06:01 +02:00
html Fixed "hi is not a function" resulting from a google chart loader update to v44 (see https://groups.google.com/forum/#!topic/google-visualization-api/tdswEASPEKA) 2016-02-28 20:27:49 +01:00
img Added screenshots 2016-02-24 00:50:53 +01:00
.gitignore Initial commit 2016-02-22 22:45:52 +01:00
Dockerfile HTML frontend first version 2016-02-23 22:24:23 +01:00
README.md Updates to readme 2016-02-26 21:46:35 +01:00
httpd.js Prevent database is locked errors 2019-06-17 11:06:01 +02:00
stats.js Containers are identified by name now for handling container restarts 2016-02-26 21:27:44 +01:00
supervisord.conf HTML frontend first version 2016-02-23 22:24:23 +01:00

README.md

Docker Container Stats

A web interface for viewing historical and current statistics per docker container (cpu, mem, net i/o, block i/o) - in a docker container.

Pull and run daemonized:

docker pull weweave/docker-container-stats
docker run \
        -d \
        -p 8080:8080 \
        --volume=/var/lib/docker/:/var/lib/docker:ro \
        --volume=/var/run/docker.sock:/var/run/docker.sock:ro \
        --volume=/home/docker/storage/stats/db:/opt/docker-stats/db \
        --name stats \
        weweave/docker-container-stats

To view your stats, open a web browser and visit http://localhost:8080 (replace localhost with your docker host's hostname or ip address).

Mounting the volumes /var/lib/docker and /var/run/docker.sock (read-only) is required so that the docker container can retrieve the statistics for the containers.

Mounting the volume /opt/docker-stats/db is optional. You can use it if you want to persist the SQLite database.

We strongly recommend not making your stats available online. To password protect your statistics, you can use a frontend web server/proxy (Apache, nginx, ...).

Screenshots

All containers' memory usage

All containers' inbound network traffic

Selected container's latest statistics