1
0
mirror of https://github.com/amir20/dozzle.git synced 2026-01-03 11:35:00 +01:00

feat: adds labels to fuzzy search dialog (#2649)

This commit is contained in:
Amir Raminfar
2024-01-04 07:47:51 -08:00
committed by GitHub
parent ee4f94ce2e
commit a4026e16e8
7 changed files with 22 additions and 15 deletions

View File

@@ -190,6 +190,7 @@ func (d *Client) ListContainers() ([]Container, error) {
Status: c.Status,
Host: d.host.ID,
Health: findBetweenParentheses(c.Status),
Labels: c.Labels,
}
containers = append(containers, container)
}

View File

@@ -6,18 +6,19 @@ import (
// Container represents an internal representation of docker containers
type Container struct {
ID string `json:"id"`
Names []string `json:"names"`
Name string `json:"name"`
Image string `json:"image"`
ImageID string `json:"imageId"`
Command string `json:"command"`
Created int64 `json:"created"`
State string `json:"state"`
Status string `json:"status"`
Health string `json:"health,omitempty"`
Host string `json:"host,omitempty"`
Tty bool `json:"-"`
ID string `json:"id"`
Names []string `json:"names"`
Name string `json:"name"`
Image string `json:"image"`
ImageID string `json:"imageId"`
Command string `json:"command"`
Created int64 `json:"created"`
State string `json:"state"`
Status string `json:"status"`
Health string `json:"health,omitempty"`
Host string `json:"host,omitempty"`
Tty bool `json:"-"`
Labels map[string]string `json:"labels,omitempty"`
}
// ContainerStat represent stats instant for a container