1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-24 15:59:41 +02:00

fix(images): consider stopped containers for unused label [EE-6983] (#11629)

This commit is contained in:
Prabhat Khera 2024-04-18 17:14:39 +12:00 committed by GitHub
parent e7a2b6268e
commit c15789eb73
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -64,7 +64,9 @@ func (handler *Handler) imagesList(w http.ResponseWriter, r *http.Request) *http
imageUsageSet := set.Set[string]{}
if withUsage {
containers, err := cli.ContainerList(r.Context(), container.ListOptions{})
containers, err := cli.ContainerList(r.Context(), container.ListOptions{
All: true,
})
if err != nil {
return httperror.InternalServerError("Unable to retrieve Docker containers", err)
}