{ "info": { "author": "VMware, Inc.", "author_email": "pgomez@vmware.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 1 - Planning", "Environment :: No Input/Output (Daemon)", "Intended Audience :: Developers", "Intended Audience :: Information Technology", "Intended Audience :: System Administrators", "License :: OSI Approved :: Apache Software License", "Operating System :: MacOS", "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Operating System :: Unix", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.2", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Topic :: Software Development :: Libraries :: Python Modules", "Topic :: System :: Distributed Computing" ], "description": "pyvcloud\n========\n\nPython SDK for VMware vCloud. It supports vCloud Air On Demand and Subscription. It also supports vCloud Director.\n\n``Release early, release often.``\n\nThis project is under development, the classes, methods and parameters might change over time. This README usually reflects the syntax of the latest version.\n\nSample usage:\n\nImport modules and instantiate a vCloud Air object::\n\n from pyvcloud.vcloudair import VCA\n vca = VCA(host, user, service_type, service_version, verify)\n\nLogin to a vCloud Director instance::\n\n result = vca.login(password=password, org=org)\n\nInstallation\n============\n\nThe Python SDK requires the libxml2 and libxslt libraries, see `lxml `_ for more details. On Debian/Ubuntu, you can install the libraries with this command::\n\n sudo apt-get install libxml2-dev libxslt-dev\n \nOf course, a Python dev environment is required::\n\n sudo apt-get install python-dev python-pip\n\nThe Python SDK can be installed with the following command::\n\n pip install pyvcloud\n \nUse of `virtualenv `_ is recommended.\n\n\nUsage\n=====\n\nThe SDK supports logging in to different type of services: vCloud Air Subscription, vCloud Air On Demand and vCloud Director Standalone. See the following `code `_ as an example::\n\n import time, datetime, os\n from pyvcloud.vcloudair import VCA\n\n def print_vca(vca):\n if vca:\n print 'vca token: ', vca.token\n if vca.vcloud_session:\n print 'vcloud session token: ', vca.vcloud_session.token\n print 'org name: ', vca.vcloud_session.org\n print 'org url: ', vca.vcloud_session.org_url\n print 'organization: ', vca.vcloud_session.organization\n else:\n print 'vca vcloud session: ', vca.vcloud_session\n else:\n print 'vca: ', vca\n\n def test_vcloud_session(vca, vdc, vapp):\n the_vdc = vca.get_vdc(vdc)\n for x in range(1, 5):\n print datetime.datetime.now(), the_vdc.get_name(), vca.vcloud_session.token\n the_vdc = vca.get_vdc(vdc) \n if the_vdc: print the_vdc.get_name(), vca.vcloud_session.token\n else: print False \n the_vapp = vca.get_vapp(the_vdc, vapp)\n if the_vapp: print the_vapp.me.name\n else: print False\n time.sleep(2)\n\n ### Subscription\n host='vchs.vmware.com'\n username = os.environ['VCAUSER']\n password = os.environ['PASSWORD']\n service = '85-719'\n org = 'AppServices'\n vdc = 'AppServices'\n vapp = 'cts'\n\n #sample login sequence on vCloud Air Subscription\n vca = VCA(host=host, username=username, service_type='subscription', version='5.6', verify=True)\n\n #first login, with password\n result = vca.login(password=password)\n print_vca(vca)\n\n #next login, with token, no password\n #this tests the vca token\n result = vca.login(token=vca.token)\n print_vca(vca)\n\n #uses vca.token to generate vca.vcloud_session.token\n vca.login_to_org(service, org)\n print_vca(vca)\n\n #this tests the vcloud session token\n test_vcloud_session(vca, vdc, vapp)\n\n\n ### On Demand \n host='iam.vchs.vmware.com'\n username = os.environ['VCAUSER']\n password = os.environ['PASSWORD']\n instance = 'c40ba6b4-c158-49fb-b164-5c66f90344fa'\n org = 'a6545fcb-d68a-489f-afff-2ea055104cc1'\n vdc = 'VDC1'\n vapp = 'ubu'\n\n #sample login sequence on vCloud Air On Demand\n vca = VCA(host=host, username=username, service_type='ondemand', version='5.7', verify=True)\n\n #first login, with password\n result = vca.login(password=password)\n print_vca(vca)\n\n #then login with password and instance id, this will generate a session_token\n result = vca.login_to_instance(password=password, instance=instance, token=None, org_url=None)\n print_vca(vca)\n\n #next login, with token, org and org_url, no password, it will retrieve the organization\n result = vca.login_to_instance(instance=instance, password=None, token=vca.vcloud_session.token, org_url=vca.vcloud_session.org_url)\n print_vca(vca)\n\n #this tests the vca token \n result = vca.login(token=vca.token)\n if result: print result, vca.instances\n else: print False\n\n #this tests the vcloud session token\n test_vcloud_session(vca, vdc, vapp)\n\n\n ### vCloud Director standalone\n host='p1v21-vcd.vchs.vmware.com'\n username = os.environ['VCAUSER']\n password = os.environ['PASSWORD']\n service = '85-719'\n org = 'AppServices'\n vdc = 'AppServices'\n vapp = 'cts'\n\n #sample login sequence on vCloud Director standalone\n vca = VCA(host=host, username=username, service_type='vcd', version='5.6', verify=True)\n\n #first login, with password and org name\n result = vca.login(password=password, org=org)\n print_vca(vca)\n\n #next login, with token, org and org_url, no password, it will retrieve the organization\n result = vca.login(token=vca.token, org=org, org_url=vca.vcloud_session.org_url)\n print_vca(vca)\n\n #this tests the vcloud session token\n test_vcloud_session(vca, vdc, vapp)\n\n \nDevelopment\n===========\n\nTo test the current code, check it out from github and install it with::\n\n pip install --editable .\n\nTo debug a python session, add this code::\n\n import logging\n import httplib\n httplib.HTTPConnection.debuglevel = 1\n logging.basicConfig()\n logging.getLogger().setLevel(logging.DEBUG)\n requests_log = logging.getLogger(\"requests.packages.urllib3\")\n requests_log.setLevel(logging.DEBUG)\n requests_log.propagate = True", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/vmware/pyvcloud", "keywords": "pyvcloud vcloud vcloudair vmware", "license": "License :: OSI Approved :: Apache Software License", "maintainer": null, "maintainer_email": null, "name": "pyvcloud.mishkin", "package_url": "https://pypi.org/project/pyvcloud.mishkin/", "platform": "Windows,Linux,Solaris,Mac OS-X,Unix", "project_url": "https://pypi.org/project/pyvcloud.mishkin/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/vmware/pyvcloud" }, "release_url": "https://pypi.org/project/pyvcloud.mishkin/12.5/", "requires_dist": null, "requires_python": null, "summary": "VMware vCloud Python SDK", "version": "12.5" }, "last_serial": 1790328, "releases": { "12": [ { "comment_text": "", "digests": { "md5": "e7ca23962c7f4a4376a10fef9947bebf", "sha256": "e782fea495a109be76cc8281b408467ccaf90cec18915f55ff44ffc52aa4ae3d" }, "downloads": -1, "filename": "pyvcloud.mishkin-12.tar.gz", "has_sig": false, "md5_digest": "e7ca23962c7f4a4376a10fef9947bebf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1301290, "upload_time": "2015-05-07T16:00:14", "url": "https://files.pythonhosted.org/packages/8c/d7/5d4aa20b4b785234e39b1d59291860ef10b469f8070ff1db0326c085cb2a/pyvcloud.mishkin-12.tar.gz" } ], "12.1": [ { "comment_text": "", "digests": { "md5": "872e1ae1cfee79e08afd5cd17b7ac721", "sha256": "3790e3a442569c3711dce841a645e11b5eda00c312937b058576ede2bb58e32c" }, "downloads": -1, "filename": "pyvcloud.mishkin-12.1.tar.gz", "has_sig": false, "md5_digest": "872e1ae1cfee79e08afd5cd17b7ac721", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1301780, "upload_time": "2015-05-07T20:25:13", "url": "https://files.pythonhosted.org/packages/1a/16/a2d0e8a5491e3d5d6e306bc9c4a5b85d94deed13c2043f6dda61f2296914/pyvcloud.mishkin-12.1.tar.gz" } ], "12.2": [ { "comment_text": "", "digests": { "md5": "4029b95b09b1a3bfa98232940bac475e", "sha256": "58feaf91bb4f7d572c36d4c356922d939c09bda7831338d2b095da42600b2f35" }, "downloads": -1, "filename": "pyvcloud.mishkin-12.2.tar.gz", "has_sig": false, "md5_digest": "4029b95b09b1a3bfa98232940bac475e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1301780, "upload_time": "2015-05-08T02:53:37", "url": "https://files.pythonhosted.org/packages/ab/64/0988d2981fcac231b71e066b1fe6e00881753fce16aa5bfab7135d2bbc2d/pyvcloud.mishkin-12.2.tar.gz" } ], "12.3": [ { "comment_text": "", "digests": { "md5": "843819d1816bfc9a87e04b6abbcc3f8c", "sha256": "81cae8523dcac3952fb991113faa6f601d8b70baa6304ac2471fa3a379afa6e9" }, "downloads": -1, "filename": "pyvcloud.mishkin-12.3.tar.gz", "has_sig": false, "md5_digest": "843819d1816bfc9a87e04b6abbcc3f8c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1301983, "upload_time": "2015-05-08T14:07:14", "url": "https://files.pythonhosted.org/packages/49/57/c7114d1380ac1d004597833c23837c229eb84e91b25d3d53d0903294802b/pyvcloud.mishkin-12.3.tar.gz" } ], "12.4": [ { "comment_text": "", "digests": { "md5": "9cfb89db087875c343a178ca78ededc4", "sha256": "b5a00c7e3f293b6421881776d28a3026291efba0040e5d3e0cae7f0d557c8a37" }, "downloads": -1, "filename": "pyvcloud.mishkin-12.4.tar.gz", "has_sig": false, "md5_digest": "9cfb89db087875c343a178ca78ededc4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1302022, "upload_time": "2015-05-08T19:40:58", "url": "https://files.pythonhosted.org/packages/ce/8d/9997852503049f18b716e8e5a5cf6ac0416fe10973ba71444c3391de11e2/pyvcloud.mishkin-12.4.tar.gz" } ], "12.5": [ { "comment_text": "", "digests": { "md5": "9868af29beac03b662854749542dbe3c", "sha256": "23278e5614fcfe424975f341c62b7aa2e7c3fbd2f6410a7b1521a8249fae9564" }, "downloads": -1, "filename": "pyvcloud.mishkin-12.5.tar.gz", "has_sig": false, "md5_digest": "9868af29beac03b662854749542dbe3c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1302026, "upload_time": "2015-05-19T16:19:38", "url": "https://files.pythonhosted.org/packages/31/6a/c96aea8763ba71c4e087cdb9149969a466815a19e0ff6451491100e278c1/pyvcloud.mishkin-12.5.tar.gz" } ], "15rc2": [ { "comment_text": "", "digests": { "md5": "fccb373bba2e6b6641fdfa9885e488c8", "sha256": "31c12c0517371c6fd8bb84367a51b959da810fb863fd9440c4576b5dbaa9468b" }, "downloads": -1, "filename": "pyvcloud.mishkin-15rc2-py2.7.egg", "has_sig": false, "md5_digest": "fccb373bba2e6b6641fdfa9885e488c8", "packagetype": "bdist_egg", "python_version": "2.7", "requires_python": null, "size": 3665185, "upload_time": "2015-10-28T15:15:31", "url": "https://files.pythonhosted.org/packages/13/31/2ebec5c1cd282c1a6cb12c0d97fc3bb7c24ce53bd089c8e51a110539e36e/pyvcloud.mishkin-15rc2-py2.7.egg" }, { "comment_text": "", "digests": { "md5": "d13a1f07c807731eab08a7f6d6f6c73d", "sha256": "c0a60851ecde73ff9a0864e33e9508307df6a9fe2149f44350a9c22ad49bf3be" }, "downloads": -1, "filename": "pyvcloud.mishkin-15rc2.tar.gz", "has_sig": false, "md5_digest": "d13a1f07c807731eab08a7f6d6f6c73d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1332677, "upload_time": "2015-10-28T15:14:11", "url": "https://files.pythonhosted.org/packages/3c/8d/ccea1b45bc779819f55af6a1761beb3afcbc53eca3e0158e9b635b277006/pyvcloud.mishkin-15rc2.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "9868af29beac03b662854749542dbe3c", "sha256": "23278e5614fcfe424975f341c62b7aa2e7c3fbd2f6410a7b1521a8249fae9564" }, "downloads": -1, "filename": "pyvcloud.mishkin-12.5.tar.gz", "has_sig": false, "md5_digest": "9868af29beac03b662854749542dbe3c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1302026, "upload_time": "2015-05-19T16:19:38", "url": "https://files.pythonhosted.org/packages/31/6a/c96aea8763ba71c4e087cdb9149969a466815a19e0ff6451491100e278c1/pyvcloud.mishkin-12.5.tar.gz" } ] }