Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Prometheus_Dojo.pdf

 Prometheus_Dojo.pdf

Nesse docker meetup de halloween fizemos um DOJO sobre prometheus e vimos como monitorar alguns containers! =)

Sebastian Webber

October 31, 2018
Tweet

More Decks by Sebastian Webber

Other Decks in Programming

Transcript

  1. Como rodar o prometheus? $ docker run \ -p 9090:9090

    \ -v $(pwd)/prometheus.yml:/etc/prometheus/prometheus.yml \ -d \ prom/prometheus
  2. Como rodar o grafana? $ docker run \ -d \

    --name=grafana \ -p 3000:3000 \ grafana/grafana
  3. version: '3.1' volumes: prometheus_data: {} grafana_data: {} services: prometheus: image:

    prom/prometheus volumes: - ./prometheus.yml:/etc/prometheus/prometheus.yml - prometheus_data:/prometheus ports: - 9090:9090 restart: always https://bit.ly/2qk0OU7
  4. Como rodar o cAdvisor? $ docker run \ --volume=/:/rootfs:ro \

    --volume=/var/run:/var/run:ro \ --volume=/sys:/sys:ro \ --volume=/var/lib/docker/:/var/lib/docker:ro \ --volume=/dev/disk/:/dev/disk:ro \ --publish=8080:8080 \ --detach=true \ --name=cadvisor \ google/cadvisor:latest
  5. Como rodar o node_exporter? $ docker run -d \ --net="host"

    \ --pid="host" \ -v "/:/host:ro,rslave" \ quay.io/prometheus/node-exporter \ --path.rootfs /host