Documentation
¶
Index ¶
- Constants
- Variables
- func Deploy(p []Provisioned) error
- func FilterClusterNsName(zoneIndex int) string
- func GatewayClusterNsName(zoneIndex int) string
- type AuthType
- type FederatedNamespace
- type Identifier
- type LoadableProvisioned
- type LoadableZone
- type PrivateZone
- type Provisioned
- type WithCert
- type Zone
Constants ¶
View Source
const ( // NumGatewayZones is the number of managed identity zones to provision and test for gateway tests NumGatewayZones = 3 // GatewayClusterNsPrefix is the prefix for cluster-scoped gateway test namespaces (one per zone) GatewayClusterNsPrefix = "gateway-cluster-ns" // GatewayClusterSaName is the service account name used in cluster-scoped gateway test namespaces GatewayClusterSaName = "gateway-cluster-sa" // GatewayNsPublic is the namespace for namespace-scoped gateway tests with public zones GatewayNsPublic = "gateway-wi-ns" // GatewayNsPrivate is the namespace for namespace-scoped gateway tests with private zones GatewayNsPrivate = "private-gateway-wi-ns" // GatewayNsSaName is the service account name used in namespace-scoped gateway test namespaces GatewayNsSaName = "gateway-wi-sa" // FilterClusterNsPrefix is the prefix for cluster-scoped filter test namespaces (one per zone) FilterClusterNsPrefix = "filter-cluster-ns" // FilterClusterSaName is the service account name used in cluster-scoped filter test namespaces FilterClusterSaName = "filter-cluster-sa" // FilterNs is the namespace for namespace-scoped filter tests FilterNs = "filter-ns" // FilterNsSaName is the service account name used in namespace-scoped filter test namespace FilterNsSaName = "filter-sa" )
Variables ¶
View Source
var Infras = infras{ { Name: "basic-cluster", ResourceGroup: uniqueResourceGroup(), Location: getLocation(), Suffix: uuid.New().String(), }, { Name: "private-cluster", ResourceGroup: uniqueResourceGroup(), Location: getLocation(), Suffix: uuid.New().String(), McOpts: []clients.McOpt{clients.PrivateClusterOpt}, }, { Name: "osm-cluster", ResourceGroup: uniqueResourceGroup(), Location: getLocation(), Suffix: uuid.New().String(), McOpts: []clients.McOpt{clients.OsmClusterOpt, clients.VmCountOpt(8)}, }, { Name: "gateway-full-mesh-cluster", ResourceGroup: uniqueResourceGroup(), Location: getLocation(), Suffix: uuid.New().String()[:16], McOpts: []clients.McOpt{clients.IstioServiceMeshOpt, clients.ManagedGatewayOpt}, FederatedNamespaces: GenerateGatewayFederatedNamespaces(), }, { Name: "gateway-approuting-istio-cluster", ResourceGroup: uniqueResourceGroup(), Location: getLocation(), Suffix: uuid.New().String()[:16], McOpts: []clients.McOpt{clients.ManagedGatewayOpt, clients.AppRoutingIstioOpt}, FederatedNamespaces: GenerateGatewayFederatedNamespaces(), PostCreate: clients.EnableAppRoutingIstio, }, }
Infras is a list of infrastructure configurations the e2e tests will run against
Functions ¶
func Deploy ¶
func Deploy(p []Provisioned) error
func FilterClusterNsName ¶ added in v0.2.19
FilterClusterNsName returns the namespace name for a cluster-scoped filter test at the given zone index
func GatewayClusterNsName ¶ added in v0.2.19
GatewayClusterNsName returns the namespace name for a cluster-scoped gateway test at the given zone index
Types ¶
type FederatedNamespace ¶ added in v0.2.18
FederatedNamespace represents a namespace and service account pair to federate with the managed identity
func GenerateGatewayFederatedNamespaces ¶ added in v0.2.19
func GenerateGatewayFederatedNamespaces() []FederatedNamespace
GenerateGatewayFederatedNamespaces generates all FederatedNamespace entries needed for gateway tests
type Identifier ¶
type Identifier interface {
GetId() string
}
type LoadableProvisioned ¶
type LoadableProvisioned struct {
Name string
Cluster azure.Resource
ClusterLocation, ClusterDnsServiceIp, ClusterPrincipalId, ClusterClientId, ClusterOidcUrl string
ClusterOptions map[string]struct{}
ManagedIdentity azure.Resource
ManagedIdentityClientId string
ManagedIdentityPrincipalId string
ManagedIdentityZones []withLoadableCert[LoadableZone]
ManagedIdentityPrivateZones []withLoadableCert[azure.Resource]
ContainerRegistry azure.Resource
Zones []withLoadableCert[LoadableZone]
PrivateZones []withLoadableCert[azure.Resource]
KeyVault azure.Resource
ResourceGroup arm.ResourceID // rg id is a little weird and can't be correctly parsed by azure.Resource so we have to use arm.ResourceID
SubscriptionId string
TenantId string
E2eImage string
OperatorImage string
}
LoadableProvisioned is a struct that can be used to load a Provisioned struct from a file. Ensure that all fields are exported so that they can properly be serialized/deserialized.
func ToLoadable ¶
func ToLoadable(p []Provisioned) ([]LoadableProvisioned, error)
func (LoadableProvisioned) Provisioned ¶
func (l LoadableProvisioned) Provisioned() (Provisioned, error)
type LoadableZone ¶
type PrivateZone ¶
type PrivateZone interface {
GetDnsZone(ctx context.Context) (*armprivatedns.PrivateZone, error)
LinkVnet(ctx context.Context, linkName, vnetId string) error
GetName() string
Identifier
}
type Provisioned ¶
type Provisioned struct {
Name string
Cluster cluster
ContainerRegistry containerRegistry
ManagedIdentity managedIdentity
ManagedIdentityZones []WithCert[Zone]
ManagedIdentityPrivateZones []WithCert[PrivateZone]
Zones []WithCert[Zone]
PrivateZones []WithCert[PrivateZone]
KeyVault keyVault
ResourceGroup resourceGroup
SubscriptionId string
TenantId string
E2eImage string
OperatorImage string
}
func ToProvisioned ¶
func ToProvisioned(l []LoadableProvisioned) ([]Provisioned, error)
func (Provisioned) Loadable ¶
func (p Provisioned) Loadable() (LoadableProvisioned, error)
Click to show internal directories.
Click to hide internal directories.