import "istio.io/istio/pkg/test/framework/components/istio"
config.go eastwest.go flags.go helm.go ingress.go istio.go operator.go util.go
const ( // DefaultSystemNamespace default value for SystemNamespace DefaultSystemNamespace = "istio-system" // IntegrationTestDefaultsIOP is the path of the default IstioOperator spec to use // for integration tests IntegrationTestDefaultsIOP = "tests/integration/iop-integration-test-defaults.yaml" // IntegrationTestRemoteDefaultsIOP is the path of the default IstioOperator spec to use // on remote clusters for integration tests IntegrationTestRemoteDefaultsIOP = "tests/integration/iop-remote-integration-test-defaults.yaml" // DefaultDeployTimeout for Istio DefaultDeployTimeout = time.Second * 300 // DefaultCIDeployTimeout for Istio DefaultCIDeployTimeout = time.Minute * 10 // DefaultUndeployTimeout for Istio. DefaultUndeployTimeout = time.Second * 300 // DefaultCIUndeployTimeout for Istio. DefaultCIUndeployTimeout = time.Second * 900 )
const ( ReleasePrefix = "istio-" BaseChart = "base" DiscoveryChart = "istio-discovery" BaseReleaseName = ReleasePrefix + BaseChart IstiodReleaseName = "istiod" ControlChartsDir = "istio-control" )
ClaimSystemNamespace retrieves the namespace for the Istio system components from the environment.
ClaimSystemNamespaceOrFail calls ClaimSystemNamespace, failing the test if an error occurs.
Indent indents a block of text with an indent string
func Setup(i *Instance, cfn SetupConfigFn, ctxFns ...SetupContextFn) resource.SetupFn
Setup is a setup function that will deploy Istio on Kubernetes environment
type Config struct { // The namespace where the Istio components (<=1.1) reside in a typical deployment (default: "istio-system"). SystemNamespace string // The namespace in which istio ca and cert provisioning components are deployed. IstioNamespace string // The namespace in which config, discovery and auto-injector are deployed. ConfigNamespace string // The namespace in which kiali, tracing providers, graphana, prometheus are deployed. TelemetryNamespace string // The namespace in which istio policy checker is deployed. PolicyNamespace string // The namespace in which istio ingressgateway is deployed IngressNamespace string // The namespace in which istio egressgateway is deployed EgressNamespace string // DeployTimeout the timeout for deploying Istio. DeployTimeout time.Duration // UndeployTimeout the timeout for undeploying Istio. UndeployTimeout time.Duration // The IstioOperator spec file to be used for Control plane cluster by default PrimaryClusterIOPFile string // The IstioOperator spec file to be used for Config cluster by default ConfigClusterIOPFile string // The IstioOperator spec file to be used for Remote cluster by default RemoteClusterIOPFile string // Override values specifically for the ICP crd // This is mostly required for cases where --set cannot be used // These values are applied to non-remote clusters ControlPlaneValues string // Override values specifically for the ICP crd // This is mostly required for cases where --set cannot be used // These values are only applied to remote clusters // Default value will be ControlPlaneValues if no remote values provided RemoteClusterValues string // Override values specifically for the ICP crd // This is mostly required for cases where --set cannot be used // These values are only applied to config clusters // Default value will be ControlPlaneValues if no remote values provided ConfigClusterValues string // Overrides for the Helm values file. Values map[string]string // Indicates that the test should deploy Istio into the target Kubernetes cluster before running tests. DeployIstio bool // Do not wait for the validation webhook before completing the deployment. This is useful for // doing deployments without Galley. SkipWaitForValidationWebhook bool // Indicates that the test should deploy Istio's east west gateway into the target Kubernetes cluster // before running tests. DeployEastWestGW bool // Indicates that the test should deploy Istio's using helm charts DeployHelm bool }
Config provide kube-specific Config from flags.
DefaultConfig creates a new Config from defaults, environments variables, and command-line parameters.
DefaultConfigOrFail calls DefaultConfig and fails t if an error occurs.
String implements fmt.Stringer
type Instance interface { resource.Resource // IngressFor returns an ingress used for reaching workloads in the given cluster. // The ingress's service name will be "istio-ingressgateway" and the istio label will be "ingressgateway". IngressFor(cluster resource.Cluster) ingress.Instance // CustomIngressFor returns an ingress with a specific service name and "istio" label used for reaching workloads // in the given cluster. CustomIngressFor(cluster resource.Cluster, serviceName, istioLabel string) ingress.Instance // RemoteDiscoveryAddressFor returns the external address of the discovery server that controls // the given cluster. This allows access to the discovery server from // outside its cluster. RemoteDiscoveryAddressFor(cluster resource.Cluster) (net.TCPAddr, error) Settings() Config }
Instance represents a deployed Istio instance
Deploy deploys (or attaches to) an Istio deployment and returns a handle. If cfg is nil, then DefaultConfig is used.
Get returns the Istio component from the context. If there is none an error is returned.
GetOrFail returns the Istio component from the context. If there is none the test is failed.
SetupConfigFn is a setup function that specifies the overrides of the configuration to deploy Istio.
SetupContextFn is a setup function that uses Context for configuration.
Path | Synopsis |
---|---|
ingress |
Package istio imports 45 packages (graph) and is imported by 10 packages. Updated 2021-01-23. Refresh now. Tools for package owners.