jenkinsci / jenkinsci/docker-workflow-plugin

[JENKINS-43186] should not use `docker inspect <image>`

Open
#488 0 comments 0 reactions 0 assignees View on GitHub
component:docker-workflow-plugin enhancement imported-jira-issue priority:minor resolution:unresolved
Dominant language
Java
Stars
527
Forks
422
Avg merge
10m
Merged PRs (30d)
1

Description

docker pipeline relies on `docker inspect` to check for image to exist, but this can result in false positive as this command to look for containers, networks, volumes, plugins and images.

Should use `docker images -q` and check for result count, or on 1.13 and later `docker image inspect `.

---
Originally reported by ndeloof, imported from: should not use `docker inspect `


  • status: Open
  • priority: Minor
  • component(s): docker-workflow-plugin
  • resolution: Unresolved
  • votes: 2
  • watchers: 7
  • imported: 2025-12-07

Raw content of original issue

docker pipeline relies on `docker inspect` to check for image to exist, but this can result in false positive as this command to look for containers, networks, volumes, plugins and images.

Should use `docker images <image> -q` and check for result count, or on 1.13 and later `docker image inspect <image>`.

environment

```
docker pipeline relies on `docker inspect` to check for image to exist, but this can result in false positive as this command to look for containers, networks, volumes, plugins and images.

Should use `docker images <image> -q` and check for result count, or on 1.13 and later `docker image inspect <image>`.

```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.