Don't query state in docker discovery

As it's not supported on some older docker, and not used anyway
This commit is contained in:
Daniel Berteaud 2022-01-20 14:54:19 +01:00
parent 8140dcb7cf
commit 80bfaee714
1 changed files with 1 additions and 2 deletions

View File

@ -31,8 +31,7 @@ if ($what =~ m/^containers?/){
$format = '{' .
'"{#DOCKER_CONTAINER_ID}":"{{ .ID }}",' .
'"{#DOCKER_CONTAINER_IMAGE}": "{{ .Image }}",' .
'"{#DOCKER_CONTAINER_NAME}":"{{ .Names }}",' .
'"{#DOCKER_CONTAINER_STATE}": "{{ .State }}"' .
'"{#DOCKER_CONTAINER_NAME}":"{{ .Names }}"' .
'}';
$cmd = "$docker container list --all --format '$format'";
} elsif ($what =~ m/^networks?/){