mirror of
https://github.com/amir20/dozzle.git
synced 2026-08-07 08:54:45 +00:00
bd4651fb0b
Deploy VitePress site to Pages / build (push) Has been cancelled
Deploy VitePress site to Pages / Deploy (push) Has been cancelled
Push container / Push branches and PRs (push) Has been cancelled
Test / Typecheck (push) Has been cancelled
Test / JavaScript Tests (push) Has been cancelled
Test / Go Tests (push) Has been cancelled
Test / Go Staticcheck (push) Has been cancelled
Test / Integration Tests (push) Has been cancelled
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
21 lines
517 B
Go
21 lines
517 B
Go
package web
|
|
|
|
import (
|
|
"encoding/json"
|
|
"net/http"
|
|
|
|
"github.com/amir20/dozzle/internal/container"
|
|
)
|
|
|
|
func (h *handler) debugStore(w http.ResponseWriter, r *http.Request) {
|
|
respone := make(map[string]any)
|
|
respone["hosts"] = h.hostService.Hosts()
|
|
containers, errors := h.hostService.ListAllContainers(container.ContainerLabels{})
|
|
respone["containers"] = containers
|
|
respone["errors"] = errors
|
|
|
|
w.Header().Set("Content-Type", "application/json")
|
|
w.WriteHeader(http.StatusOK)
|
|
json.NewEncoder(w).Encode(respone)
|
|
}
|