Documentation
¶
Index ¶
Constants ¶
View Source
const Name = "services"
Name is the registry key for this scanner.
Variables ¶
This section is empty.
Functions ¶
func NewScanner ¶
NewScanner returns a scanner that lists all services in a cluster.
Types ¶
type Data ¶
type Data struct {
// Count is the total number of services.
Count int `json:"count"`
// Services lists all services across all namespaces.
Services []ServiceInfo `json:"services"`
}
Data holds service information for one cluster.
type PortInfo ¶
type PortInfo struct {
// Name is the port name.
Name string `json:"name,omitempty"`
// Port is the service port number.
Port int32 `json:"port"`
// Protocol is the port protocol (TCP, UDP, SCTP).
Protocol string `json:"protocol"`
}
PortInfo describes a single port on a service.
type ServiceInfo ¶
type ServiceInfo struct {
// Namespace is the namespace containing the service.
Namespace string `json:"namespace"`
// Name is the service name.
Name string `json:"name"`
// Type is the service type (ClusterIP, NodePort, LoadBalancer, ExternalName).
Type string `json:"type"`
// Ports lists the port specifications.
Ports []PortInfo `json:"ports,omitempty"`
}
ServiceInfo describes a single service.
Click to show internal directories.
Click to hide internal directories.