features

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 27, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package features provides sample mutations for the networkpolicy primitive example.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DNSEgressMutation

func DNSEgressMutation() networkpolicy.Mutation

DNSEgressMutation adds an egress rule allowing UDP traffic on port 53 for DNS resolution. It is always enabled (nil Feature gate).

func HTTPIngressMutation

func HTTPIngressMutation() networkpolicy.Mutation

HTTPIngressMutation adds an ingress rule allowing TCP traffic on port 8080. It is always enabled (nil Feature gate).

func MetricsIngressMutation

func MetricsIngressMutation(version string, enableMetrics bool) networkpolicy.Mutation

MetricsIngressMutation adds an ingress rule allowing TCP traffic on port 9090 for Prometheus scraping. It is enabled when enableMetrics is true.

func VersionLabelMutation

func VersionLabelMutation(version string) networkpolicy.Mutation

VersionLabelMutation sets the app.kubernetes.io/version label on the NetworkPolicy. It is always enabled (nil Feature gate).

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL