Skip to content

Easily runnable example to view how yabeda metrics works in action

Notifications You must be signed in to change notification settings

yabeda-rb/example-prometheus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Example of Rails and Sidekiq metrics exported to Prometheus + Grafana

This example illustrates how to use yabeda gem suite with rails application to draw graphs for app metrics.

Prerequisites

Recent versions of Docker and Docker Compose installed.

Usage

Notes

Possible errors and their solutions

Permission denied error / My grafana container is not running (Stopping after boot)

If your grafana's container is not running correctly after you run docker-compose up you're probably getting this error, if you check at docker ps -a you'll see your grana container with the status Exited, picks the id of this container and run docker logs YOUR_GRAFANA_CONTAINER_ID and check if the errors is equal to the following:

GF_PATHS_DATA='/var/lib/grafana' is not writable.                                                                                      
You may have issues with file permissions, more information here: http:https://docs.grafana.org/installation/docker/#migration-from-a-previou
s-version-of-the-docker-container-to-5-1-or-later                                                                                      
mkdir: cannot create directory '/var/lib/grafana/plugins': Permission denied   

Solution

Replace at your docker-compose.yml line 38 by your user's id that you will get on the following command:

id -u

Acknowledgement

The configurations are based off the following articles and repositories:

License

This example is available as open source under the terms of the MIT License.