https://github.com/google/cadvisor
Analyzes resource usage and performance characteristics of running containers.
Vagrantfile
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.define "cadvisor"
config.vm.box = "yungsang/coreos-alpha"
config.vm.network :forwarded_port, guest: 2375, host: 2375
config.vm.network :forwarded_port, guest: 8080, host: 8080
config.vm.provision :docker do |d|
d.run "cadvisor",
image: "google/cadvisor",
args: "-v /var/run:/var/run:rw -v /sys/fs/cgroup/:/sys/fs/cgroup:ro -v /var/lib/docker/:/var/lib/docker:ro -p 8080:8080"
end
config.vm.network :forwarded_port, guest: 8081, host: 8081
config.vm.provision :docker do |d|
d.run "hello-world",
image: "yungsang/busybox",
args: "-p 8081:8080",
cmd: "nc -p 8080 -l -l -e echo hello world!"
end
end
$ vagrant up
$ open http://localhost:8080