Closed TheCrimsonLady closed 2 years ago
@lhridder could you look into this?
It seems like environment variables for this feature are not implemented yet: https://github.com/haveachin/infrared/blob/68b01d674d161f89f1899c5f352ece912fc16bd8/cmd/infrared/main.go#L60
It seems like environment variables for this feature are not implemented yet:
Ok thanks for the clarification, that explains it
I'll close this issue
If this is merged you can enable it with environment variables
If this is merged you can enable it with environment variables
I assume you mean with the -e
Flags when deploying the Docker Container?
Yes
Thanks a lot 😄
This has now been merged into main :)
This has now been merged into main :)
Yeah I saw that earlier today, but I think I still pass the environment variable wrong. I redeployed my infrared container multiple times with the following commands (this is always only the last command the readme provides):
docker run -d --name infrared --restart=unless-stopped -it -v /usr/local/infrared/configs/:/configs -e enable-prometheus -e PROMETHEUS_ENABLED -p 25565:25565/tcp --expose 25565 haveachin/infrared:latest
docker rm infrared && docker run -d --name infrared --restart=unless-stopped -it -e PROMETHEUS_ENABLED -e enable-prometheus=true -v /usr/local/infrared/configs/:/configs -p 25565:25565/tcp --expose 25565 haveachin/infrared:latest
docker run -d --name infrared --restart=unless-stopped -it -e PROMETHEUS_ENABLED -e -enable-prometheus=true -v /usr/local/infrared/configs/:/configs -p 25565:25565/tcp --expose 25565 --expose 9100 -p 9100:9100/tcp -p 9100:9100/udp haveachin/infrared:latest
None of the commands seem to enable the Prometheus feature, according to my prometheus webUI (see attached image)
How exactly do you have to pass them?
I noticed that there are some issues with the building pipeline or are you building it from source?
No, I'm using the commands in the readme to deploy/update infrared. I just added the flags for prometheus
But building from source is another thing I wanted to open an issue on here, since I was unable to use my own fork to build the container. But I think I should do that in another issue
Ah you should use INFRARED_PROMETHEUS_ENABLED=true
and INFRARED_PROMETHEUS_BIND=":9100"
Oh ok, thanks for the tip! I'll try that once there are no players on my server anymore
Maybe change the readme to make this more clear because the wording right now is sorta ambiguous in contrast to your suggestion.
Yes i forgot to add the new env variables to the readme, my bad
Oh ok, thanks for the tip! I'll try that once there are no players on my server anymore
Maybe change the readme to make this more clear because the wording right now is sorta ambiguous in contrast to your suggestion.
There is also a complete rewrite on its way. So there will probably no new features or changes for the current version.
Describe the bug I am unable to get the node_exporter function to get to work since I don't know where I am supposed to add the command line flags, or where the infrared binary mentioned in the documentation is. Due to the lack of the CMD section in the Dockerfile, I am unsure where the command line flags need to go.
To Reproduce Deploying as normal Docker container (not Docker compose) on Debian 10.
Expected behavior Passing command line flags to enable the node_exporter function
Screenshots (Optional) I tried to pass the flags with the -e docker flag (to no avail), entering the container with a shell did not work either and I am unsure as if how to pass the command line flags to the RUN section in the Dockerfile