Documentation
¶
Index ¶
- func GetInputPorts(inputs []obs.InputSpec) []int32
- func GetOutputPortsWithProtocols(outputs []obs.OutputSpec, portProtocolMap map[factory.PortProtocol]bool)
- func GetProxyPorts(portProtocolMap map[factory.PortProtocol]bool)
- func ReconcileClusterLogForwarderNetworkPolicy(k8Client client.Client, namespace, policyName, instanceName, component string, ...) error
- func ReconcileInputService(k8sClient client.Client, namespace, name, instance, certSecretName string, ...) error
- func ReconcileLogFileMetricsExporterNetworkPolicy(k8Client client.Client, namespace, policyName, instanceName, component string, ...) error
- func ReconcileService(k8sClient client.Client, ...) error
- func RemoveNetworkPolicy(k8Client client.Client, namespace, name string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetInputPorts ¶
GetInputPorts extracts all unique ports from the given input receiver specs. It returns the ports that input receivers are configured to listen on.
func GetOutputPortsWithProtocols ¶
func GetOutputPortsWithProtocols(outputs []obs.OutputSpec, portProtocolMap map[factory.PortProtocol]bool)
GetOutputPortsWithProtocols extracts all unique ports with their protocols from the given outputs. It parses URLs to extract ports and protocols, or uses default values based on the output type.
func GetProxyPorts ¶
func GetProxyPorts(portProtocolMap map[factory.PortProtocol]bool)
GetProxyPorts extracts unique ports from cluster-wide proxy environment variables. It parses HTTP_PROXY and HTTPS_PROXY URLs to determine explicit proxy ports, or adds default ports (80 for HTTP, 443 for HTTPS) when no port is specified.
func ReconcileClusterLogForwarderNetworkPolicy ¶
func ReconcileClusterLogForwarderNetworkPolicy(k8Client client.Client, namespace, policyName, instanceName, component string, policyRuleSet obsv1.NetworkPolicyRuleSetType, outputs []obsv1.OutputSpec, inputs []obsv1.InputSpec, ownerRef metav1.OwnerReference, visitor func(o runtime.Object)) error
ReconcileClusterLogForwarderNetworkPolicy reconciles the NetworkPolicy for the clusterlogforwarder It handles both AllowAllIngressEgress and RestrictIngressEgress rule sets, parsing ports from outputs and inputs when needed.
func ReconcileInputService ¶
func ReconcileLogFileMetricsExporterNetworkPolicy ¶
func ReconcileLogFileMetricsExporterNetworkPolicy(k8Client client.Client, namespace, policyName, instanceName, component string, policyRuleSet loggingv1alpha1.NetworkPolicyRuleSetType, ownerRef metav1.OwnerReference, visitor func(o runtime.Object)) error
ReconcileLogFileMetricsExporterNetworkPolicy reconciles the NetworkPolicy for the logfilemetricexporter
Types ¶
This section is empty.