Documentation ¶
Index ¶
- type ApplicationTunnel
- type Cert
- type CertsDump
- type ConfigWriter
- func (c *ConfigWriter) Prime(b []byte) error
- func (c *ConfigWriter) PrintBootstrapDump(outputFormat string) error
- func (c *ConfigWriter) PrintConnectionsDump(filter ConnectionsFilter, outputFormat string) error
- func (c *ConfigWriter) PrintConnectionsSummary(filter ConnectionsFilter) error
- func (c *ConfigWriter) PrintFullDump(outputFormat string) error
- func (c *ConfigWriter) PrintFullSummary() error
- func (c *ConfigWriter) PrintPodRootCAFromDynamicSecretDump() (string, error)
- func (c *ConfigWriter) PrintPolicyDump(filter PolicyFilter, outputFormat string) error
- func (c *ConfigWriter) PrintPolicySummary(filter PolicyFilter) error
- func (c *ConfigWriter) PrintSecretDump(outputFormat string) error
- func (c *ConfigWriter) PrintSecretSummary() error
- func (c *ConfigWriter) PrintServiceDump(filter ServiceFilter, outputFormat string) error
- func (c *ConfigWriter) PrintServiceSummary(filter ServiceFilter) error
- func (c *ConfigWriter) PrintVersionSummary() error
- func (c *ConfigWriter) PrintWorkloadDump(filter WorkloadFilter, outputFormat string) error
- func (c *ConfigWriter) PrintWorkloadSummary(filter WorkloadFilter) error
- type ConnectionsFilter
- type GatewayAddress
- type InboundConnection
- type LoadBalancer
- type Locality
- type OutboundConnection
- type PolicyFilter
- type PolicyMatch
- type ServiceFilter
- type StringMatch
- type WorkloadConnection
- type WorkloadConnections
- type WorkloadFilter
- type WorkloadInfo
- type WorkloadState
- type ZtunnelDump
- type ZtunnelEndpoint
- type ZtunnelPolicy
- type ZtunnelService
- type ZtunnelWorkload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApplicationTunnel ¶
type ConfigWriter ¶
type ConfigWriter struct { Stdout io.Writer FullDump []byte // contains filtered or unexported fields }
ConfigWriter is a writer for processing responses from the Ztunnel Admin config_dump endpoint
func (*ConfigWriter) Prime ¶
func (c *ConfigWriter) Prime(b []byte) error
Prime loads the config dump into the writer ready for printing
func (*ConfigWriter) PrintBootstrapDump ¶
func (c *ConfigWriter) PrintBootstrapDump(outputFormat string) error
PrintBootstrapDump prints just the bootstrap config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintConnectionsDump ¶
func (c *ConfigWriter) PrintConnectionsDump(filter ConnectionsFilter, outputFormat string) error
func (*ConfigWriter) PrintConnectionsSummary ¶
func (c *ConfigWriter) PrintConnectionsSummary(filter ConnectionsFilter) error
func (*ConfigWriter) PrintFullDump ¶
func (c *ConfigWriter) PrintFullDump(outputFormat string) error
func (*ConfigWriter) PrintFullSummary ¶
func (c *ConfigWriter) PrintFullSummary() error
func (*ConfigWriter) PrintPodRootCAFromDynamicSecretDump ¶
func (c *ConfigWriter) PrintPodRootCAFromDynamicSecretDump() (string, error)
PrintPodRootCAFromDynamicSecretDump prints just pod's root ca from dynamic secret config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintPolicyDump ¶
func (c *ConfigWriter) PrintPolicyDump(filter PolicyFilter, outputFormat string) error
PrintPolicyDump prints the relevant services in the config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintPolicySummary ¶
func (c *ConfigWriter) PrintPolicySummary(filter PolicyFilter) error
PrintServiceSummary prints a summary of the relevant services in the config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintSecretDump ¶
func (c *ConfigWriter) PrintSecretDump(outputFormat string) error
PrintSecretDump prints just the secret config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintSecretSummary ¶
func (c *ConfigWriter) PrintSecretSummary() error
PrintSecretSummary prints a summary of dynamic active secrets from the config dump
func (*ConfigWriter) PrintServiceDump ¶
func (c *ConfigWriter) PrintServiceDump(filter ServiceFilter, outputFormat string) error
PrintServiceDump prints the relevant services in the config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintServiceSummary ¶
func (c *ConfigWriter) PrintServiceSummary(filter ServiceFilter) error
PrintServiceSummary prints a summary of the relevant services in the config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintVersionSummary ¶
func (c *ConfigWriter) PrintVersionSummary() error
PrintVersionSummary prints version information for Istio and Ztunnel from the config dump
func (*ConfigWriter) PrintWorkloadDump ¶
func (c *ConfigWriter) PrintWorkloadDump(filter WorkloadFilter, outputFormat string) error
PrintWorkloadDump prints the relevant workloads in the config dump to the ConfigWriter stdout
func (*ConfigWriter) PrintWorkloadSummary ¶
func (c *ConfigWriter) PrintWorkloadSummary(filter WorkloadFilter) error
PrintWorkloadSummary prints a summary of the relevant listeners in the config dump to the ConfigWriter stdout
type ConnectionsFilter ¶
type GatewayAddress ¶
type GatewayAddress struct {
Destination string `json:"destination"`
}
type InboundConnection ¶
type LoadBalancer ¶
type OutboundConnection ¶
type PolicyFilter ¶
type PolicyFilter struct {
Namespace string
}
PolicyFilter is used to pass filter information into service based config writer print functions
func (*PolicyFilter) Verify ¶
func (wf *PolicyFilter) Verify(pol *ZtunnelPolicy) bool
Verify returns true if the passed workload matches the filter fields
type PolicyMatch ¶
type PolicyMatch struct { Namespaces []StringMatch `json:"namespaces,omitempty"` NotNamespaces []StringMatch `json:"notNamespaces,omitempty"` Principals []StringMatch `json:"principals,omitempty"` NotPrincipals []StringMatch `json:"notPrincipals,omitempty"` SourceIps []string `json:"sourceIps,omitempty"` NotSourceIps []string `json:"notSourceIps,omitempty"` DestinationIps []string `json:"destinationIps,omitempty"` NotDestinationIps []string `json:"notDestinationIps,omitempty"` DestinationPorts []uint16 `json:"destinationPorts,omitempty"` NotDestinationPorts []uint16 `json:"notDestinationPorts,omitempty"` }
type ServiceFilter ¶
type ServiceFilter struct {
Namespace string
}
ServiceFilter is used to pass filter information into service based config writer print functions
func (*ServiceFilter) Verify ¶
func (wf *ServiceFilter) Verify(svc *ZtunnelService) bool
Verify returns true if the passed workload matches the filter fields
type StringMatch ¶
type WorkloadConnection ¶
type WorkloadConnections ¶
type WorkloadConnections struct { Inbound []InboundConnection `json:"inbound"` Outbound []OutboundConnection `json:"outbound"` }
type WorkloadFilter ¶
WorkloadFilter is used to pass filter information into workload based config writer print functions
func (*WorkloadFilter) Verify ¶
func (wf *WorkloadFilter) Verify(workload *ZtunnelWorkload) bool
Verify returns true if the passed workload matches the filter fields
type WorkloadInfo ¶
type WorkloadState ¶
type WorkloadState struct { State string `json:"state,omitempty"` Connections WorkloadConnections `json:"connections,omitempty"` Info WorkloadInfo `json:"info"` }
type ZtunnelDump ¶
type ZtunnelDump struct { Workloads []*ZtunnelWorkload `json:"workloads"` Services []*ZtunnelService `json:"services"` Policies []*ZtunnelPolicy `json:"policies"` Certificates []*CertsDump `json:"certificates"` WorkloadState map[string]WorkloadState `json:"workloadState"` }
type ZtunnelEndpoint ¶
type ZtunnelPolicy ¶
type ZtunnelPolicy struct { Name string `json:"name"` Namespace string `json:"namespace"` Scope string `json:"scope"` Action string `json:"action"` Rules [][][]*PolicyMatch `json:"rules"` }
type ZtunnelService ¶
type ZtunnelService struct { Name string `json:"name"` Namespace string `json:"namespace"` Hostname string `json:"hostname"` Addresses []string `json:"vips"` Ports map[string]int `json:"ports"` LoadBalancer *LoadBalancer `json:"loadBalancer,omitempty"` Waypoint *GatewayAddress `json:"waypoint,omitempty"` Endpoints map[string]*ZtunnelEndpoint `json:"endpoints"` SubjectAltNames []string `json:"subjectAltNames,omitempty"` IPFamilies string `json:"ipFamilies"` }
type ZtunnelWorkload ¶
type ZtunnelWorkload struct { UID string `json:"uid"` WorkloadIPs []string `json:"workloadIps"` Waypoint *GatewayAddress `json:"waypoint,omitempty"` NetworkGateway *GatewayAddress `json:"networkGateway,omitempty"` Protocol string `json:"protocol"` Name string `json:"name"` Namespace string `json:"namespace"` ServiceAccount string `json:"serviceAccount"` WorkloadName string `json:"workloadName"` WorkloadType string `json:"workloadType"` CanonicalName string `json:"canonicalName"` CanonicalRevision string `json:"canonicalRevision"` ClusterID string `json:"clusterId"` TrustDomain string `json:"trustDomain,omitempty"` Locality Locality `json:"locality,omitempty"` Node string `json:"node"` Network string `json:"network,omitempty"` Status string `json:"status"` Hostname string `json:"hostname"` ApplicationTunnel ApplicationTunnel `json:"applicationTunnel,omitempty"` AuthorizationPolicies []string `json:"authorizationPolicies,omitempty"` }