Documentation
¶
Index ¶
- Variables
- type BuildCacheInfo
- type BuildCacheSummary
- type ContainerInfo
- type ContainerSummary
- type DeleteRequest
- type DeleteResult
- type DiskUsage
- type Handler
- type ImageInfo
- type ImageSummary
- type MaintenanceInfo
- type NetworkInfo
- type NetworkSummary
- type PruneRequest
- type PruneResult
- type Service
- type SystemInfo
- type VolumeInfo
- type VolumeSummary
Constants ¶
This section is empty.
Variables ¶
View Source
var Module = fx.Module("maintenance", fx.Provide(NewService), fx.Provide(NewHandler), )
Functions ¶
This section is empty.
Types ¶
type BuildCacheInfo ¶
type BuildCacheInfo struct {
ID string `json:"id"`
Parent string `json:"parent,omitempty"`
Type string `json:"type"`
Size int64 `json:"size"`
Created time.Time `json:"created"`
LastUsed time.Time `json:"last_used"`
UsageCount int `json:"usage_count"`
InUse bool `json:"in_use"`
Description string `json:"description"`
}
type BuildCacheSummary ¶
type BuildCacheSummary struct {
TotalCount int `json:"total_count"`
TotalSize int64 `json:"total_size"`
Cache []BuildCacheInfo `json:"cache"`
}
type ContainerInfo ¶
type ContainerSummary ¶
type ContainerSummary struct {
RunningCount int `json:"running_count"`
StoppedCount int `json:"stopped_count"`
TotalCount int `json:"total_count"`
TotalSize int64 `json:"total_size"`
Containers []ContainerInfo `json:"containers"`
}
type DeleteRequest ¶
type DeleteResult ¶
type ImageSummary ¶
type MaintenanceInfo ¶
type MaintenanceInfo struct {
SystemInfo SystemInfo `json:"system_info"`
DiskUsage DiskUsage `json:"disk_usage"`
ImageSummary ImageSummary `json:"image_summary"`
ContainerSummary ContainerSummary `json:"container_summary"`
VolumeSummary VolumeSummary `json:"volume_summary"`
NetworkSummary NetworkSummary `json:"network_summary"`
BuildCacheSummary BuildCacheSummary `json:"build_cache_summary"`
LastUpdated time.Time `json:"last_updated"`
}
type NetworkInfo ¶
type NetworkSummary ¶
type NetworkSummary struct {
TotalCount int `json:"total_count"`
UnusedCount int `json:"unused_count"`
Networks []NetworkInfo `json:"networks"`
}
type PruneRequest ¶
type PruneRequest struct {
Type string `json:"type"` // "images", "containers", "volumes", "networks", "system"
Force bool `json:"force"` // Force removal without confirmation
All bool `json:"all"` // For images: remove all unused (not just dangling)
Filters string `json:"filters"` // Optional filters
}
type PruneResult ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) DeleteResource ¶
func (s *Service) DeleteResource(ctx context.Context, req *DeleteRequest) (*DeleteResult, error)
func (*Service) GetSystemInfo ¶
func (s *Service) GetSystemInfo(ctx context.Context) (*MaintenanceInfo, error)
func (*Service) PruneDocker ¶
func (s *Service) PruneDocker(ctx context.Context, req *PruneRequest) (*PruneResult, error)
type SystemInfo ¶
type SystemInfo struct {
Version string `json:"version"`
APIVersion string `json:"api_version"`
Architecture string `json:"architecture"`
OS string `json:"os"`
KernelVersion string `json:"kernel_version"`
TotalMemory int64 `json:"total_memory"`
NCPU int `json:"ncpu"`
StorageDriver string `json:"storage_driver"`
DockerRootDir string `json:"docker_root_dir"`
ServerVersion string `json:"server_version"`
}
type VolumeInfo ¶
type VolumeSummary ¶
type VolumeSummary struct {
TotalCount int `json:"total_count"`
UnusedCount int `json:"unused_count"`
TotalSize int64 `json:"total_size"`
UnusedSize int64 `json:"unused_size"`
Volumes []VolumeInfo `json:"volumes"`
}
Click to show internal directories.
Click to hide internal directories.