{ "info": { "author": "GridCentric", "author_email": "support@gridcentric.com", "bugtrack_url": null, "classifiers": [], "description": "Overview\n========\n\nAn extension hook for novaclient that enables it to interact with the Gridcentric endpoints.\n\nCommand line usage\n==================\n\nAfter installing the operations provided by the Gridcentric extension will be available to the \nnova command line application:\n\n # Display all of the available commands of the nova script. The gridcentric bless, launch, \n # list-blessed, list-launched, discard and gc-migrate are listed.\n $ nova help\n \n # Doing nova help on any of these commands will display how to use them in detail.\n $ nova help bless\n usage: nova bless \n \n Bless an instance\n \n Positional arguments:\n ID of the instance to bless\n \n $ nova help launch\n usage: nova launch [--target ] [--params ]\n \n \n Launch a new instance\n \n Positional arguments:\n ID of the blessed instance\n \n Optional arguments:\n --target \n The memory target of the launched instance\n --params Guest parameters to send to vms-agent\n \n $ nova help discard\n usage: nova discard \n \n Discard a blessed instance\n \n Positional arguments:\n ID of the blessed instance\n \n $ nova help gc-migrate\n usage: nova gc-migrate \n \n Migrate an instance using Gridcentric VMS\n \n Positional arguments:\n ID of the instance to migrate\n Host to migrate to\n \n $ nova help list-launched\n usage: nova list-launched \n \n List instances launched from this blessed instance.\n \n Positional arguments:\n ID of the blessed instance\n \n $ nova help list-blessed\n usage: nova list-blessed \n \n List instances blessed from this instance.\n \n Positional arguments:\n ID of the instance\n \n\nScripting usage\n===============\n\nThe novaclient hooks can also be accessed directly using the python API.\n\n user = \"admin\"\n apikey = \"admin\"\n project = \"openstackDemo\"\n authurl = \"http://localhost:5000/v2.0\" \n \n extensions = shell.OpenStackComputeShell()._discover_extensions(\"1.1\")\n novaclient = NovaClient(user, apikey, project, authurl, extensions=extensions,\n endpoint_type=shell.DEFAULT_NOVA_ENDPOINT_TYPE,\n service_type=shell.DEFAULT_NOVA_SERVICE_TYPE)\n \n def wait_for_status(server, status):\n while server.status != status:\n time.sleep(30)\n server = novaclient.gridcentric.get(server.id)\n return server\n\n def wait_until_gone(server):\n try:\n while True:\n server = novaclient.gridcentric.get(server.id)\n time.sleep(10)\n except Exception, e:\n # server is no longer there.\n pass\n\n # Boot a new server using flavor 1 and the image passed in as the first arguement.\n image_id = sys.argv[1]\n flavor_id = 1\n server = novaclient.servers.create(\"Gridcentric instance\",\n image_id,\n flavor_id)\n server = wait_for_status(server, \"ACTIVE\")\n \n # Bless the server. This will return an instance of the blessed_server. We need to\n # wait until the server becomes active.\n blessed_server = novaclient.gridcentric.bless(server)[0]\n blessed_server = wait_for_status(blessed_server, \"BLESSED\")\n \n # Launch a new server based off of the blessed one. Note that we can do this\n # by either calling launch on the server itself, or passing the server into the\n # gridcentric manager.\n launched_server = blessed_server.launch()[0]\n launched_server2 = novaclient.gridcentric.launch(blessed_server)[0]\n \n # list the servers that were launched from the blessed ones.\n for s in blessed_server.list_launched():\n print \"Server %s was launched from %s\" %(s.id, blessed_server.id)\n \n # Delete the launched servers.\n launched_server2 = wait_for_status(launched_server2, \"ACTIVE\")\n launched_server2.delete()\n launched_server = wait_for_status(launched_server, \"ACTIVE\")\n novaclient.servers.delete(launched_server)\n\n # W need to ensure that the launched instances have been deleted before discarding\n # the blessed instance.\n wait_until_gone(launched_server2)\n wait_until_gone(launched_server)\n\n # Delete the original server. Note we can delete this server\n # and keep the blessed one around.\n server.delete()\n\n # Discard the blessed server\n blessed_server.discard()\n", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://www.gridcentric.com/", "keywords": null, "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "gridcentric_python_novaclient_ext", "package_url": "https://pypi.org/project/gridcentric_python_novaclient_ext/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/gridcentric_python_novaclient_ext/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://www.gridcentric.com/" }, "release_url": "https://pypi.org/project/gridcentric_python_novaclient_ext/1.2.1533/", "requires_dist": null, "requires_python": null, "summary": "GridCentric extension for OS novaclient.", "version": "1.2.1533" }, "last_serial": 792698, "releases": { "0.2.4.351": [], "1.1.1109": [ { "comment_text": "", "digests": { "md5": "849f59477581333dc8865a7501456f8f", "sha256": "2ad6f49b9d1ec9562bface09a2a13c429bef0be61fed4f7ecbc08190fe5a90ce" }, "downloads": -1, "filename": "gridcentric_python_novaclient_ext-1.1.1109.tar.gz", "has_sig": false, "md5_digest": "849f59477581333dc8865a7501456f8f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8729, "upload_time": "2012-12-13T05:29:38", "url": "https://files.pythonhosted.org/packages/4c/41/3fc2e24689255580a8f7b6fe16bd6b5628100dc518dfa26ccbd6c29af97f/gridcentric_python_novaclient_ext-1.1.1109.tar.gz" } ], "1.1.1208": [ { "comment_text": "", "digests": { "md5": "7131822a0f63033e6a9278d5c0dc40c2", "sha256": "8834746e6bfd12f1be96c492aa820d97a6d1b7b80ef24e710db8aa05c0d2e85a" }, "downloads": -1, "filename": "gridcentric_python_novaclient_ext-1.1.1208.tar.gz", "has_sig": false, "md5_digest": "7131822a0f63033e6a9278d5c0dc40c2", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9237, "upload_time": "2013-02-01T02:52:11", "url": "https://files.pythonhosted.org/packages/ce/f1/b8851bad79f0323874993b21956df7985334da20501a26bc912fa30e82d0/gridcentric_python_novaclient_ext-1.1.1208.tar.gz" } ], "1.1.1244": [ { "comment_text": "", "digests": { "md5": "c7c6841134a69c61292e89d5bea321c7", "sha256": "92dd4fbfe4e0fefa0dedecff6ed95c6153ddb522fd32e6c728188421bcf8f591" }, "downloads": -1, "filename": "gridcentric_python_novaclient_ext-1.1.1244.tar.gz", "has_sig": false, "md5_digest": "c7c6841134a69c61292e89d5bea321c7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9323, "upload_time": "2013-02-07T20:16:43", "url": "https://files.pythonhosted.org/packages/af/e9/c390c3630cb599e4e9b5343eccee2eff85f4ba1d9c96589543747ba0ccfb/gridcentric_python_novaclient_ext-1.1.1244.tar.gz" } ], "1.2.1533": [ { "comment_text": "", "digests": { "md5": "30a268b70efd58e07b83b966b4eb24e9", "sha256": "7ffd784215b97c4b512005e2ed62224c6610d2ec045a343a00d91d697fbabb29" }, "downloads": -1, "filename": "gridcentric_python_novaclient_ext-1.2.1533.tar.gz", "has_sig": false, "md5_digest": "30a268b70efd58e07b83b966b4eb24e9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10763, "upload_time": "2013-05-03T16:41:52", "url": "https://files.pythonhosted.org/packages/34/32/13fd5fc257e21f298b5f8e956adc5b74811599388fce4dd083ffe5363477/gridcentric_python_novaclient_ext-1.2.1533.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "30a268b70efd58e07b83b966b4eb24e9", "sha256": "7ffd784215b97c4b512005e2ed62224c6610d2ec045a343a00d91d697fbabb29" }, "downloads": -1, "filename": "gridcentric_python_novaclient_ext-1.2.1533.tar.gz", "has_sig": false, "md5_digest": "30a268b70efd58e07b83b966b4eb24e9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10763, "upload_time": "2013-05-03T16:41:52", "url": "https://files.pythonhosted.org/packages/34/32/13fd5fc257e21f298b5f8e956adc5b74811599388fce4dd083ffe5363477/gridcentric_python_novaclient_ext-1.2.1533.tar.gz" } ] }