1
0
mirror of https://github.com/vmware/vsphere-automation-sdk-python.git synced 2024-11-26 03:10:00 -05:00

Mis changes

1. Use '_' to replace ' ' for objects in testbed.py
2. Update the path in README
3. Add README to sso and lib folder
This commit is contained in:
Tianhao He 2017-01-24 15:28:39 -08:00
parent af0f3f2634
commit 92c794364d
26 changed files with 117 additions and 97 deletions

2
.gitignore vendored
View File

@ -1,2 +1,4 @@
*.py[cod]
__pycache__/
.DS_Store
.idea/*

View File

@ -57,7 +57,7 @@ Before executing the samples we'll need to setup the vSphere test environment us
First, from the command line change to the SDK ./bin folder.
$ cd /path/to/VMware-vSphere-Automation-SDK-Python-<version>/bin
$ cd /path/to/vsphere-automation-sdk-python-samples/bin
Next, using a text editor open ../samples/vsphere/vcenter/setup/testbed.py and edit the following settings replace everything in < > brackts with your environment information. Leave the rest of the settings in this file at their default values.

View File

@ -163,10 +163,10 @@ You have two options to run samples inside this package:
<ul>
<li><code>$ cd /path/to/VMware-vSphere-Automation-SDK-Python-&lt;version&gt;/client/bin</code></li>
<li>Run the sample with the testbed settings specified in setup.py in a Linux machine:<br/>
<code>$ ./run_sample.sh ../samples/src/vsphere/samples/vcenter/vm/create/create_default_vm.py -v</code>
<code>$ ./run_sample.sh ../samples/src/samples/vsphere/vcenter/vm/create/create_default_vm.py -v</code>
</li>
<li>Or specify the credentials using command line parameters:<br/>
<code>$ ./run_sample.sh ../samples/src/vsphere/samples/vcenter/vm/create/create_default_vm.py -s &lt;server&gt; -u &lt;username&gt; -p &lt;password&gt; -v</code>
<code>$ ./run_sample.sh ../samples/src/samples/vsphere/vcenter/vm/create/create_default_vm.py -s &lt;server&gt; -u &lt;username&gt; -p &lt;password&gt; -v</code>
</li>
</ul>
</li>
@ -244,9 +244,9 @@ vApi connection workflow sample performs the following basic steps to connect
The call sequence shown above is implemented in the samples framework through the following modules:</br>
<ul>
<li><code>src/vsphere/samples/common/lookup_service_helper</code> provides methods for discovering management nodes and service endpoint URLs on management nodes from lookup service.</li>
<li><code>src/vsphere/samples/common/platform_service_controller</code> uses lookup_service_helper to discover the Single Sign-On URL (on any of the Platform Service Controller node) and then retrieves the SAML token from the Single Sign-On server by authenticating the given user.</li>
<li><code>src/vsphere/samples/common/service_manager</code> login to the vAPI and vim service endpoints (on a management node).</li>
<li><code>src/samples/vsphere/common/lookup_service_helper</code> provides methods for discovering management nodes and service endpoint URLs on management nodes from lookup service.</li>
<li><code>src/samples/vsphere/common/platform_service_controller</code> uses lookup_service_helper to discover the Single Sign-On URL (on any of the Platform Service Controller node) and then retrieves the SAML token from the Single Sign-On server by authenticating the given user.</li>
<li><code>src/samples/vsphere/common/service_manager</code> login to the vAPI and vim service endpoints (on a management node).</li>
</ul>
<h3>Running the Connection Workflow Samples:</h3>
@ -311,7 +311,7 @@ Before running the samples:
</p>
<pre>
$cd /path/to/VMware-vSphere-Automation-SDK-Python-&lt;version&gt;/client/bin
$run_sample.sh ../samples/src/vsphere/samples/workflow/connection_workflow.py \
$run_sample.sh ../samples/src/samples/vsphere/workflow/connection_workflow.py \
-vapiurl https://203.0.113.0/api \
-stsurl https://203.0.113.0:443/sts/STSService/vsphere.local \
-username administrator@vsphere.local \
@ -322,7 +322,7 @@ $run_sample.sh ../samples/src/vsphere/samples/workflow/connection_workflow.py \
Use the -h option to print information about a sample.
The following example shows the help for the vAPI connection workflow sample.
<pre>
$ ./run_sample.sh ../samples/src/vsphere/samples/workflow/vapi_connection_workflow.py -h
$ ./run_sample.sh ../samples/src/samples/vsphere/workflow/vapi_connection_workflow.py -h
usage: vapi_connection_workflow.py [-h] [-w LSWSDLURL] [-s LSSOAPURL]
[-m MGMTINSTANCENAME] [-u USERNAME]
[-p PASSWORD] [-v]

9
lib/README.md Normal file
View File

@ -0,0 +1,9 @@
This directory contains samples for Platform Service Controller, SSO and Lookup Service APIs:
Running the samples
* $ cd /path/to/vsphere-automation-sdk-python-samples/bin
* $ ./run_sample.sh ../samples/vsphere/tagging/tagging_workflow.py --server <vCenter Server IP> --username <username> --password <password> --clustername <clustername> --categoryname <categoryname> --categorydesc <categorydesc> --tagname <tagname> -tagdesc <tagdesc> -v
* Testbed Requirement:
- 1 vCenter Server

View File

@ -18,7 +18,7 @@ from vmware.vapi.security.sso import create_saml_bearer_security_context
from samples.vsphere.common import sso
from samples.vsphere.common.lookup_service_helper import LookupServiceHelper
from samples.common.ssl_helper import get_unverified_context
from samples.vsphere.common.ssl_helper import get_unverified_context

View File

@ -16,7 +16,7 @@ __copyright__ = 'Copyright 2013, 2016 VMware, Inc. All rights reserved.'
from pyVim.connect import SmartConnect, Disconnect
from samples.vsphere.common import vapiconnect
from samples.common.ssl_helper import get_unverified_context
from samples.vsphere.common.ssl_helper import get_unverified_context
class ServiceManager(object):

View File

@ -75,8 +75,9 @@ def logout(stub_config):
"""
Delete session with vCenter.
"""
session_svc = Session(stub_config)
session_svc.delete()
if stub_config:
session_svc = Session(stub_config)
session_svc.delete()
def create_unverified_session(session, suppress_warning):

View File

@ -16,7 +16,7 @@ __copyright__ = 'Copyright 2013, 2016 VMware, Inc. All rights reserved.'
from pyVmomi import vim
from samples.vsphere.common.sample_base import SampleBase
from samples.vsphere.common.vim.helpers import get_obj
from samples.vsphere.common.vim.helpers.vim_utils import get_obj
class GetClusterByName(SampleBase):

View File

@ -16,7 +16,7 @@ __copyright__ = 'Copyright 2013, 2016 VMware, Inc. All rights reserved.'
from pyVmomi import vim
from samples.vsphere.common.sample_base import SampleBase
from samples.vsphere.common.vim.helpers import get_obj
from samples.vsphere.common.vim.helpers.vim_utils import get_obj
class GetDatastoreByName(SampleBase):

View File

@ -10,8 +10,8 @@ This directory contains samples for Content Library APIs:
Running the samples
* $ cd /path/to/VMware-vSphere-Automation-SDK-Python-<version>/bin
* $ ./run_sample.sh ../vsphere/samples/contentlibrary/<sample-dir>/<sample>.py --server <vCenter Server IP> --name <username> --password <password> <additional-sample-parameters>
* $ cd /path/to/vsphere-automation-sdk-python-samples/bin
* $ ./run_sample.sh ../samples/vsphere/contentlibrary/<sample-dir>/<sample>.py --server <vCenter Server IP> --username <username> --password <password> <additional-sample-parameters>
The additional sample parameters are as follows (all parameters can be displayed for any sample using option --help)

View File

@ -17,7 +17,7 @@ from com.vmware.content_client import LibraryModel
from samples.vsphere.common.id_generator import generate_random_uuid
from samples.vsphere.common.sample_base import SampleBase
from samples.vsphere.common.vim.helpers import get_datastore_id
from samples.vsphere.common.vim.helpers.get_datastore_by_name import get_datastore_id
from samples.vsphere.contentlibrary.lib.cls_api_client import ClsApiClient
__author__ = 'VMware, Inc.'

View File

@ -27,7 +27,7 @@ from com.vmware.content.library.item_client import (DownloadSessionModel,
from com.vmware.content.library.item.downloadsession_client import File as DownloadSessionFile
from com.vmware.content.library.item.updatesession_client import File as UpdateSessionFile
from samples.vsphere.common.id_generator import generate_random_uuid
from samples.vsphere.common.vim.helpers import get_datastore_id
from samples.vsphere.common.vim.helpers.get_datastore_by_name import get_datastore_id
__author__ = 'VMware, Inc.'
__copyright__ = 'Copyright 2016 VMware, Inc. All rights reserved.'

View File

@ -23,7 +23,7 @@ from pyVmomi import vim
from samples.vsphere.common.id_generator import generate_random_uuid
from samples.vsphere.common.sample_base import SampleBase
from samples.vsphere.common.vim.helpers import (
from samples.vsphere.common.vim.helpers.vim_utils import (
get_obj, get_obj_by_moId, poweron_vm, poweroff_vm, delete_object)
from samples.vsphere.contentlibrary.lib.cls_api_client import ClsApiClient
from samples.vsphere.contentlibrary.lib.cls_api_helper import ClsApiHelper

View File

@ -25,7 +25,7 @@ from samples.vsphere.common.id_generator import generate_random_uuid
from samples.vsphere.common.sample_base import SampleBase
from samples.vsphere.contentlibrary.lib.cls_api_client import ClsApiClient
from samples.vsphere.contentlibrary.lib.cls_api_helper import ClsApiHelper
from samples.vsphere.common.vim.helpers import get_datastore_id
from samples.vsphere.common.vim.helpers.get_datastore_by_name import get_datastore_id
__author__ = 'VMware, Inc.'

View File

@ -0,0 +1,9 @@
This directory contains samples for Platform Service Controller, SSO and Lookup Service APIs:
Running the samples
* $ cd /path/to/vsphere-automation-sdk-python-samples/bin
* $ ./run_sample.sh ../samples/vsphere/tagging/tagging_workflow.py --server <vCenter Server IP> --username <username> --password <password> --clustername <clustername> --categoryname <categoryname> --categorydesc <categorydesc> --tagname <tagname> -tagdesc <tagdesc> -v
* Testbed Requirement:
- 1 vCenter Server

View File

@ -29,7 +29,7 @@ from vmware.vapi.security.sso import create_saml_bearer_security_context
from vmware.vapi.security.session import create_session_security_context
from vmware.vapi.stdlib.client.factories import StubConfigurationFactory
from vmware.vapi.lib.connect import get_requests_connector
from samples.common.ssl_helper import get_unverified_context
from samples.vsphere.common.ssl_helper import get_unverified_context
class ConnectionWorkflow(object):

View File

@ -2,11 +2,10 @@ This directory contains samples for Tagging APIs:
Running the samples
* $ cd /path/to/VMware-vSphere-Automation-SDK-Python-<version>/bin
* $ ./run_sample.sh ../vsphere/samples/tagging/tagging_workflow.py --server <vCenter Server IP> --name <username> --password <password> --clustername <clustername> --categoryname <categoryname> --tagname <tagname>
* $ cd /path/to/vsphere-automation-sdk-python-samples/bin
* $ ./run_sample.sh ../samples/vsphere/tagging/tagging_workflow.py --server <vCenter Server IP> --username <username> --password <password> --clustername <clustername> --categoryname <categoryname> --categorydesc <categorydesc> --tagname <tagname> -tagdesc <tagdesc> -v
* Testbed Requirement:
- 1 vCenter Server
- 1 ESX hosts
- 1 cluster

View File

@ -9,7 +9,7 @@ inside the vcenter.vm package.
* Prepare testbed using setup script:
- Edit testbed.py with your settings. In particular, you need to set the IP addresses and credentials in this file.
$ cd /path/to/VMware-vSphere-Automation-SDK-Python-<version>/client/bin
$ cd /path/to/vsphere-automation-sdk-python-samples/client/bin
$ ./run_sample.sh ../samples/vsphere/vcenter/setup/main.py -st
* Run the vAPI vCenter sample suite:

View File

@ -10,9 +10,9 @@
* NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
"""
from samples.vsphere.vim.file import (detect_file, delete_file,
from samples.vsphere.common.vim.file import (detect_file, delete_file,
parse_datastore_path)
from samples.vsphere.vim.inventory import get_datastore_mo
from samples.vsphere.common.vim.inventory import get_datastore_mo
from samples.vsphere.common.vim import datastore_file

View File

@ -10,9 +10,9 @@
* NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
"""
from samples.vsphere.vim.file import (detect_file, delete_file,
from samples.vsphere.common.vim.file import (detect_file, delete_file,
parse_datastore_path)
from samples.vsphere.vim.inventory import get_datastore_mo
from samples.vsphere.common.vim.inventory import get_datastore_mo
from samples.vsphere.common.vim import datastore_file

View File

@ -28,7 +28,7 @@ from samples.vsphere.vcenter.setup.testbed_setup import validate as testbed_vali
from samples.vsphere.vcenter.vm.main import cleanup as sample_cleanup
from samples.vsphere.vcenter.vm.main import run as sample_run
from samples.common.ssl_helper import get_unverified_context
from samples.vsphere.common.ssl_helper import get_unverified_context
# Parse command line params for setup script

View File

@ -13,35 +13,35 @@
"""
config = {}
config["SERVER"] = ""
config["USERNAME"] = ""
config["PASSWORD"] = ""
config["SERVER"] = "10.192.34.73"
config["USERNAME"] = "administrator@vsphere.local"
config["PASSWORD"] = "Admin!23"
config["ESX_HOST1"] = ""
config["ESX_HOST2"] = ""
config["ESX_USER"] = ""
config["ESX_HOST1"] = "10.192.49.29"
config["ESX_HOST2"] = "10.192.51.199"
config["ESX_USER"] = "root"
config["ESX_PASS"] = ""
config["USE_NFS"] = True
config["NFS_HOST"] = ""
config["NFS_HOST"] = "10.192.43.16"
config["NFS_REMOTE_PATH"] = "/store1"
config["NFS_DATASTORE_NAME"] = "Shared NFS Volume"
config["NFS_DATASTORE_NAME"] = "Shared_NFS_Volume"
config["ESX_HOST1_VMFS_DATASTORE"] = "Local VMFS Volume on Host1"
config["ESX_HOST2_VMFS_DATASTORE"] = "Local VMFS Volume on Host2"
config["ESX_HOST1_VMFS_DATASTORE"] = "Local_VMFS_Volume_on_Host1"
config["ESX_HOST2_VMFS_DATASTORE"] = "Local_VMFS_Volume_on_Host2"
config["DATACENTER1_NAME"] = "Sample DC 1"
config["DATACENTER2_NAME"] = "Sample DC 2"
config["DATACENTER1_NAME"] = "Sample_DC_1"
config["DATACENTER2_NAME"] = "Sample_DC_2"
config["VM_FOLDER1_NAME"] = "Sample VM Folder 1"
config["VM_FOLDER2_NAME"] = "Sample VM Folder 2"
config["VM_FOLDER1_NAME"] = "Sample_VM_Folder_1"
config["VM_FOLDER2_NAME"] = "Sample_VM_Folder_2"
config["CLUSTER1_NAME"] = "Cluster 1"
config["CLUSTER1_NAME"] = "Cluster1"
config["VDSWITCH1_NAME"] = "DSwitch 1"
config["VDPORTGROUP1_NAME"] = "Static Portgroup on DSwitch 1"
config["VDSWITCH1_NAME"] = "DSwitch1"
config["VDPORTGROUP1_NAME"] = "Static_Portgroup_on_DSwitch_1"
config["STDPORTGROUP_NAME"] = "VM Network"
config["STDPORTGROUP_NAME"] = "VM_Network"
# The main datacenter and datastore that will be used for the VM tests
config["VM_DATACENTER_NAME"] = config["DATACENTER2_NAME"]
@ -50,9 +50,9 @@ config["VM_DATASTORE_NAME"] = config["NFS_DATASTORE_NAME"]
# GestOS should be one of the enumeration values in com.vmware.vcenter.vm.GuestOS
config["VM_GUESTOS"] = "WINDOWS_9_64"
config["VM_NAME_DEFAULT"] = "Sample Default VM for Simple Testbed"
config["VM_NAME_BASIC"] = "Sample Basic VM for Simple Testbed"
config["VM_NAME_EXHAUSTIVE"] = "Sample Exhaustive VM for Simple Testbed"
config["VM_NAME_DEFAULT"] = "Sample_Default_VM_for_Simple_Testbed"
config["VM_NAME_BASIC"] = "Sample_Basic_VM_for_Simple_Testbed"
config["VM_NAME_EXHAUSTIVE"] = "Sample_Exhaustive_VM_for_Simple_Testbed"
config["BACKENDS_DATACENTER_NAME"] = config["VM_DATACENTER_NAME"]

View File

@ -13,7 +13,7 @@ This directory contains samples for vCenter virtual machine APIs:
* Configure virtual SCSI adapters of a virtual machine - hardware/adapter/scsi.py
* Configure the booting settings for virtual machine - hardware/boot.py
* Configure the boot devices used by a virtual machine - hardware/boot_device.py
* Configure CD-ROM devices for a virtual machine - hardware/cdrom.py
* Configure CD-ROM devices for a virtual machine - hardware/cdrom.py
* Configure CPU settings for a virtual machine - hardware/cpu.py
* Configure disk settings for a virtual machine - hardware/disk.py
* Configure virtual ethernet adapters of a virtual machine - hardware/ethernet.py
@ -34,12 +34,12 @@ You have two options to run samples inside this package:
For example, to run the create_default_vm sample in the samples.vsphere.vcenter.vm.create package:
* $ cd /path/to/VMware-vSphere-Automation-SDK-Python-<version>/client/bin
* $ cd /path/to/vsphere-automation-sdk-python-samples/bin
* Run the sample with the testbed settings specified in setup.py in a Linux machine:
$ ./run_sample.sh ../samples/src/vsphere/samples/vcenter/vm/create/create_default_vm.py -v
$ ./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/src/vsphere/samples/vcenter/vm/create/create_default_vm.py -s &lt;server&gt; -u &lt;username&gt; -p &lt;password&gt; -v
$ ./run_sample.sh ../samples/vsphere/vcenter/vm/create/create_default_vm.py -s &lt;server&gt; -u &lt;username&gt; -p &lt;password&gt; -v

View File

@ -19,7 +19,7 @@ from com.vmware.vcenter.vm.hardware_client import (IdeAddressSpec,
SataAddressSpec,
ScsiAddressSpec)
from pyVim.connect import SmartConnect, Disconnect
from samples.vsphere.vim.vmdk import (create_vmdk, delete_vmdk, detect_vmdk)
from samples.vsphere.common.vim.vmdk import (create_vmdk, delete_vmdk, detect_vmdk)
from samples.vsphere.common import vapiconnect
from samples.vsphere.common.sample_util import parse_cli_args_vm

View File

@ -29,35 +29,35 @@ from samples.vsphere.vcenter.helper.vm_helper import get_vm
def setup(context):
print('Setup vcenter.vm.hardware Samples Started')
samples.vcenter.vm.hardware.cpu.setup(context)
samples.vcenter.vm.hardware.memory.setup(context)
samples.vcenter.vm.hardware.disk.setup(context)
samples.vcenter.vm.hardware.adapter.sata.setup(context)
samples.vcenter.vm.hardware.adapter.scsi.setup(context)
samples.vcenter.vm.hardware.boot.setup(context)
samples.vcenter.vm.hardware.boot_device.setup(context)
samples.vcenter.vm.hardware.cdrom.setup(context)
samples.vcenter.vm.hardware.ethernet.setup(context)
samples.vcenter.vm.hardware.floppy.setup(context)
samples.vcenter.vm.hardware.serial.setup(context)
samples.vcenter.vm.hardware.parallel.setup(context)
samples.vsphere.vcenter.vm.hardware.cpu.setup(context)
samples.vsphere.vcenter.vm.hardware.memory.setup(context)
samples.vsphere.vcenter.vm.hardware.disk.setup(context)
samples.vsphere.vcenter.vm.hardware.adapter.sata.setup(context)
samples.vsphere.vcenter.vm.hardware.adapter.scsi.setup(context)
samples.vsphere.vcenter.vm.hardware.boot.setup(context)
samples.vsphere.vcenter.vm.hardware.boot_device.setup(context)
samples.vsphere.vcenter.vm.hardware.cdrom.setup(context)
samples.vsphere.vcenter.vm.hardware.ethernet.setup(context)
samples.vsphere.vcenter.vm.hardware.floppy.setup(context)
samples.vsphere.vcenter.vm.hardware.serial.setup(context)
samples.vsphere.vcenter.vm.hardware.parallel.setup(context)
print('Setup vcenter.vm.hardware Samples Complete\n')
def cleanup():
print('Cleanup vcenter.vm.hardware Samples Started')
samples.vcenter.vm.hardware.cpu.cleanup()
samples.vcenter.vm.hardware.memory.cleanup()
samples.vcenter.vm.hardware.disk.cleanup()
samples.vcenter.vm.hardware.adapter.sata.cleanup()
samples.vcenter.vm.hardware.adapter.scsi.cleanup()
samples.vcenter.vm.hardware.boot.cleanup()
samples.vcenter.vm.hardware.boot_device.cleanup()
samples.vcenter.vm.hardware.cdrom.cleanup()
samples.vcenter.vm.hardware.ethernet.cleanup()
samples.vcenter.vm.hardware.floppy.cleanup()
samples.vcenter.vm.hardware.serial.cleanup()
samples.vcenter.vm.hardware.parallel.cleanup()
samples.vsphere.vcenter.vm.hardware.cpu.cleanup()
samples.vsphere.vcenter.vm.hardware.memory.cleanup()
samples.vsphere.vcenter.vm.hardware.disk.cleanup()
samples.vsphere.vcenter.vm.hardware.adapter.sata.cleanup()
samples.vsphere.vcenter.vm.hardware.adapter.scsi.cleanup()
samples.vsphere.vcenter.vm.hardware.boot.cleanup()
samples.vsphere.vcenter.vm.hardware.boot_device.cleanup()
samples.vsphere.vcenter.vm.hardware.cdrom.cleanup()
samples.vsphere.vcenter.vm.hardware.ethernet.cleanup()
samples.vsphere.vcenter.vm.hardware.floppy.cleanup()
samples.vsphere.vcenter.vm.hardware.serial.cleanup()
samples.vsphere.vcenter.vm.hardware.parallel.cleanup()
print('Cleanup vcenter.vm.hardware Samples Complete\n')
@ -99,18 +99,18 @@ def run():
print('#' * 79)
print('# vcenter.vm.hardware Samples')
print('#' * 79)
samples.vcenter.vm.hardware.cpu.run()
samples.vcenter.vm.hardware.memory.run()
samples.vcenter.vm.hardware.disk.run()
samples.vcenter.vm.hardware.adapter.sata.run()
samples.vcenter.vm.hardware.adapter.scsi.run()
samples.vcenter.vm.hardware.boot.run()
samples.vcenter.vm.hardware.boot_device.run()
samples.vcenter.vm.hardware.cdrom.run()
samples.vcenter.vm.hardware.ethernet.run()
samples.vcenter.vm.hardware.floppy.run()
samples.vcenter.vm.hardware.serial.run()
samples.vcenter.vm.hardware.parallel.run()
samples.vsphere.vcenter.vm.hardware.cpu.run()
samples.vsphere.vcenter.vm.hardware.memory.run()
samples.vsphere.vcenter.vm.hardware.disk.run()
samples.vsphere.vcenter.vm.hardware.adapter.sata.run()
samples.vsphere.vcenter.vm.hardware.adapter.scsi.run()
samples.vsphere.vcenter.vm.hardware.boot.run()
samples.vsphere.vcenter.vm.hardware.boot_device.run()
samples.vsphere.vcenter.vm.hardware.cdrom.run()
samples.vsphere.vcenter.vm.hardware.ethernet.run()
samples.vsphere.vcenter.vm.hardware.floppy.run()
samples.vsphere.vcenter.vm.hardware.serial.run()
samples.vsphere.vcenter.vm.hardware.parallel.run()
###########################################################################
# Virtual Hardware Upgrade Sample

View File

@ -11,7 +11,7 @@
"""
import samples.vsphere.vcenter.helper.network_helper
import samples.vcenter.vm.hardware.main
import samples.vsphere.vcenter.vm.hardware.main
import samples.vsphere.vcenter.vm.placement
import samples.vsphere.vcenter.vm.power
from samples.vsphere.common.sample_util import pp
@ -127,11 +127,11 @@ def run(context):
#
###########################################################################
if context.option['DO_SAMPLES_INCREMENTAL']:
samples.vcenter.vm.hardware.main.setup(context)
samples.vcenter.vm.hardware.main.validate(context)
samples.vcenter.vm.hardware.main.run()
samples.vsphere.vcenter.vm.hardware.main.setup(context)
samples.vsphere.vcenter.vm.hardware.main.validate(context)
samples.vsphere.vcenter.vm.hardware.main.run()
if context.option['DO_SAMPLES_CLEANUP']:
samples.vcenter.vm.hardware.main.cleanup()
samples.vsphere.vcenter.vm.hardware.main.cleanup()
# Sample cleanup