Automation

 View Only
  • 1.  how to import ovf from www using powercli?

    Broadcom Employee
    Posted Jul 28, 2016 07:00 AM

    Hi folks,

    as I know Import-VApp can import existing ovf to my vc/vsphere and its ovf must be local to windows for example -Source "c:\vApps\WebServer\WebServer.ovf",

    but the source could be from www for example http://www.foo.com/samplevm.ovf, so far I have to download samplevm.ovf locally to windows and them import-vapp to import it,

    I learned ovftool.exe can do this job but could powercli import from www to my vsphere without downloading locally? really appreciate!

    Simon



  • 2.  RE: how to import ovf from www using powercli?

    Posted Jul 28, 2016 07:20 AM

    Afaik that is currently not possible, see also Deploy OVF template using Import-vApp -Source from Datastore?



  • 3.  RE: how to import ovf from www using powercli?

    Broadcom Employee
    Posted Jul 28, 2016 07:34 AM

    thank you sir,

    when using vCenter, the import wizard can work with both local windows path and the www url, so I was wondering there could be one api powercli can use?

    Simon



  • 4.  RE: how to import ovf from www using powercli?

    Posted Jul 28, 2016 07:57 AM

    Yes, that is what I mentioned in that other thread.

    You will first have to obtain the OVF Descriptor, with the Descriptor you call the CreateImportSpec method.

    Then you call the regular ImportVApp method. Via the Status in the returned HttpNfcLease object you can follow the progress of the import.

    I have a script that uses this technique to import a local OVF file, but for an OVF via an URL I'm still struggling with certificates, proxies and firewalls I'm afraid.



  • 5.  RE: how to import ovf from www using powercli?

    Broadcom Employee
    Posted Jul 28, 2016 08:24 AM

    thank you Sir, could you please post the script importing local ovf file? it still can teach me a lot, thanks

    Simon



  • 6.  RE: how to import ovf from www using powercli?

    Posted Jul 28, 2016 09:16 AM

    Drop me an email (link on my blog).
    The script is still very raw, don't want to make it public yet :smileygrin:



  • 7.  RE: how to import ovf from www using powercli?

    Broadcom Employee
    Posted Jul 28, 2016 09:32 AM

    just send it in e-mail, thank you Sir,

    Simon