1
0
mirror of https://github.com/vmware/vsphere-automation-sdk-python.git synced 2024-11-23 01:49:59 -05:00
vsphere-automation-sdk-python/samples/vsphere/vcenter
2017-02-17 15:06:57 -08:00
..
helper add supported vcenter_version to vcenter and tagging samples 2017-02-10 13:55:36 -08:00
setup Add missing top level module dunder 2017-02-09 17:19:12 -08:00
vm use atexit intead of try catch in main 2017-02-17 15:06:57 -08:00
__init__.py Add missing top level module dunder 2017-02-09 17:19:12 -08:00
README.md update vcenter README files 2017-01-24 17:29:00 -08:00

This directory contains samples for the vSphere infrastructure and virtual machine APIs. You have two options to run samples inside this package:

  • Run all samples under vcenter folder using main.py in samples.vsphere.vcenter.setup package. Please see the README for more details.

  • Run an individual sample in an existing environment. You can either pass the environment parameters through command line arguments or specify them in testbed.py in the setup package.

    For example, to run the create_default_vm sample in the vsphere.samples.vcenter.vm.create package:

    * with the testbed settings specified in testbed.py in a Linux machine:
    
       $ ./run_sample.sh ../samples/vsphere/vcenter/vm/create/create_default_vm.py -v
    
    * Or specify the credentials using command line parameters:
    
       $ ./run_sample.sh ../samples/vsphere/vcenter/vm/create/create_default_vm.py -s \<server> -u \<username> -p \<password> -v