Git Product home page Git Product logo

docker-raspberry-pi-monitoring's Introduction

Docker-Raspberry-PI-Monitoring

Introduction

A monitoring solution for Docker hosts and containers with Prometheus, Grafana, cAdvisor, NodeExporter.

You can download this dashboard at Grafana Dashboard Community

Screenshot

image

Installation

First SSH into your Pi and there is one thing we need to do before we get cracking. We need to enable c-groups so the stack will work out of the box. To do this you need to modify the configuration file /boot/cmdline.txt:

sudo nano /boot/cmdline.txt

And add the following options:

cgroup_enable=memory cgroup_memory=1

Now save the file in your editor and reboot:

sudo reboot

Then clone this repository on your Pi host, cd into Docker-Raspberry-PI-Monitoring directory and run docker-compose up:

git clone https://github.com/oijkn/Docker-Raspberry-PI-Monitoring.git
cd Docker-Raspberry-PI-Monitoring
docker-compose up -d

Containers:

  • Prometheus (metrics database) http://:9090
  • Grafana (visualize metrics) http://:3000
  • NodeExporter (host metrics collector)
  • cAdvisor (containers metrics collector)

Setup Grafana

Navigate to http://<host-ip>:3000 and login with user admin password admin. You can change the credentials in the compose file or by supplying the ADMIN_USER and ADMIN_PASSWORD environment variables on compose up.

GF_SECURITY_ADMIN_USER=admin
GF_SECURITY_ADMIN_PASSWORD=changeme
GF_USERS_ALLOW_SIGN_UP=false

Grafana is not preconfigured with dashboard, so you have to import it from the json file. And set Prometheus as the default data source.

Grafana > Configuration > Data Sources > Prometheus

image

Setup Prometheus

scrape_configs:
  - job_name: 'prometheus'
    scrape_interval: 30s
    static_configs:
      - targets: ['localhost:9090', 'cadvisor:8080', 'node-exporter:9100']

docker-raspberry-pi-monitoring's People

Contributors

oijkn avatar rmiddle avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.