New-WMNamespaceNetworkSpec Command | Vmware PowerCLI Reference

New-WMNamespaceNetworkSpec

Creates a specification for a namespace network. The specification is later used to create the actual namespace network.

Syntax

New-WMNamespaceNetworkSpec
-AddressRanges < String[] >
-DistributedPortGroup < VDPortgroup >
-Gateway < String >
-Name < String >
-Subnet < String >
[-ProgressAction < ActionPreference > ]
[-Server < VIServer[] > ]
[CommonParameters]

Parameters

Required Parameter Name Type Position Features Description
required
AddressRanges String[] named
Specifies one or more strings representing an IP address range in the format "start IP - end IP". For example, "192.169.10.100 - 192.169.10.200".
required
DistributedPortGroup VDPortgroup named
Specifies the distributed portgroup that handles the Kubernetes workload traffic.
required
Gateway String named
Specifies the gateway of the network.
required
Name String named
Specifies a unique name within the cluster. This must be an alphanumeric (a-z and 0-9) string, with a maximum length of 63 characters. You can use the hyphen (-) anywhere except for the first or last symbol.
required
Subnet String named
Specifies the subnet mask of the network.
optional ProgressAction ActionPreference named
optional Server VIServer[] named
Specifies the vCenter Server systems on which you want to run the cmdlet. If no value is given to this parameter, the command runs on the default servers. For more information about default servers, see the description of the Connect-VIServer cmdlet.

Output

VMware.VimAutomation.WorkloadManagement.Types.V1.WMNamespaceNetworkSpec

Examples

Example 1

$primaryWorkloadNetworkSpec = New-WMNamespaceNetworkSpec `
   -Name "network-1" `
   -Gateway "192.168.10.1" `
   -Subnet "255.255.255.0" `
   -AddressRanges "192.168.10.50-192.168.10.99" `
   -DistributedPortGroup "Management Network"

Get-Cluster "MyCluster" | Enable-WMCluster `
   -SizeHint Tiny `
   -ManagementVirtualNetwork (Get-VirtualNetwork "VM Network" ) `
   -ManagementNetworkMode Dhcp `
   -ServiceCIDR "10.96.0.0/24" `
   -EphemeralStoragePolicy "MyStoragePolicy1" `
   -ImageStoragePolicy "MyStoragePolicy2" `
   -MasterStoragePolicy "MyStoragePolicy3" `
   -ContentLibrary "cl1" `
   -HAProxyName "HAProxy1" `
   -HAProxyAddressRanges "192.168.10.50-192.168.10.99" `
   -HAProxyUsername "HAProxy1AdminUser" `
   -HAProxyPassword "pass" `
   -HAProxyDataPlaneAddresses "HAProxy1DataPlane:443" `
   -HAProxyServerCertificateChain "-----BEGIN CERTIFICATE-----...........-----END CERTIFICATE-----" `
   -PrimaryWorkloadNetworkSpecification $primaryWorkloadNetworkSpec

Creates a specification for a workspace network backed by a distributed portgroup. The specification is then passed to Enable-WMCluster which creates a namespace network that can later be used by the workloads.

Related Commands

WMNamespace

This cmdlet retrieves the workload namespaces in the vCenter Server system.

This cmdlet creates a new workload namespace on the specified cluster.

This cmdlet deletes a workload namespace from the vCenter Server system.

This cmdlet modifies the configuration of a workload namespace.

WMNamespaceLimits

Retrieves information about the Kubernetes resource limits of a namespace.

Changes the Kubernetes resource limits of a namespace.

WMNamespaceNetworkSpec

Creates a specification for a namespace network. The specification is later used to create the actual namespace network.

WMNamespacePermission

Retrieves information about workload namespace access permissions.

Grants an access permission to a workload namespace.

Removes an access permission to a workload namespace.

Modifies an access permission to a workload namespace.

WMNamespaceStoragePolicy

This cmdlet retrieves the configuration of the storage claimed by a workload namespace.

This cmdlet creates a storage claim for a workload namespace using the specified configuration.

This cmdlet deletes the storage claim for a workload namespace associated with a specified storage policy.

This cmdlet modifies the configuration of a storage claim used by a workload namespace.