grafana/grafana-docker

Failure to run Grafana 5.1.0 on centos 7 with host bindings

xlson opened this issue · 1 comments

xlson commented

OS: Centos 7
Grafana version: 5.1.0

When running Grafana 5.1.0 in Docker on Centos 7 using local host bindings Grafana fails to create the database file /var/lib/grafana/grafana.db. This configuration works on Ubuntu 16.04 without any problems.

Configuration:

sudo mkdir -p /home/new-grafana/grafana/etc/provisioning \
    /home/new-grafana/grafana/var/lib \
    /home/new-grafana/grafana/var/log\
    /home/new-grafana/grafana/home_dash_files

docker run --user root -p 3000:3000 --name=grafana \
    -v /home/new-grafana/grafana/etc/provisioning:/etc/grafana/provisioning \
    -v /home/new-grafana/grafana/var/lib:/var/lib/grafana \
    -v /home/new-grafana/grafana/var/log:/var/log/grafana \
    -v /home/new-grafana/grafana/home_dash_files:/home/dash_files \
    grafana/grafana:5.1.0

These problems are probably related to selinux ACLs.

Originates from community question: https://community.grafana.com/t/grafana-5-1-0-docker-image-cant-handle-the-permissions/7342/6

xlson commented

This is apparently a problem if you install the rpm for docker, but not docker-ce. Will close it for now.