1
I installed the graphite container via Docker as follows :
docker run -d --name=grafana \
--restart always \
-p 5000:3000 \
-e "GF_SERVER_PROTOCOL=http" \
-e "GF_SERVER_ROOT_URL=http://meuIP" \
-e "GF_SERVER_HTTP_PORT=3000" \
-v /docker/grafana/data:/var/lib/grafana \
grafana/grafana
But when I try to access it will not because it is not running on the IP I want ( meuIP) and yes no 0.0.0.0
as shown below :
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
2c7246e98d99 grafana/grafana "/run.sh" About a minute ago Up 4 seconds 0.0.0.0:5000->3000/tcp grafana
In this case how do I route and access it by typing http://meuIP:5000 in the browser ?
EDITED :
I’m using the Centos7.
The Docker version is :
Client:
Version: 17.05.0-ce
API version: 1.29
Go version: go1.7.5
Git commit: 89658be
Built: Thu May 4 22:06:25 2017
OS/Arch: linux/amd64
Server:
Version: 17.05.0-ce
API version: 1.29 (minimum version 1.12)
Go version: go1.7.5
Git commit: 89658be
Built: Thu May 4 22:06:25 2017
OS/Arch: linux/amd64
Experimental: false
Edited 2 :
The problem is that overnight the container gets status Exited (1)
seconds after I spin.
If I do it like this it spins and I can access :
docker run \
-d \
-p 5200:3000 \
grafana/grafana
But I want to install the plugin from Zabbix too. Ai if I do so it exits after 10 seconds:
docker run -d \
-p 5100:3000 \
-e "GF_INSTALL_PLUGINS=alexanderzobnin-zabbix-app" \
grafana/grafana
I also want to redirect the container data to a specific folder so if something goes wrong I can recover .
If I do it like this, it turns him on:
docker run \
-d \
-p 5200:3000 \
-v /docker/grafana/data:/var/lib/grafana \
grafana/grafana
But I wanted to do it this way :
docker run -d \
-p 5100:3000 \
-e "GF_INSTALL_PLUGINS=alexanderzobnin-zabbix-app" \
-v /docker/grafana/data:/var/lib/grafana \
grafana/grafana
Does anyone know why the container is being canceled when I try to install the plugin or redirect the output ?
Do a test like this:
docker run -d -p 3000:3000 grafana/grafana
. After that tries to accesshttp://localhost:3000
and tell me if you can access.– Tuxpilgrim
@Tuxpilgrim, yes I tried but it also doesn’t work.
– Beto
On Linux. More precisely on Centos 7.
– Beto
I edited the question to add more information.
– Beto
I edited the question again.
– Beto
I suggest you edit the title of the question, the problem apparently no longer relates to accessing the address of container.
– Tuxpilgrim
Edited title.
– Beto