com.vmware.vcenter.namespace_management package

Subpackages

Submodules

com.vmware.vcenter.namespace_management.clusters_client module

class com.vmware.vcenter.namespace_management.clusters_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

class com.vmware.vcenter.namespace_management.clusters_client.Topology(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The Topology class provides methods to query the topological layout of the infrastructure a Supervisor is running on. This class was added in vSphere API 8.0.0.1.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

get(cluster)

Queries the Supervisor ID that is currently running on the given vSphere Cluster ID, if there’s any. A Supervisor can be running on one or multiple vSphere Zones, and each vSphere Zone is associated with one or more vSphere Clusters. This method was added in vSphere API 8.0.0.1.

Parameters

cluster (str) – Identifier for a vSphere Cluster. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type

str

Returns

Identifier of the Supervisor associated with the given vSphere Cluster. The return value will be an identifier for the resource type: com.vmware.vcenter.consumption_domains.Zone.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if the given vSphere Cluster does not exist.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have Namespaces.Manage privilege and the System.Read privilege on all vSphere Clusters hosting the Supervisor.

com.vmware.vcenter.namespace_management.cns_client module

The com.vmware.vcenter.namespace_management.cns_client module provides classes for configuration of Persistent Services capabilities on VC clusters.

class com.vmware.vcenter.namespace_management.cns_client.MaintenanceActionType(string)

Bases: vmware.vapi.bindings.enum.Enum

The MaintenanceActionType class contains actions to be taken when an entity enters maintenance mode.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the MaintenanceActionType instance.

EnsureAccessibility = MaintenanceActionType(string='EnsureAccessibility')

The entity is going down temporarily for maintenance. Still need to ensure application availability and storage accessibility at least in a degraded level.

NoAction = MaintenanceActionType(string='NoAction')

Admin override to not delay or stop the entity from entering maintenance mode.

PermanentRemoval = MaintenanceActionType(string='PermanentRemoval')

The entity is getting permanently removed. Move applications, rebuild storage on other entities before allowing to proceed.

class com.vmware.vcenter.namespace_management.cns_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.vcenter.namespace_management.networks_client module

class com.vmware.vcenter.namespace_management.networks_client.IPAssignment(assignee=None, ranges=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

IPAssignment class is used to assign IP addresses to be used for various functions in a Supervisor Kubernetes Cluster. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • assignee (IPAssignment.Assignment or None) – IPAssignment.assignee is the role assignee for the given IP Ranges. This attribute was added in vSphere API 8.0.0.1. This field defaults to ANY.

  • ranges (list of IPRange) – IPAssignment.ranges lists the available IP addresses that can be consumed by Supervisor to run the cluster. This attribute was added in vSphere API 8.0.0.1.

class Assignment(string)

Bases: vmware.vapi.bindings.enum.Enum

IPAssignment.Assignment lists the different entities that require IP ranges. These assignments fulfill different needs in the Kubernetes environment. This enumeration was added in vSphere API 8.0.0.1.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the Assignment instance.

NODE = Assignment(string='NODE')

IPAssignment.Assignment.NODE represents IP ranges that is allocated to nodes for both the control plane and Tanzu Kubernetes Grid Clusters. This assignment is currently only applicable on VDS networks. This class attribute was added in vSphere API 8.0.0.1.

POD = Assignment(string='POD')

IPAssignment.Assignment.POD represents the IP address that is allocatable to Kubernetes Pods. This assignment is currently only applicable on NSX-T networks. This class attribute was added in vSphere API 8.0.0.1.

SERVICE = Assignment(string='SERVICE')

IPAssignment.Assignment.SERVICE represents the IP ranges that Kubernetes can use for its cluster IP addresses. Cluster IPs are internal to the cluster, but can be exposed via edge services such as load balancer, ingress, and egress. This class attribute was added in vSphere API 8.0.0.1.

class com.vmware.vcenter.namespace_management.networks_client.IPManagement(dhcp_enabled=None, gateway_address=None, ip_assignments=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

IPManagement class dictates IP addressing configuration for the network that hosts the Supervisor. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • dhcp_enabled (bool or None) – IPManagement.dhcp_enabled If set true, configures IP address using the DHCP server on the broadcast domain unless the corresponding IPManagement.ip_assignments are set. This attribute was added in vSphere API 8.0.0.1. If None this field defaults to true.

  • gateway_address (str or None) – IPManagement.gateway_address is the IP address combined with the subnet prefix length (e.g. 192.168.1.1/24) of the default gateway of this network. This attribute was added in vSphere API 8.0.0.1. If IPManagement.dhcp_enabled is not set, or this is an NSX network, this address must be set.

  • ip_assignments (list of IPAssignment or None) – IPManagement.ip_assignments are a list of roles that can be allocated to IP addresses. If IPManagement.gateway_address is specified, these assignments must be on the same subnet. This attribute was added in vSphere API 8.0.0.1. These assignments are optional when using DHCP.

class com.vmware.vcenter.namespace_management.networks_client.IPRange(address=None, count=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The IPRange class is used to express a range of IP addresses. The IP address supported by this structure will depend on the IP version that is being used by Supervisor.

Currently, the Supervisor only supports IPv4.. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • address (str) – IPRange.address is the starting IP address of the IPRange. This attribute was added in vSphere API 8.0.0.1.

  • count (long) –

    IPRange.count is number of IP addresses in the range.

    For example:

    A /24 subnet will have a count of 256.

    A /24 subnet with a gateway address and a broadcast address will have a count of 254.. This attribute was added in vSphere API 8.0.0.1.

class com.vmware.vcenter.namespace_management.networks_client.Services(dns=None, ntp=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

Services class describes services that assists applications in communicating on a network. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
class com.vmware.vcenter.namespace_management.networks_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.vcenter.namespace_management.software_client module

The com.vmware.vcenter.namespace_management.software_client module provides classes for managing namespaces software components.

class com.vmware.vcenter.namespace_management.software_client.Clusters(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The Clusters class provides methods to upgrade the vSphere clusters.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class Info(current_version=None, available_versions=None, last_upgraded_date=None, messages=None, state=None, upgrade_status=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Clusters.Info class contains detailed information about the cluster upgrade status and related information.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • current_version (str) – Current version of the cluster.

  • available_versions (list of str) – Set of available versions can be upgraded to.

  • last_upgraded_date (datetime.datetime or None) – Date of last successful upgrade. If None, the cluster has not yet been upgraded.

  • messages (list of Clusters.Message) – Current set of messages associated with the cluster version.

  • state (Clusters.State) – Current state of the upgrade.

  • upgrade_status (Clusters.UpgradeStatus or None) – Information about upgrade in progress. If None, the cluster upgrade is not in progress.

class Message(severity=None, details=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Clusters.Message class contains the information about the object configuration.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
class Severity(string)

Bases: vmware.vapi.bindings.enum.Enum

The Clusters.Message.Severity class represents the severity of the message.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the Severity instance.

ERROR = Severity(string='ERROR')

Error message. This is accompanied by vCenter event and/or alarm.

INFO = Severity(string='INFO')

Informational message. This may be accompanied by vCenter event.

WARNING = Severity(string='WARNING')

Warning message. This may be accompanied by vCenter event.

class Result(res=None, exception=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Clusters.Result class contains the result of batch upgrade method.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • res (Clusters.Result.Res) – The result of batch upgrade method.

  • exception (Exception) – Exception when cluster pre-check failed during upgrade invocation. This attribute is optional and it is only relevant when the value of res is Clusters.Result.Res.REJECTED.

class Res(string)

Bases: vmware.vapi.bindings.enum.Enum

The Clusters.Result.Res class represents the upgrade invocation result for each cluster.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the Res instance.

REJECTED = Res(string='REJECTED')

Upgrade is rejected. This implies pre-check failed when invoking upgrade of the cluster.

STARTED = Res(string='STARTED')

Upgrade is started.

class State(string)

Bases: vmware.vapi.bindings.enum.Enum

The Clusters.State class describes the state of the upgrade.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the State instance.

ERROR = State(string='ERROR')

Upgrade failed and need user intervention.

PENDING = State(string='PENDING')

Upgrade is in progress.

READY = State(string='READY')

Cluster is ready when there is no upgrade or upgrade is completed.

class Summary(cluster=None, cluster_name=None, current_version=None, available_versions=None, last_upgraded_date=None, desired_version=None, state=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Clusters.Summary class contains basic information about the cluster upgrade related information.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • cluster (str) – Identifier for the cluster. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: ClusterComputeResource. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: ClusterComputeResource.

  • cluster_name (str) – Name of the cluster. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: ClusterComputeResource.name. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: ClusterComputeResource.name.

  • current_version (str) – Current version of the cluster.

  • available_versions (list of str) – Set of versions available for upgrade.

  • last_upgraded_date (datetime.datetime or None) – Date of last successful upgrade. If None, the cluster has not yet been upgraded.

  • desired_version (str or None) – Desired version the cluster will be upgraded to. If None, the cluster upgrade is not in progress.

  • state (Clusters.State) – Current state of the upgrade.

class UpgradeProgress(total=None, completed=None, message=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Clusters.UpgradeProgress class contains detailed information about the cluster upgrade progess.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • total (long) – Total amount of the work for the operation. The work here represents the number of master nodes in the cluster need to be upgraded.

  • completed (long) – The amount of work completed for the operation. The value can only be incremented. The number or master nodes which upgrade completed.

  • message (com.vmware.vapi.std_client.LocalizableMessage) – Message about the work progress.

class UpgradeSpec(desired_version=None, ignore_precheck_warnings=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Clusters.UpgradeSpec class contains the specification required to upgrade a cluster.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • desired_version (str) – Version number the cluster is going to be upgraded to.

  • ignore_precheck_warnings (bool or None) – If true, the upgrade workflow will ignore any pre-check warnings and proceed with the upgrade. If None, the upgrade workflow will not ignore pre-check warnings and fail the upgrade. It is equivalent to setting the value to false. The workflow adopts a conservative approach of failing the upgrade if None to solely let the user decide whether to force the upgrade despite the warnings.

class UpgradeStatus(desired_version=None, messages=None, progress=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Clusters.UpgradeStatus class contains detailed information about the cluster when upgraded is in progress.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • desired_version (str or None) – Desired version the cluster will be upgraded to. If None, the cluster upgrade is not in progress.

  • messages (list of Clusters.Message) – Current set of messages associated with the upgrade state.

  • progress (Clusters.UpgradeProgress or None) – Information about upgrade progess. If None, the cluster upgrade is not in progress.

get(cluster)

Returns upgrade related information of a specific cluster.

Parameters

cluster (str) – Identifier for the cluster which will be upgraded. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type

Clusters.Info

Returns

Information about the upgrade of the specified WCP enabled cluster.

Raise

com.vmware.vapi.std.errors_client.NotFound if cluster could not be located.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have System.Read privilege.

Raise

com.vmware.vapi.std.errors_client.Unsupported if the cluster is not WCP enabled.

list()

Returns upgrade related information about all WCP enabled clusters.

Return type

list of Clusters.Summary

Returns

List of upgrade summary of all WCP enabled clusters.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have System.Read privilege.

upgrade(cluster, spec)

Upgrade the cluster to a specific version. This operation upgrades the components on control plane VMs and worker plane hosts based on the selected version. Before upgrading, this operation performs pre-checks and sets the evaluation response in Info.UpgradeStatus.messages with various Message.Severity levels. Depending on the severity, the upgrade may or may not proceed beyond prechecks. Here is a list of severities and corresponding behavior: - ERROR: Upgrade does not proceed beyond precheck operation - WARNING: Upgrade proceeds beyond precheck operation only if UpgradeSpec.ignorePrecheckWarnings is set to true - INFO: Upgrade proceeds beyond precheck operation uninterrupted

Parameters
  • cluster (str) – Identifier for the cluster which will be upgraded. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (Clusters.UpgradeSpec) – Specification for upgrading the cluster.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Unsupported if pre-check failed of the cluster.

Raise

com.vmware.vapi.std.errors_client.NotFound if cluster could not be located.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have Namespaces.Upgrade privilege.

upgrade_multiple(specs)

Upgrade a set of clusters to its corresponding specific version.

Parameters

specs (dict of str and Clusters.UpgradeSpec) – Specifications for upgrading selected clusters. The key in the parameter dict must be an identifier for the resource type: ClusterComputeResource.

Return type

dict of str and Clusters.Result

Returns

Pre-check result when invoking upgrade for each cluster. The key in the return value dict will be an identifier for the resource type: ClusterComputeResource.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have Namespaces.Upgrade privilege on all specified clusters.

class com.vmware.vcenter.namespace_management.software_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.vcenter.namespace_management.stats_client module

The com.vmware.vcenter.namespace_management.stats_client module provides classes for gathering statistics related to various Namespaces related components.

class com.vmware.vcenter.namespace_management.stats_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

class com.vmware.vcenter.namespace_management.stats_client.TimeSeries(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The TimeSeries class provides methods to gather statistical values for clusters, namespaces and pods.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class PodIdentifier(namespace=None, pod_name=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

Pod identifier. These are the fields required to uniquely identify a pod.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • namespace (str) – The namespace that the pod is running in. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance.

  • pod_name (str) – The name of the pod itself.

class Spec(obj_type=None, pod=None, namespace=None, cluster=None, start=None, end=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

This structure is sent in a request for TimeSeries data and is used to specify what object stats should be returned for.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • obj_type (TimeSeries.Spec.ObjType) – Type of statistics object that the request is operating on.

  • pod (TimeSeries.PodIdentifier) – Pod Identifier for queries on an individual pod. This attribute is optional and it is only relevant when the value of objType is TimeSeries.Spec.ObjType.POD.

  • namespace (str) – Namespace name for queries for a namespace. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance. This attribute is optional and it is only relevant when the value of objType is TimeSeries.Spec.ObjType.NAMESPACE.

  • cluster (str) – Cluster identifier for queries for a cluster. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: ClusterComputeResource. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: ClusterComputeResource. This attribute is optional and it is only relevant when the value of objType is TimeSeries.Spec.ObjType.CLUSTER.

  • start (long) – UNIX timestamp value indicating when the requested series of statistical samples should begin. https://en.wikipedia.org/wiki/Unix_time

  • end (long) – UNIX timestamp value indicating when the requested series of statistical samples should end. https://en.wikipedia.org/wiki/Unix_time

class ObjType(string)

Bases: vmware.vapi.bindings.enum.Enum

Type of statistics object that this request is operating on.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the ObjType instance.

CLUSTER = ObjType(string='CLUSTER')

The CLUSTER object type is used when specifying a vSphere cluster.

NAMESPACE = ObjType(string='NAMESPACE')

The NAMESPACE object type is used to specify a namespace.

POD = ObjType(string='POD')

The POD object type is used to specify an individual pod within a namespace.

class TimeSeries(counter=None, time_stamps=None, values=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

A set of timestamps and statistical values representing a time series. The lengths of TimeSeries.TimeSeries.time_stamps and TimeSeries.TimeSeries.values will always match each other.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • counter (str) – Counter identifier.

  • time_stamps (list of long) – Sequence of UNIX timestamp values at which statistical values were sampled. https://en.wikipedia.org/wiki/Unix_time

  • values (list of long) – Sequence of sampled values corresponding to the timestamps in tss.

get(spec)

Gather statistical values for a cluster, namespace, or pod.

Parameters

spec (TimeSeries.Spec) – Specification of the statistical values that should be returned.

Return type

list of TimeSeries.TimeSeries

Returns

A list of TimeSeries values for each counter specified in the request.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.InvalidArgument if the start time in TimeSeries.Spec.start is invalid, or the end time in TimeSeries.Spec.end is invalid.

Raise

com.vmware.vapi.std.errors_client.NotFound if the specified cluster in TimeSeries.Spec.cluster or the namespace in TimeSeries.Spec.namespace or TimeSeries.Spec.pod does not exist.

Raise

com.vmware.vapi.std.errors_client.Unsupported if the specified cluster in TimeSeries.Spec.cluster is not enabled for Namespaces.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have System.Read privilege.

com.vmware.vcenter.namespace_management.storage_client module

class com.vmware.vcenter.namespace_management.storage_client.Profiles(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The Profiles class provides methods to get storage profiles compatible with control plane VMDKs which can be used to enable a Supervisor. A storage profile is compatible if it results in at least one datastore in each of the specified zones. This class was added in vSphere API 8.0.0.1.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class FilterSpec(zones=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Profiles.FilterSpec class contains zones used to find compatible storage profiles. A storage profile is compatible if it results in at least one datastore in each of the specified zones. (see Profiles.check()). This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters

zones (list of str) – Zone compatibility criteria. The common storage profiles across the given zones will be returned. A storage profile is considered compatible if it results in at least one datastore in each of the given zones. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: com.vmware.vcenter.consumption_domains.Zone. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: com.vmware.vcenter.consumption_domains.Zone.

class Item(zone=None, datastores=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Profiles.Item class contains the datastores and vSphere Zone which they are in. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • zone (str) – The vSphere Zones the datastore are in. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.consumption_domains.Zone. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.consumption_domains.Zone.

  • datastores (list of str) – The datastores in the zone. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: Datastore. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: Datastore.

class Summary(profile=None, profile_name=None, compatible=None, items=None, incompatibility_reasons=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Profiles.Summary class contains the information about compatible storage profiles and represents the result of Profiles.check() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • profile (str) – Identifier of the compatible storage profile. A storage profile is compatible if it results in at least one datastore in each of the specified zones. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: SpsStorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: SpsStorageProfile.

  • profile_name (str) – Human-readable identifier of the storage profile. This attribute was added in vSphere API 8.0.0.1.

  • compatible (bool) – Compatibility of this storage profile with the specified vSphere Zones. This attribute was added in vSphere API 8.0.0.1.

  • items (list of Profiles.Item) – The list of Profiles.Item wich correspond to the storage profile. This attribute was added in vSphere API 8.0.0.1.

  • incompatibility_reasons (list of com.vmware.vapi.std_client.LocalizableMessage) – The reason for incompatibility. If empty, this profile is compatible with the given vSphere Zones specified in the Profiles.FilterSpec. This attribute was added in vSphere API 8.0.0.1.

check(filter)

Returns the compatible management storage profiles for enabling a WCP Supervisor across a given set of zones. A storage profile is compatible if it results in at least one datastore in each of the specified zones. This method was added in vSphere API 8.0.0.1.

Parameters

filter (Profiles.FilterSpec) – Specification of the zones to consider when finding compatible storage profiles. The Profiles.FilterSpec must contain at least 1 zone.

Return type

list of Profiles.Summary

Returns

List of storage profiles compatible across the given Profiles.FilterSpec. The profiles returned will each result in at least one datastore in each zone.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.InvalidArgument if one or more fields of the Profiles.FilterSpec is incorrect.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have System.Read privilege on all of the Cluster Compute Resources in the specified vSphere Zones.

class com.vmware.vcenter.namespace_management.storage_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

com.vmware.vcenter.namespace_management.supervisor_services_client module

The com.vmware.vcenter.namespace_management.supervisor_services_client module provides classes for managing supervisor services that are extensions to the Supervisor.

class com.vmware.vcenter.namespace_management.supervisor_services_client.ClusterSupervisorServices(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The ClusterSupervisorServices class provides methods to manage a Supervisor Service on the vSphere Supervisors. This class was added in vSphere API 7.0.3.0.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ConfigStatus(string)

Bases: vmware.vapi.bindings.enum.Enum

The ClusterSupervisorServices.ConfigStatus class describes the status of reaching the desired state configuration for the Supervisor Service. This enumeration was added in vSphere API 7.0.3.0.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the ConfigStatus instance.

CONFIGURED = ConfigStatus(string='CONFIGURED')

The Supervisor Service has been configured correctly (i.e. the provided YAML content has been applied successfully to the cluster). This class attribute was added in vSphere API 7.0.3.0.

CONFIGURING = ConfigStatus(string='CONFIGURING')

The Supervisor Service is being installed. This class attribute was added in vSphere API 7.0.3.0.

ERROR = ConfigStatus(string='ERROR')

Failed to install the Supervisor Service, user intervention needed. This class attribute was added in vSphere API 7.0.3.0.

REMOVING = ConfigStatus(string='REMOVING')

The Supervisor Service is being deleted. This class attribute was added in vSphere API 7.0.3.0.

class CreateSpec(supervisor_service=None, version=None, service_config=None, yaml_service_config=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ClusterSupervisorServices.CreateSpec class provides a specification required to create a Supervisor Service on a vSphere Supervisor. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • supervisor_service (str) – Identifier of the Supervisor Service. This Supervisor Service must be in the ACTIVATED state. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • version (str) – Identifier of the Supervisor Service version which contains the service definition. This Supervisor Service version must be in the ACTIVATED state. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

  • service_config ((dict of str and str) or None) – A generic key-value map for additional configuration parameters required during service creation. As an example, a third party operator might reference a private registry using parameters such as “registryName” for the registry name, “registryUsername” and “registryPassword” for the registry credentials. This attribute was added in vSphere API 7.0.3.0. If None, no additional configuration parameters will be applied when installing a Supervisor Service in the vSphere Supervisor.

  • yaml_service_config (str or None) –

    A set of additional configuration parameters to be applied during service creation. These parameters should be formatted as a base64 encoded YAML document.

    Parameters should be set in at most one of serviceConfig or yamlServiceConfig, and not both. The yamlServiceConfig supports complex data types and nested properties.. This attribute was added in vSphere API 8.0.0.1. If None, no additional configuration parameters will be applied when installing a Supervisor Service in the vSphere Supervisor.

class Info(desired_version=None, service_namespace=None, config_status=None, messages=None, current_version=None, display_name=None, description=None, prefix=None, yaml_service_config=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ClusterSupervisorServices.Info class contains the detailed information about a Supervisor Service on the vSphere Supervisor. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • desired_version (str) – The desired version of this Supervisor Service. This attribute was added in vSphere API 7.0.3.0.

  • service_namespace (str or None) – Identifier of the namespace to allocate the Supervisor Service’s operators. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespaces.Instance. If None, there is an error when creating the service namespace or the namespace has not been created yet.

  • config_status (ClusterSupervisorServices.ConfigStatus) – Current setting for ClusterSupervisorServices.ConfigStatus. This attribute was added in vSphere API 7.0.3.0.

  • messages (list of ClusterSupervisorServices.Message) – Current set of messages associated with the Supervisor Service on the vSphere Supervisor. This attribute was added in vSphere API 7.0.3.0.

  • current_version (str or None) – The current version for the Supervisor Service. This attribute was added in vSphere API 7.0.3.0. If None, there is no version installed for the Supervisor Service.

  • display_name (str) – A human readable name of the Supervisor Service. This attribute was added in vSphere API 7.0.3.0.

  • description (str or None) – A human readable description of the Supervisor Service. This attribute was added in vSphere API 7.0.3.0. If None, the description for the service version is empty.

  • prefix (str or None) – The prefix that will be added to the names of the Supervisor Service’s kubernetes resources. This attribute was added in vSphere API 7.0.3.0. If None, the prefix is not assigned yet.

  • yaml_service_config (str or None) – The configuration parameters applied on this Supervisor Service, formatted as a base64 encoded YAML document. Any configuration that has been set will be returned as base64 encoded YAML, including the serviceConfig. This attribute was added in vSphere API 8.0.0.1. If None, the Supervisor Service has no configuration applied.

class Message(severity=None, details=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ClusterSupervisorServices.Message class contains the information about the Supervisor Service configuration on a vSphere Supervisor. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
class MessageSeverity(string)

Bases: vmware.vapi.bindings.enum.Enum

The ClusterSupervisorServices.Message.MessageSeverity class represents the severity of the message. This enumeration was added in vSphere API 7.0.3.0.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the MessageSeverity instance.

ERROR = MessageSeverity(string='ERROR')

Error message. This is accompanied by vCenter event and/or alarm. This class attribute was added in vSphere API 7.0.3.0.

INFO = MessageSeverity(string='INFO')

Informational message. This may be accompanied by vCenter event. This class attribute was added in vSphere API 7.0.3.0.

WARNING = MessageSeverity(string='WARNING')

Warning message. This may be accompanied by vCenter event. This class attribute was added in vSphere API 7.0.3.0.

class SetSpec(version=None, service_config=None, yaml_service_config=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ClusterSupervisorServices.SetSpec class provides a specification required to set a new configuration on a Supervisor Service in a vSphere Supervisor. This class is applied in entirety, replacing the current specification fully. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • version (str) – Identifier of the Supervisor Service version which contains the service definition. This Supervisor Service version must be in the ACTIVATED state. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

  • service_config ((dict of str and str) or None) – A generic key-value map for additional configuration parameters required during service upgrade. As an example, a third party operator might reference a private registry using parameters such as “registryName” for the registry name, “registryUsername” and “registryPassword” for the registry credentials. This attribute was added in vSphere API 7.0.3.0. If None, no additional configuration parameters will be applied when upgrading a Supervisor Service in the vSphere Supervisor.

  • yaml_service_config (str or None) –

    A set of additional configuration parameters to be applied during service upgrade. These parameters should be formatted as a base64 encoded YAML document.

    Parameters should be set in at most one of serviceConfig or yamlServiceConfig, and not both. The yamlServiceConfig supports complex data types and nested properties.. This attribute was added in vSphere API 8.0.0.1. If None, no additional configuration parameters will be applied when upgrading a Supervisor Service in the vSphere Supervisor.

class Summary(supervisor_service=None, desired_version=None, config_status=None, current_version=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ClusterSupervisorServices.Summary class contains the basic information about a Supervisor Service on the vSphere Supervisor. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • supervisor_service (str) – The identifier of the Supervisor Service. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • desired_version (str) – The desired version of this Supervisor Service. This attribute was added in vSphere API 7.0.3.0.

  • config_status (ClusterSupervisorServices.ConfigStatus) – Current setting for ClusterSupervisorServices.ConfigStatus. This attribute was added in vSphere API 7.0.3.0.

  • current_version (str or None) – The current version for the Supervisor Service. This attribute was added in vSphere API 7.0.3.0. If None, there is no version installed for the Supervisor Service.

create(cluster, spec)

Create a Supervisor Service on the specified vSphere Supervisor. This method will apply the Supervisor Service version’s service definition on the cluster. This method is possible only when the Supervisor Service and Supervisor Service version are in the ACTIVATED state. A Supervisor can be running on one or multiple vSphere Zones, and each vSphere Zone is associated with one or more vSphere Clusters. If a Supervisor running on the specified vSphere Cluster is running on additional vSphere Clusters, this operation will apply to Supervisor components running on the other vSphere Clusters in addition to the specified vSphere Cluster. To call this API on a Supervisor with multiple vSphere Clusters, use com.vmware.vcenter.namespace_management.supervisors.Topology#get to get the vSphere Clusters associated with the given Supervisor. Any cluster from the list returned can be used as the input of this API. This method was added in vSphere API 7.0.3.0.

Parameters
  • cluster (str) – Identifier for the Supervisor on which to create the service. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • spec (ClusterSupervisorServices.CreateSpec) – Specification for the Supervisor Service on the cluster.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.InvalidArgument if spec contains any errors.

Raise

com.vmware.vapi.std.errors_client.AlreadyExists if a Supervisor Service ID defined in spec exists on the Supervisor

Raise

com.vmware.vapi.std.errors_client.NotFound if the specified cluster with ID cluster or Supervisor Service with the Supervisor Service ID defined in spec or version with the ID {param.name version} could not be located.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor doesn’t support Supervisor Services, or if the Supervisor Service cannot be created in the current state, e.g. the supervisor service version is in the DEACTIVATED state.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have the SupervisorServices.Manage privilege on the specified cluster.

delete(cluster, supervisor_service)

Delete a Supervisor Service on the specified vSphere Supervisor. This method will remove the Supervisor Service with the specified identifier from the cluster, by removing the corresponding namespace and deleting the operator(s) associated with the Supervisor Service. Note that this operation doesn’t deal with the application instances that are created by the associated operator(s), so existing application instances could be orphaned if users don’t clean or migrate them. A Supervisor can be running on one or multiple vSphere Zones, and each vSphere Zone is associated with one or more vSphere Clusters. If a Supervisor running on the specified vSphere Cluster is running on additional vSphere Clusters, this operation will apply to Supervisor components running on the other vSphere Clusters in addition to the specified vSphere Cluster. To call this API on a Supervisor with multiple vSphere Clusters, use com.vmware.vcenter.namespace_management.supervisors.Topology#get to get the vSphere Clusters associated with the given Supervisor. Any cluster from the list returned can be used as the input of this API. This method was added in vSphere API 7.0.3.0.

Parameters
  • cluster (str) – Identifier for the Supervisor from which to delete the service. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • supervisor_service (str) – Identifier for the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor with the ID cluster or the Supervisor Service does not exist on the Supervisor.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor doesn’t support Supervisor Services.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have the SupervisorServices.Manage privilege on the specified cluster.

get(cluster, supervisor_service)

Return information about the specific Supervisor Service on the specified vSphere Supervisor. A Supervisor can be running on one or multiple vSphere Zones, and each vSphere Zone is associated with one or more vSphere Clusters. If a Supervisor running on the specified vSphere Cluster is running on additional vSphere Clusters, this operation will apply to Supervisor components running on the other vSphere Clusters in addition to the specified vSphere Cluster. To call this API on a Supervisor with multiple vSphere Clusters, use com.vmware.vcenter.namespace_management.supervisors.Topology#get to get the vSphere Clusters associated with the given Supervisor. Any cluster from the list returned can be used as the input of this API. This method was added in vSphere API 7.0.3.0.

Parameters
  • cluster (str) – Identifier for the cluster on which to get the service. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • supervisor_service (str) – Identifier for the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

Return type

ClusterSupervisorServices.Info

Returns

The information for the specified Supervisor Service on the specified cluster.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor with the ID cluster or the Supervisor Service does not exist on the Supervisor.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor doesn’t support Supervisor Services.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have the SupervisorServices.Manage privilege on the specified cluster.

list(cluster)

Return the summaries about all Supervisor Services on the specified vSphere Supervisor. A Supervisor can be running on one or multiple vSphere Zones, and each vSphere Zone is associated with one or more vSphere Clusters. If a Supervisor running on the specified vSphere Cluster is running on additional vSphere Clusters, this operation will apply to Supervisor components running on the other vSphere Clusters in addition to the specified vSphere Cluster. To call this API on a Supervisor with multiple vSphere Clusters, use com.vmware.vcenter.namespace_management.supervisors.Topology#get to get the vSphere Clusters associated with the given Supervisor. Any cluster from the list returned can be used as the input of this API. This method was added in vSphere API 7.0.3.0.

Parameters

cluster (str) – Identifier for the cluster on which to list the services. The parameter must be an identifier for the resource type: ClusterComputeResource.

Return type

list of ClusterSupervisorServices.Summary

Returns

The list of summaries of all Supervisor Services on the cluster.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor with the ID cluster could not be located.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor doesn’t support Supervisor Services.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have the SupervisorServices.Manage privilege on the specified cluster.

set(cluster, supervisor_service, spec)

Set a new configuration to the specified Supervisor Service on the specified vSphere Supervisor. This method will apply the new Supervisor Service version’s service definition to the existing Supervisor Service on the cluster. This method requires that the specified Supervisor Service is already installed in the specified Supervisor. Note that this operation doesn’t interfere with the application instances that are created by the associated operator(s). So users should make sure the new version is still compatible with the existing application instances. A Supervisor can be running on one or multiple vSphere Zones, and each vSphere Zone is associated with one or more vSphere Clusters. If a Supervisor running on the specified vSphere Cluster is running on additional vSphere Clusters, this operation will apply to Supervisor components running on the other vSphere Clusters in addition to the specified vSphere Cluster. To call this API on a Supervisor with multiple vSphere Clusters, use com.vmware.vcenter.namespace_management.supervisors.Topology#get to get the vSphere Clusters associated with the given Supervisor. Any cluster from the list returned can be used as the input of this API. This method was added in vSphere API 7.0.3.0.

Parameters
  • cluster (str) – Identifier for the Supervisor from which to delete the service. The parameter must be an identifier for the resource type: ClusterComputeResource.

  • supervisor_service (str) – Identifier for the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • spec (ClusterSupervisorServices.SetSpec) – Specification for the Supervisor Service on the cluster.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.InvalidArgument if spec contains any errors.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor with the ID cluster or Supervisor Service with the ID supervisor_service or version with the ID {param.name version} could not be located, or the Supervisor Service does not exist on the Supervisor.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor doesn’t support Supervisor Services or the specified version is not in the ACTIVATED state.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have the SupervisorServices.Manage privilege on the specified cluster.

class com.vmware.vcenter.namespace_management.supervisor_services_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

class com.vmware.vcenter.namespace_management.supervisor_services_client.Versions(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The Versions class provides methods to manage a version object of a Supervisor Service. A Supervisor Service version can be enabled on the vSphere Supervisor. This class was added in vSphere API 7.0.3.0.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class CarvelCreateSpec(content=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Versions.CarvelCreateSpec class provides a specification required to create a Supervisor Service version from Carvel application package format (Package and PackageMetadata resources should be declared). This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters

content (str) – Inline content that contains all service definition of the version in Carvel application package format, which shall be base64 encoded. This attribute was added in vSphere API 8.0.0.1.

class ContentType(string)

Bases: vmware.vapi.bindings.enum.Enum

The Versions.ContentType class defines the type of content that describes the format of Supervisor Service version definition. This enumeration was added in vSphere API 7.0.3.0.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the ContentType instance.

CARVEL_APPS_YAML = ContentType(string='CARVEL_APPS_YAML')

The Supervisor Service version definition is provided as inline YAML document that follows the Carvel application package format. This class attribute was added in vSphere API 8.0.0.1.

CUSTOM_YAML = ContentType(string='CUSTOM_YAML')

The Supervisor Service version definition is provided as inline YAML document that follows a plain Kubernetes YAML format. This class attribute was added in vSphere API 7.0.3.0.

VSPHERE_APPS_YAML = ContentType(string='VSPHERE_APPS_YAML')

The Supervisor Service version definition is provided as inline YAML document that follows the vSphere application service format. This class attribute was added in vSphere API 7.0.3.0.

class CreateSpec(custom_spec=None, vsphere_spec=None, carvel_spec=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Versions.CreateSpec class provides a specification required to create a Supervisor Service version. Exactly one of Versions.CreateSpec.custom_spec or Versions.CreateSpec.vsphere_spec must be set. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • custom_spec (Versions.CustomCreateSpec or None) –

    The specification required to create a Supervisor Service version from inline content that is based on a plain Kubernetes YAML format.

    . This attribute was added in vSphere API 7.0.3.0. If set, the service version will be created from inline content based on a plain Kubernetes YAML format.

  • vsphere_spec (Versions.VsphereCreateSpec or None) –

    The specification required to create a Supervisor Service version from inline content that is based on the vSphere application service format.

    . This attribute was added in vSphere API 7.0.3.0. If set, the service version will be created from inline content based on the vSphere application service format.

  • carvel_spec (Versions.CarvelCreateSpec or None) –

    The specification required to create a Supervisor Service version from inline content that is based on the Carvel application package format.

    . This attribute was added in vSphere API 8.0.0.1. If set, the service version will be created from inline content based on the Carvel application package format (Package and PackageMetadata resources should be declared).

class CustomCreateSpec(version=None, display_name=None, description=None, content=None, trusted_provider=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Versions.CustomCreateSpec class provides a specification required to create a Supervisor Service version from a plain Kubernetes YAML format. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • version (str) – The identifier of the Supervisor Service version. This must be a semantic version. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

  • display_name (str) – A human readable name of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0.

  • description (str or None) – A human readable description of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0. If None, the description for the service version will be empty.

  • content (str) – Inline content that contains all service definition of the version, which shall be base64 encoded. The service definition here follows a plain Kubernetes YAML format. This attribute was added in vSphere API 7.0.3.0.

  • trusted_provider (bool or None) – Whether or not the Supervisor Service version is from a trusted provider, this field must be set to false if the service version is not from a trusted provider. If it is set to be true, but the content is not signed or the signature is invalid, an InvalidArgument will be thrown. This attribute was added in vSphere API 7.0.3.0. If None, the default value is true. In this case, the content must be signed and will be verified.

class Info(display_name=None, description=None, eula=None, content_type=None, content=None, trust_verified=None, state=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Versions.Info class contains detailed information about a Supervisor Service version. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • display_name (str) – The human readable name of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0.

  • description (str or None) – A human-readable description of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0. If None, no description is available for the Supervisor Service version.

  • eula (str or None) – The End User License Agreement (EULA) associated with the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0. If None, no EULA is available for the Supervisor Service version.

  • content_type (Versions.ContentType) – The content type of content. This attribute was added in vSphere API 7.0.3.0.

  • content (str or None) – Inline content that contains base64 encoded service definition for the version. This attribute was added in vSphere API 7.0.3.0. If None, no content is available for the Supervisor Service version.

  • trust_verified (bool) – If true, the Supervisor Service version is from trusted provider and the trust is verified. This attribute was added in vSphere API 7.0.3.0.

  • state (Versions.State) – The current Versions.State of the version. This attribute was added in vSphere API 7.0.3.0.

class State(string)

Bases: vmware.vapi.bindings.enum.Enum

The Versions.State class defines the state of a Supervisor Service version. This enumeration was added in vSphere API 7.0.3.0.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the State instance.

ACTIVATED = State(string='ACTIVATED')

The is the default state of a Supervisor Service version upon creation. In this state, all operations on the version should work as normal. This class attribute was added in vSphere API 7.0.3.0.

DEACTIVATED = State(string='DEACTIVATED')

The is the deactivated state of a Supervisor Service version. In this state, certain operations on the version are disallowed, for example, the version cannot be created on the vSphere Supervisor clusters. This class attribute was added in vSphere API 7.0.3.0.

class Summary(version=None, display_name=None, state=None, description=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Versions.Summary class contains the basic information about a Supervisor Service version. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • version (str) – The identifier of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

  • display_name (str) – A human readable name of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0.

  • state (Versions.State) – The current Versions.State of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0.

  • description (str or None) – A human readable description of the Supervisor Service version. This attribute was added in vSphere API 7.0.3.0. If None, no description is available for the service version.

class VsphereCreateSpec(content=None, trusted_provider=None, accept_eula=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Versions.VsphereCreateSpec class provides a specification required to create a Supervisor Service version from vSphere application service format, which shall contain the Supervisor Service identifier, version identifier, display name and description information. This class was added in vSphere API 7.0.3.0.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • content (str) – Inline content that contains all service definition of the version in vSphere application service format, which shall be base64 encoded. This attribute was added in vSphere API 7.0.3.0.

  • trusted_provider (bool or None) – Whether or not the Supervisor Service version is from a trusted provider, this field must be set to false if the service version is not from a trusted provider. If it is set to be true, but the content is not signed or the signature is invalid, an InvalidArgument will be thrown. This attribute was added in vSphere API 7.0.3.0. If None, the default value is true. In this case, the content must be signed and will be verified.

  • accept_eula (bool or None) – Whether or not the End User License Agreement (EULA) that is specified in the content is accepted. If a EULA is specified, this attribute must be set to be true so that the Supervisor Service version can be created. This attribute was added in vSphere API 7.0.3.0. If None, the default value is false.

activate(supervisor_service, version)

Activate a Supervisor Service version. This method will change the Versions.State of the version to ACTIVATED state. This method was added in vSphere API 7.0.3.0.

Parameters
  • supervisor_service (str) – Identifier for the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • version (str) – Identifier of the version. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor Service version cannot be activated in the current state, for example, the Supervisor Service is in DEACTIVATED state.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor Service with the ID supervisor_service or version with the ID {param.name version} could not be located.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have the SupervisorServices.Manage privilege.

create(supervisor_service, spec)

Create a Supervisor Service version based on the provided service definition information for the version. This method was added in vSphere API 7.0.3.0.

Parameters
  • supervisor_service (str) – Identifier of the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • spec (Versions.CreateSpec) – Specification for the Supervisor Service version to be created.

Raise

com.vmware.vapi.std.errors_client.AlreadyExists if a Supervisor Service version with the same identifier already exists.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.InvalidArgument if an invalid field in spec is specified or if it contains any errors. For example, when the field trusted is set to be true, but no signature is provided or it is invalid or when a EULA is specified but not accepted.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor Service version cannot be created in the current state, for example, the Supervisor Service is in DEACTIVATED state.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor Service with the ID supervisor_service could not be located.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the SupervisorServices.Manage privilege.

deactivate(supervisor_service, version)

Deactivate a Supervisor Service version. This method will change the Versions.State of the version to DEACTIVATED state, which will make sure the version cannot be created on any Supervisor cluster. Note that this method should be called before deleting the version. This method was added in vSphere API 7.0.3.0.

Parameters
  • supervisor_service (str) – Identifier for the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • version (str) – Identifier of the version. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor Service version cannot be deactivated in the current state, for example, the Supervisor Service is in ACTIVATED state and this version is the last version of the Supervisor Service in ACTIVATED state.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor Service with the ID supervisor_service or version with the ID version could not be located.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have the SupervisorServices.Manage privilege.

delete(supervisor_service, version)

Delete a Supervisor Service version. This method only deletes the Supervisor Service version from vCenter if the version is in DEACTIVATED state and all instances of the version are removed from all Supervisors. Note that the deactivate method should be called to deactivate the version before the version can be deleted.

Note that deleting the last version of the supervisor_service does not delete the supervisor_service instance automatically.. This method was added in vSphere API 7.0.3.0.

Parameters
  • supervisor_service (str) – Identifier of the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • version (str) – Identifier of the version. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request, e.g. if it is unable to reach a vSphere Supervisor that has the version enabled.

Raise

com.vmware.vapi.std.errors_client.NotAllowedInCurrentState if the Supervisor Service version cannot be deleted in the current state, e.g. the version is not in DEACTIVATED state.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor Service with the ID supervisor_service or version with the ID {param.name version} could not be located.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the SupervisorServices.Manage privilege.

get(supervisor_service, version)

Return the information for the specified Supervisor Service version. This method was added in vSphere API 7.0.3.0.

Parameters
  • supervisor_service (str) – Identifier of the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

  • version (str) – Identifier of the version. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor_services.Version.

Return type

Versions.Info

Returns

Information for the specified Supervisor Service version.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if Supervisor Service with the ID supervisor_service or version with the ID {param.name version} could not be located.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the System.Read privilege.

list(supervisor_service)

Return the information about all versions of the Supervisor Service. This method was added in vSphere API 7.0.3.0.

Parameters

supervisor_service (str) – Identifier of the Supervisor Service. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.SupervisorService.

Return type

list of Versions.Summary

Returns

The list of summary of all service versions of the Supervisor Service.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if service with the ID supervisor_service could not be located.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user doesn’t have the System.Read privilege.

com.vmware.vcenter.namespace_management.supervisors_client module

The com.vmware.vcenter.namespace_management.supervisors_client module provides classes for operating a Supervisor.

class com.vmware.vcenter.namespace_management.supervisors_client.CNSFileConfig(vsan_clusters=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The CNSFileConfig class contains the specification required to set the configuration for Cloud Native Storage file volume support on Supervisor. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters

vsan_clusters (list of str) –

CNSFileConfig.vsan_clusters is a list of clusters to be used for provisioning file volumes.

As a prerequisite these clusters must have vSAN and vSAN file services enabled, and must be in the same vCenter as the Supervisor.

Currently this list must have a single entry which is the cluster identifier of the current cluster. This cluster must be a vSAN cluster and must have vSAN File Service enabled.

If a cluster in the list is not a vSAN cluster or does not have vSAN File Service enabled, an InvalidArgument error will be thrown from com.vmware.vcenter.namespace_management_client.Clusters.enable(), com.vmware.vcenter.namespace_management_client.Clusters.update() and com.vmware.vcenter.namespace_management_client.Clusters.set() APIs.

An empty list may be specified to disable file volume support on the Supervisor.. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: ClusterComputeResource. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: ClusterComputeResource.

class com.vmware.vcenter.namespace_management.supervisors_client.Conditions(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The Conditions class provides methods to retrieve conditions related to a particular Supervisor. This class was added in vSphere API 8.0.0.1.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class Condition(type=None, description=None, status=None, last_transition_time=None, reason=None, severity=None, messages=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Conditions.Condition class defines an observation of the configuration state of a Supervisor. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • type (str) – The type of the condition is a CamelCase, machine readable identifier, indicating the configuration stage. InfrastructureInitialized, ControlPlaneVMsDeployed and ControlPlaneVMsConfigured are examples of such identifiers. This attribute was added in vSphere API 8.0.0.1.

  • description (com.vmware.vapi.std_client.LocalizableMessage) – Description of the condition type in a human readable format. This attribute was added in vSphere API 8.0.0.1.

  • status (Conditions.Condition.Status) – The status of the condition. This attribute was added in vSphere API 8.0.0.1.

  • last_transition_time (datetime.datetime or None) – Last time the condition transitioned from one state to another. A transition happens when the value of status or severity field changes. This attribute was added in vSphere API 8.0.0.1. if None, there are no ongoing operations related to bringing the condition to the desired state.

  • reason (str) – A brief CamelCase message indicating details about the reason for the last transition. FailedWithSystemError, ManagementDNSServersMissing and WaitForNodeUpgrade are examples of such messages. This attribute was added in vSphere API 8.0.0.1.

  • severity (Conditions.Severity) – Provides an explicit classification of the reason identifier. Can be set when the value of status is not TRUE. This attribute was added in vSphere API 8.0.0.1.

  • messages (list of Conditions.Message) – A list of human-readable messages that provide additional details about the last transition. This attribute was added in vSphere API 8.0.0.1.

class Status(string)

Bases: vmware.vapi.bindings.enum.Enum

Status of the condition, which can be one of TRUE, FALSE or UNKNOWN. This enumeration was added in vSphere API 8.0.0.1.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the Status instance.

FALSE = Status(string='FALSE')

Indicates that the condition has not reached the desired state. This class attribute was added in vSphere API 8.0.0.1.

TRUE = Status(string='TRUE')

Indicates that the condition has reached the desired state. This class attribute was added in vSphere API 8.0.0.1.

UNKNOWN = Status(string='UNKNOWN')

Indicates that the status of the condition can not be determined. This class attribute was added in vSphere API 8.0.0.1.

class Message(severity=None, details=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Conditions.Message class contains user-readable information related to a Conditions.Condition. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
class Severity(string)

Bases: vmware.vapi.bindings.enum.Enum

The Conditions.Severity class represents the severity of the message. This enumeration was added in vSphere API 8.0.0.1.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the Severity instance.

ERROR = Severity(string='ERROR')

Error message. This class attribute was added in vSphere API 8.0.0.1.

INFO = Severity(string='INFO')

Informational message. This class attribute was added in vSphere API 8.0.0.1.

WARNING = Severity(string='WARNING')

Warning message. This class attribute was added in vSphere API 8.0.0.1.

get(supervisor)

Get all conditions of a given Supervisor. This method was added in vSphere API 8.0.0.1.

Parameters

supervisor (str) – the identifier for a Supervisor. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor.Supervisor.

Return type

list of Conditions.Condition

Returns

List of Conditions.Condition objects related to the given Supervisor.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if authorization information cannot be retrieved.

Raise

com.vmware.vapi.std.errors_client.NotFound if the Supervisor cannot be found, or if the user does not have read privilege on it.

class com.vmware.vcenter.namespace_management.supervisors_client.ControlPlane(network=None, login_banner=None, size=None, storage_policy=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

ControlPlane class describes the control plane configuration. It allows you to adjust configuration such as size, network, and storage required to support the control plane runtime.. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • network (com.vmware.vcenter.namespace_management.supervisors.networks.management_client.Network) –

    The management ControlPlane.network is used by vCenter and the control plane to manage the cluster. vCenter and the NSX (if used) management plane must be accessible from this network.

    The Supervisor requires that management network traffic is not L3 routable from workload network traffic.. This attribute was added in vSphere API 8.0.0.1.

  • login_banner (str or None) – ControlPlane.login_banner is a disclaimer displayed prior to login via the Kubectl plugin.. This attribute was added in vSphere API 8.0.0.1. If this banner is None, no message will be displayed to users.

  • size (SizingHint or None) – ControlPlane.size controls the size and resources allocated to the Kubernetes API server and the worker nodes.. This attribute was added in vSphere API 8.0.0.1. Defaults to SMALL.

  • storage_policy (str or None) – ControlPlane.storage_policy identifies the storage policy backing the Supervisor Kubernetes API server.. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: SpsStorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: SpsStorageProfile. This resource is required.

class com.vmware.vcenter.namespace_management.supervisors_client.ImageRegistry(hostname=None, port=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The ImageRegistry class contains the specification required to configure container image registry endpoint. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • hostname (str) – IP address or the hostname of container image registry. This attribute was added in vSphere API 8.0.0.1.

  • port (long or None) – Port number of the container image registry. This attribute was added in vSphere API 8.0.0.1. If None, defaults to 443.

class com.vmware.vcenter.namespace_management.supervisors_client.ImageSyncConfig(registry=None, repository=None, kubernetes_content_library=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

ImageSyncConfig class describes how the Supervisor Cluster and Kubernetes retrieves VM and container images that will run on the cluster. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • registry (ImageRegistry or None) – The ImageSyncConfig.registry class contains the specification required to configure container image registry endpoint. This attribute was added in vSphere API 8.0.0.1. Defaults to Docker Hub if None.

  • repository (str or None) –

    The ImageSyncConfig.repository specifies the default container image repository to use when the Kubernetes Pod specification does not specify it. For example, hub.docker.com is the image repository for a Pod whose image specification is hub.docker.com/nginx.. This attribute was added in vSphere API 8.0.0.1. If None, and if docker hub is the configured ImageSyncConfig.registry, then ImageSyncConfig.repository defaults to Docker Hub. If Docker Hub is not the configured image registry, ImageSyncConfig.repository remains unset.

    If {#member} repository is None, you must supply an image repository in your Pod spec or else images will not be able to be synced into the cluster.

  • kubernetes_content_library (str or None) –

    ImageSyncConfig.kubernetes_content_library is the UUID of the Content Library which holds the VM Images for Tanzu Kubernetes Service for vSphere.

    This Content Library should be subscribed to VMware’s hosted vSphere Kubernetes Service Repository. Optionally, you can configure your own local content library and host images locally.. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.content.Library. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.content.Library. If the Content Library identifier is None, you will not be able to deploy Tanzu Kubernetes Clusters.

class com.vmware.vcenter.namespace_management.supervisors_client.KubeAPIServerOptions(security=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

KubeAPIServerOptions declares options for the Kubernetes API Server.

The API server is used to manage workloads on the workload network.. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters

security (KubeAPIServerSecurity or None) – KubeAPIServerOptions.security allows you to specify configuration options for the API server security.. This attribute was added in vSphere API 8.0.0.1. If None, default security parameters will be configured.

class com.vmware.vcenter.namespace_management.supervisors_client.KubeAPIServerSecurity(certificate_dns_names=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

KubeAPIServerSecurity class declares security options configured on the Kubernetes API server. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters

certificate_dns_names (list of str) –

KubeAPIServerSecurity.certificate_dns_names lists additional DNS names to associate with the Kubernetes API server.

These DNS names are embedded in the TLS certificate presented by the API server as subject alternative names, which can be used in conjunction with your DNS server to securely connect a client to the server.. This attribute was added in vSphere API 8.0.0.1.

class com.vmware.vcenter.namespace_management.supervisors_client.SizingHint(string)

Bases: vmware.vapi.bindings.enum.Enum

The SizingHint class determines the configuration of Kubernetes API server and the worker nodes. It also determines the default values associated with the maximum number of pods and services. Use com.vmware.vcenter.namespace_management_client.ClusterSizeInfo.get() to get information associated with a SizingHint. This enumeration was added in vSphere API 8.0.0.1.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the SizingHint instance.

LARGE = SizingHint(string='LARGE')

Cluster size of ‘large’. This class attribute was added in vSphere API 8.0.0.1.

MEDIUM = SizingHint(string='MEDIUM')

Cluster size of ‘medium’. This class attribute was added in vSphere API 8.0.0.1.

SMALL = SizingHint(string='SMALL')

Cluster size of ‘small’. This class attribute was added in vSphere API 8.0.0.1.

TINY = SizingHint(string='TINY')

Cluster size of ‘tiny’. This class attribute was added in vSphere API 8.0.0.1.

class com.vmware.vcenter.namespace_management.supervisors_client.StubFactory(stub_config)

Bases: vmware.vapi.bindings.stub.StubFactoryBase

Initialize StubFactoryBase

Parameters

stub_config (vmware.vapi.bindings.stub.StubConfiguration) – Stub config instance

class com.vmware.vcenter.namespace_management.supervisors_client.Summary(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The Summary class provides methods to retrieve the current states of Supervisors.

Only the basic information of the given Supervisor is being queried.. This class was added in vSphere API 8.0.0.1.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class ConfigStatus(string)

Bases: vmware.vapi.bindings.enum.Enum

The Summary.ConfigStatus class describes the status of reaching the desired state configuration for the Supervisor. This enumeration was added in vSphere API 8.0.0.1.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the ConfigStatus instance.

CONFIGURING = ConfigStatus(string='CONFIGURING')

The Namespace configuration is being applied to the Supervisor. This class attribute was added in vSphere API 8.0.0.1.

ERROR = ConfigStatus(string='ERROR')

Failed to apply the Namespace configuration to the Supervisor, user intervention needed. This class attribute was added in vSphere API 8.0.0.1.

REMOVING = ConfigStatus(string='REMOVING')

The Namespace configuration is being removed from the Supervisor. This class attribute was added in vSphere API 8.0.0.1.

RUNNING = ConfigStatus(string='RUNNING')

The Supervisor is configured correctly with the Namespace configuration. This class attribute was added in vSphere API 8.0.0.1.

class FilterSpec(config_status=None, kubernetes_status=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

A Summary.FilterSpec can be specified to filter summary output by any allowed criteria. An empty Summary.FilterSpec will cause all results of the query to be returned. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • config_status (Summary.ConfigStatus or None) – Matches Supervisors with Summary.Info.config_status equal to the specified value. This attribute was added in vSphere API 8.0.0.1. if None this filter is not applied.

  • kubernetes_status (Summary.KubernetesStatus or None) – Matches Supervisors with the Summary.Info.kubernetes_status equal to the specified value. This attribute was added in vSphere API 8.0.0.1. if None this filter is not applied.

class Info(name=None, stats=None, config_status=None, kubernetes_status=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Summary.Info class contains the basic information about the statistics and status related to the Supervisor. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • name (str) – Name of the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • stats (Summary.Stats) – Basic runtime statistics for the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • config_status (Summary.ConfigStatus) – Current status of reaching the desired state configuration for the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • kubernetes_status (Summary.KubernetesStatus) – Current Status of the Supervisor’s ability to deploy pods. This attribute was added in vSphere API 8.0.0.1.

class KubernetesStatus(string)

Bases: vmware.vapi.bindings.enum.Enum

The Summary.KubernetesStatus class describes the Supervisor’s ability to deploy pods. This enumeration was added in vSphere API 8.0.0.1.

Note

This class represents an enumerated type in the interface language definition. The class contains class attributes which represent the values in the current version of the enumerated type. Newer versions of the enumerated type may contain new values. To use new values of the enumerated type in communication with a server that supports the newer version of the API, you instantiate this class. See enumerated type description page.

Parameters

string (str) – String value for the KubernetesStatus instance.

ERROR = KubernetesStatus(string='ERROR')

The Supervisor may not be able to accept pods and has error messages. This class attribute was added in vSphere API 8.0.0.1.

READY = KubernetesStatus(string='READY')

The Supervisor is able to accept pods. This class attribute was added in vSphere API 8.0.0.1.

WARNING = KubernetesStatus(string='WARNING')

The Supervisor may be able to accept pods, but has warning messages. This class attribute was added in vSphere API 8.0.0.1.

class ListItem(supervisor=None, info=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Summary.ListItem class contains information about a Supervisor returned by Summary.list() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • supervisor (str) – The immutable identifier of the Supervisor generated during enablement. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor.Supervisor. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor.Supervisor.

  • info (Summary.Info) – The current state of the Supervisor. This attribute was added in vSphere API 8.0.0.1.

class ListResult(items=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Summary.ListResult class represents the result of Summary.list() method. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters

items (list of Summary.ListItem) – List of items. This attribute was added in vSphere API 8.0.0.1.

class Stats(cpu_used=None, cpu_capacity=None, memory_used=None, memory_capacity=None, storage_used=None, storage_capacity=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Summary.Stats class contains the basic runtime statistics about a Supervisor. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • cpu_used (long) – Overall CPU usage of the Supervisor, in MHz. This is the sum of CPU usage across all worker nodes in the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • cpu_capacity (long) – Total CPU capacity in the Supervisor, in MHz. This is the sum of CPU capacities from all worker nodes in the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • memory_used (long) – Overall memory usage of the Supervisor, in mebibytes. This is the sum of memory usage across all worker nodes in the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • memory_capacity (long) – Total memory capacity of the Supervisor in mebibytes. This is the sum of memory capacities from all worker nodes in the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • storage_used (long) – Overall storage used by the Supervisor, in mebibytes. This is the sum of storage used across all worker nodes in the Supervisor. This attribute was added in vSphere API 8.0.0.1.

  • storage_capacity (long) – Overall storage capacity of the Supervisor, in mebibytes. This is the sum of total storage available from all worker nodes in the Cluster. This attribute was added in vSphere API 8.0.0.1.

get(supervisor)

Queries the current state of the specified Supervisor. This method was added in vSphere API 8.0.0.1.

Parameters

supervisor (str) – the identifier for a supervisor The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor.Supervisor.

Return type

Summary.Info

Returns

Summary.Info of the Supervisor matching the provided identifier.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if the Supervisor matching the ID does not exist.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have Namespaces.Manage privilege and the System.Read privilege on all vSphere Clusters hosting the Supervisor.

list(filter=None)

Queries the current state of all Supervisors. Optionally, apply the filter to Supervisors that match the criteria in the Summary.FilterSpec. This method was added in vSphere API 8.0.0.1.

Parameters

filter (Summary.FilterSpec or None) – Set of parameters that can be used to constrain the results of the method. if None all records will be returned.

Return type

Summary.ListResult

Returns

ListResult of Summary.Info of all Supervisors matching the criteria in the Summary.FilterSpec.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have Namespaces.Manage privilege and the System.Read privilege on all vSphere Clusters hosting the Supervisor.

class com.vmware.vcenter.namespace_management.supervisors_client.Topology(config)

Bases: vmware.vapi.bindings.stub.VapiInterface

The Topology class provides methods to query the topological layout of the infrastructure a Supervisor is running on. This class was added in vSphere API 8.0.0.1.

Parameters

config (vmware.vapi.bindings.stub.StubConfiguration) – Configuration to be used for creating the stub.

class Info(zone=None, clusters=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

The Topology.Info class contains the basic information about the association between vSphere Zones and vSphere Clusters. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • zone (str) – Identifier of this vSphere Zone. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: com.vmware.vcenter.consumption_domains.Zone. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: com.vmware.vcenter.consumption_domains.Zone.

  • clusters (list of str) – A list of vSphere Cluster identifiers that are associated with the vSphere Zone. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must contain identifiers for the resource type: ClusterComputeResource. When methods return a value of this class as a return value, the attribute will contain identifiers for the resource type: ClusterComputeResource.

get(supervisor)

Queries the current association between vSphere Zones and vSphere Clusters from the given Supervisor ID. A Supervisor can be running on one or multiple vSphere Zones, and each vSphere Zone is associated with one or more vSphere Clusters. Use the vSphere Cluster IDs obtained from Topology.get() to call the APIs that requires a vSphere Cluster ID instead of a Supervisor. This method was added in vSphere API 8.0.0.1.

Parameters

supervisor (str) – Identifier for a Supervisor. The parameter must be an identifier for the resource type: com.vmware.vcenter.namespace_management.supervisor.Supervisor.

Return type

list of Topology.Info

Returns

List of Topology.Info of vSphere Zone and vSphere Cluster associations.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.Error if the system reports an error while responding to the request.

Raise

com.vmware.vapi.std.errors_client.NotFound if given Supervisor does not exist.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user can not be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthenticated if the user cannot be authenticated.

Raise

com.vmware.vapi.std.errors_client.Unauthorized if the user does not have Namespaces.Manage privilege and the System.Read privilege on all vSphere Clusters hosting the Supervisor.

class com.vmware.vcenter.namespace_management.supervisors_client.Workloads(network=None, edge=None, kube_api_server_options=None, images=None, storage=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

Workloads class describes configuration that affects the behavior and lifecycle of Kubernetes workloads.. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • network (com.vmware.vcenter.namespace_management.supervisors.networks.workload_client.Network) –

    The workloads Workloads.network describes configuration for the primary workload network.

    Workloads will communicate with each other and will reach external networks over this network.

    The IP ranges configured on this network are managed primarily within Kubernetes.. This attribute was added in vSphere API 8.0.0.1.

  • edge (com.vmware.vcenter.namespace_management.networks.edges_client.Edge) –

    Workloads.edge configuration determines how network traffic will enter and leave the cluster.

    The IP ranges configured on this network are managed by the Supervisor and the load balancer.. This attribute was added in vSphere API 8.0.0.1.

  • kube_api_server_options (KubeAPIServerOptions or None) – Workloads.kube_api_server_options declares configuration options for the Kubernetes API Server.. This attribute was added in vSphere API 8.0.0.1. If None, the default configuration will be used.

  • images (ImageSyncConfig or None) – Workloads.images specifies how images will be stored and pulled into the cluster.. This attribute was added in vSphere API 8.0.0.1. If None, image sync configuration will default to the settings described within the ImageSyncConfig class.

  • storage (WorkloadsStorageConfig or None) – Workloads.storage specifies which persistent storage is configured and accessible for workloads to consume. You can configure policies for both images and volumes.. This attribute was added in vSphere API 8.0.0.1. If None, configuration will be copied from the control plane when possible. If not, some storage features may be unavailable.

class com.vmware.vcenter.namespace_management.supervisors_client.WorkloadsStorageConfig(cloud_native_file_volume=None, ephemeral_storage_policy=None, image_storage_policy=None)

Bases: vmware.vapi.bindings.struct.VapiStruct

WorkloadsStorageConfig class describes how vSphere and Kubernetes will persist images and volumes to disk. This class was added in vSphere API 8.0.0.1.

Tip

The arguments are used to initialize data attributes with the same names.

Parameters
  • cloud_native_file_volume (CNSFileConfig or None) – WorkloadsStorageConfig.cloud_native_file_volume specifies the Cloud Native Storage file volume support on the Supervisor. This feature provides ReadWriteMany container volumes support. This attribute was added in vSphere API 8.0.0.1. If None, file volume support will not be enabled on the Supervisor.

  • ephemeral_storage_policy (str or None) – WorkloadsStorageConfig.ephemeral_storage_policy identifies the storage policy associated with ephemeral disks of all the Kubernetes PodVMs in the cluster. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: SpsStorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: SpsStorageProfile. If None during cluster enablement, the ephemeral storage policy will be defaulted to the configured ControlPlane.storage_policy.

  • image_storage_policy (str or None) – The WorkloadsStorageConfig.image_storage_policy class contains the specification required to configure storage used for PodVM container images. This attribute was added in vSphere API 8.0.0.1. When clients pass a value of this class as a parameter, the attribute must be an identifier for the resource type: SpsStorageProfile. When methods return a value of this class as a return value, the attribute will be an identifier for the resource type: SpsStorageProfile. If None, the image storage policy will be set to the specified WorkloadsStorageConfig.ephemeral_storage_policy if provided. This field will inherit any defaults for ephemeral storage policy set by the system.