VMware Cloud Community
vin01
Expert
Expert

Deploy Photon 3.0 with answer file

Hi LucD,

Requesting your help on deploy photon os part 2(Deploy Photon 2.0 - Part 2 - LucD notes ).

When I shipped the template to the customer which I created using your part 1 script. Its bit difficult to update the JSON file by the customers.

So what i am thinking is to provide a csv file like below and customer will fill the csv and save it and execute the New-PhotonVM function.

Now the inputs which we need to pass into json file will be taken from the csv.

So is it possible to pass the inputs from the csv to json while deploying the VMs(Ex- VMhost,storage,OVF path in json should be taken from csv file).

Sample CSV.

pastedImage_4.png

Regards Vineeth.K
Reply
0 Kudos
1 Reply
LucD
Leadership
Leadership

The problem will be that I used JSON because it has a structured hierarchy (it has depth),

while a CSV file only has a single dimension.

Where the function uses for example

$paramData.vSphere.Storage

it would now have to be something like

$paramData.Storage

But if you make all the correct changes, you should be able to adapt the function to read the input from a CSV file.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

Reply
0 Kudos