Manually set IP in VRA 8.1

This post was originally published on this site

What I am trying to do is to set the IP address of the VM manually so I do not have to use an IP Range. My company has a bluecat IPAM, and I have a powershell script that will get an available ip for the network from bluecat. We do not have the bluecat intetgration for vra and are not purchasing it. In vra 7.6 with vro I used virtualMachineAddOrUpdateProperties to set the IP and it worked fine.

 

I am now trying to get the same using VRA 8.1, on-prem, with powershell and an ABX. I have a VRA network profile with 1 network 10.7.127.0/24 and it has 1 IP range in VRA of .5-.10. When I deploy a blueprint and the YAML has assignment:static for my network resource the vm deploys and it obtains 1 of the addresses from the IP Range (example .6) no problem. When I deploy a blueprint and the YAML has assignment:static for my network resource the VM deploys but it keeps it’s original IP (.252).

 

How do I set a static IP in 8.1? I have an ABX subscribed to compute.provision.pre and compute.provision.post. These both have a place in JSON for addresses.

I use the ABX and inject into addresses, the 1st addres out of my range, 10.7.127.11

Outputs

{

  “tags”: {},

  “target”: “World”,

  “zoneId”: “5ad9740d-6829-4739-8a92-46c297c90ffc”,

  “addresses”: [

    [

      “10.7.127.11”

    ]

  ],….

 

Even with this output, if assignment:static is set in YAML, I get an address from the IP range, not the manually specified IP address .11

What am  I doing wrong? It was much easier in 7.6 I must be missing something simple.

thanks,

ds

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.