VMware Cloud Community
PavelGudkov
Enthusiast
Enthusiast

vRA 8 How to set DNS Server list in blueprint

Hello,

I know that it is posible to assign DNS server list ad dns suffix search for VM using Network Profile, but I need to do it using dns property of network resource in blueprint. But I do not understand the syntax of that.

Context help says: Array, DNS servers Specification for the creation of the subnet.

I try:

Cloud_vSphere_Network_1:
type: Cloud.vSphere.Network
properties:
networkType: existing
dns:
- 10.10.10.10
- 20.20.20.20

And I have an error: 

Cannot deserialize instance of `String` out of START_ARRAY token
at [Source: UNKNOWN; line: -1, column: -1] (through reference chain: com.vmware.admiral.compute.network.ComputeNetworkDescriptionService$ComputeNetworkDescription["dns"])

 

0 Kudos
2 Replies
jimmyvandermast
Hot Shot
Hot Shot

Move the dns part to the machine.

resources:
vSphere__vCenter_-machine_1:
type: Cloud.vSphere.Machine
properties:
networks:
- network: '${resource.Cloud_vSphere_Network_1.id}'
assignment: static
dns:
- 1.1.1.1
- 2.2.2.2
Cloud_vSphere_Network_1:
type: Cloud.vSphere.Network
properties:
networkType: existing

0 Kudos
musclar
Contributor
Contributor

Are you sure about that solution?

I tryed this and it doesnt'y work.

In fact, I'm creating Dynamic Network but this shouldn't be problem?

0 Kudos