-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Closed
Labels
Milestone
Description
Relevant telegraf.conf:
It's not really relevant, but:
[[inputs.docker]]
endpoint = "unix:///var/run/docker.sock"
gather_services = false
perdevice = false
total = trueSystem info:
Telegraf 1.9.1 (git: HEAD 2063609)
Docker 18.09.4, build d14af54266
Steps to reproduce:
- Run a container from a private registry on a specific port, but without a tag, e.g.
docker run -d repo.example.com:9003/postgres(no:latestor any other tag, which is a valid way to run a container) - Start Telegraf with the Docker input.
- Run
telegraf --config <file> --test --input-filter dockerand observe the output.
Expected behavior:
The container_image should be repo.example.com:9003/postgres and the container_version should be latest (since no tag was specified).
Actual behavior:
The metrics will show the container_image as repo.example.com and the container_version as 9003/postgres.
Additional info:
The image parsing logic is here, and does not account for the case where the registry URL includes a port and no tag is present in the image name.
Reactions are currently unavailable