Skip to content

Instantly share code, notes, and snippets.

@danielpetisme
Created July 27, 2017 22:04
Show Gist options
  • Save danielpetisme/638af265f43837d93942998563ffc853 to your computer and use it in GitHub Desktop.
Save danielpetisme/638af265f43837d93942998563ffc853 to your computer and use it in GitHub Desktop.
Rancher + Docker + Elastic Metricbeat
version: '2'
services:
<hostname>-metricbeat:
image: docker.elastic.co/beats/metricbeat:5.5.1
environment:
ES_HOST: <MY_HOST>:<MY_PORT>
network_mode: host
volumes:
- /proc:/hostfs/proc:ro
- /sys/fs/cgroup:/hostfs/sys/fs/cgroup:ro
- /:/hostfs:ro
command:
- metricbeat
- -e
- -system.hostfs=/hostfs
- -E
- output.elasticsearch.hosts=$${ES_HOST}
labels:
io.rancher.container.pull_image: always
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment