The environment I work with has vRA 8.2, vSphere 7U1 and NSX-T 3 deployed.
I have build 2 basic blueprints, based on a vsphere template. One should deploy a VM into an existing NSX-T network (overlay). The second should deploy the VM with the NIC connected to a dvs port group.
The NSX network and the network profile that is referencing it have the tag 'network_placement:nsx' assigned to it. Similarily, the vSphere port gorup and a separate network profile containing it have the tag 'network_placement:vsphere' assigned.
Both tags controllign the acces to the network resources are assigned to the project.
None of the networks is selected as "default".
The vSphere Endpoint is tagged with env:vsphere'.
Here's the blueprint for the vSphere VM:
formatVersion: 1
inputs: {}
resources:
Cloud_vSphere_Network_1:
type: Cloud.vSphere.Network
properties:
networkType: existing
constraints:
- tag: 'network_placement:vsphere'
Cloud_vSphere_Machine_1:
type: Cloud.vSphere.Machine
properties:
imageRef: centos8minimal-template
cpuCount: 2
totalMemoryMB: 2048
networks:
- network: '${resource.Cloud_vSphere_Network_1.id}'
constraints:
- tag: 'env:vsphere'
And here the VM with the NSX placement:
formatVersion: 1
inputs: {}
resources:
Cloud_NSX_Network_1:
type: Cloud.NSX.Network
properties:
networkType: existing
constraints:
- tag: 'network_placement:nsx'
Cloud_vSphere_Machine_1:
type: Cloud.vSphere.Machine
properties:
imageRef: centos8minimal-template
cpuCount: 2
totalMemoryMB: 2048
networks:
- network: '${resource.Cloud_NSX_Network_1.id}'
constraints:
- tag: 'env:vsphere'
I have removed all input properties, to keep it as simple as possible.
The NSX version is deployed without issues.
However when trying to deploy the VM that has to be connected to the dvs, a few problems arise:
It seems like the constraint 'network_placement:nsx' is somehow the default and is assigned to every network resource, overwriting any other constraint. I also do not understand, how a Cloud.vSphere.Network resource can be associated with the NSX-T cloud account?
I've been using following documentation for provisioning the deployment:
Network, security, and load balancer examples in vRealize Automation cloud templates
Can anyone help me with understanding how a vSphere network gets associated with a NSX-T account?
edit: removed some typos
What tags do your network profiles have and does your project have any network constraints?
No network constraints on the project.
Same tag on network profile and attached network.
In Cloud Assembly Template Designer can you test your BP? Should give you an overview of the placement logic by the Provisioning Diagram: