summaryrefslogtreecommitdiff
path: root/openstackclient/compute
Commit message (Collapse)AuthorAgeFilesLines
* Merge "Refactor SetService --enable/disable option"Jenkins2016-06-061-15/+23
|\
| * Refactor SetService --enable/disable optionTang Chen2016-06-041-15/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes the following: 1. --enable/disable option should follow the rules in the doc below: http://docs.openstack.org/developer/python-openstackclient/command-options.html#boolean-options 2. "--disable-resion" is specified but not "--disable", an exception is raised instead of igoring "--disable-reason" option. Change-Id: I92e9234111e661bfe7119a8e19389a87c874ab0c
* | Merge "Add newline to strings in stdout/stderr.write()"Jenkins2016-06-061-1/+1
|\ \
| * | Add newline to strings in stdout/stderr.write()Lu lei2016-06-061-1/+1
| | | | | | | | | | | | | | | | | | Function stdout/stderr.write() can't break line automatically. Change-Id: I903c2d1cc1a669adb6be5aa4eb783d3b9943e685
* | | Merge "fix keypair help msg"Jenkins2016-06-061-2/+2
|\ \ \
| * | | fix keypair help msgsunyajing2016-06-061-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | keypair delete and keypair show commands cannot work on keypair ID Change-Id: I958fcd2ed184706b28d63cc9c73a8b566e86a16c Closes-Bug:#1588701
* | | | modify server groupsunyajing2016-06-061-9/+1
| |/ / |/| | | | | | | | | | | | | | make column_headers equal to columns, to keep code consistence Change-Id: Ia96b398ad822fc5fac3753e28709c370165bda8a
* | | Merge "Support multiple argument for compute agent delete command"Jenkins2016-06-051-3/+19
|\ \ \ | |_|/ |/| |
| * | Support multiple argument for compute agent delete commandsunyajing2016-06-031-3/+19
| | | | | | | | | | | | | | | Change-Id: I3b19e4914d475b86d7e8aa8d76e62a2ac811272f Partially-Implements: blueprint multi-argument-compute
* | | Fix some missing i18n support problems in computeHuanxuan Ao2016-06-031-9/+9
| |/ |/| | | | | | | | | | | Found and Fix some missing i18n support problems in compute/client.py Change-Id: I54374f4eddafd9f80b6ccdaf8f8c30e098df105e Partial-bug: #1574965
* | Merge "Add support for removing flavor-access"Jenkins2016-06-021-5/+47
|\ \ | |/ |/|
| * Add support for removing flavor-accessHuanxuan Ao2016-06-021-5/+47
| | | | | | | | | | | | | | | | Add "--project" and "--project-domain" options in "flavor unset" command to remove flavor access. Change-Id: Ia5c5a80d9890d5af066b75b4e202647c18c7d915 Partial-Bug: #1575461
* | Merge "Fix output and error log in server.py"Jenkins2016-05-311-9/+17
|\ \ | |/ |/|
| * Fix output and error log in server.pyTang Chen2016-05-281-9/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes 2 problems: 1. The '\n' should be in the end of a message, not the beginning. i.e.: The original code was: sys.stdout.write(_('\nError deleting server')) It will make the output look like this: [root@tangchen /]# openstack server delete aaa bbb Error deleting server Error deleting server[root@tangchen /]# We change it to: sys.stdout.write(_('Error deleting server\n')) Then the output will become: [root@tangchen /]# openstack server delete aaa bbb Error deleting server Error deleting server [root@tangchen /]# which is much better. 2. Record the error in log for those who didn't. Change-Id: I38b00c2321014757970183205f95f026e20a8090
* | Merge "Add support for setting flavor-access"Jenkins2016-05-301-4/+48
|\ \
| * | Add support for setting flavor-accessHuanxuan Ao2016-05-301-4/+48
| |/ | | | | | | | | | | | | | | This patch adds "--project" option in "flavor set" command to support for setting flavor access. Change-Id: I75b473600080d8ab1dd6ad01561c4f989ed3c3bd Partial-Bug: #1575461
* | Merge "[compute] Add server backup function"Jenkins2016-05-301-0/+134
|\ \
| * | [compute] Add server backup functionjichenjc2016-05-271-0/+134
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add server backup function There is no return value for this command per following doc http://developer.openstack.org/api-ref-compute-v2.1.html#createBackup, also novaclient can't be updated now due to backward compatible issue http://lists.openstack.org/pipermail/openstack-dev/2016-March/089376.html, so we have to get the information ourselves. The Image tests were not using warlock images, so that needed to be fixed before we could completely test things like --wait. Change-Id: I30159518c4d3fdec89f15963bda641a0b03962d1
* | Support to set server stateRui Chen2016-05-281-0/+9
| | | | | | | | | | | | | | | | | | | | When a server is unexpected state, OSC don't support reset the server to active or error state, that's supported by novaclient, and it's an important command for operators, the patch implement this function. Change-Id: I3e7800feb192832b0719ef9a353945beb6bfd509 Implements: blueprint server-reset-state
* | Fix help message for "server group delete" commandHuanxuan Ao2016-05-281-1/+1
|/ | | | | | | | "Server group delete" command supported deleting multi server groups, but the help message was "Delete an existing server group", so I change it in this patch. Change-Id: I05b1a7e3f29b84b9190e7cc05c01734e3daa7a6d
* Fix i18n support for help and error messages in computeTang Chen2016-05-2411-133/+184
| | | | | Change-Id: Id6eebcb48d1b7b49b6636524506294edbc44a83f Partial-bug: #1574965
* Merge "remove #noqa from i18n imports"Jenkins2016-05-192-2/+2
|\
| * remove #noqa from i18n importsSteve Martinelli2016-05-132-2/+2
| | | | | | | | | | | | hacking checks no longer fail on `import _` Change-Id: Idd60f0a0e71e5081691eacb39e5091ab08fcce6d
* | Merge "Support X.latest format for OS_COMPUTE_API_VERSION"Jenkins2016-05-161-19/+26
|\ \ | |/ |/|
| * Support X.latest format for OS_COMPUTE_API_VERSIONRui Chen2016-04-201-19/+26
| | | | | | | | | | | | | | | | | | OSC don't support to use "X.latest" format in order to talk with the latest nova microversion API, that is very helpful shortcut usage to use new nova side features, this patch implement it. Change-Id: I87918addff1f50fbc6eb72ca82b31813330753b5 Closes-Bug: #1561838
* | Merge "Use find_resource() instead of get() in _prep_server_detail()"Jenkins2016-05-111-4/+1
|\ \
| * | Use find_resource() instead of get() in _prep_server_detail()Tang Chen2016-05-091-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is such a comment in test_server.py: # Call .get() to retrieve all of the server information # as findall(name=blah) and REST /details are not the same # and do not return flavor and image information. This is an out of date comment. There is no function named findall() in OSC now. So use find_resource() instead of get(), and remove this comment. Change-Id: I8d79afc5f341fb5caf771d905506b7f1c7a41ae8
* | | Map server power state num to meanful stringTang Chen2016-05-071-0/+5
|/ / | | | | | | | | | | | | | | | | | | | | | | | | In _prep_server_detail(), power_state is not formatted by _format_servers_list_power_state(). So when executing "server show" or "server create", the power state is represented by number. This patch map the numbers to meanful strings. This patch also adds power_state attribute to FakeServer, and improves unit tests for this attribute. Change-Id: I2ec674327de4e5133b8712ba6bb53fa5ce55e3f4
* | Make "flavor show" command to show a private flavor properlyHuanxuan Ao2016-05-021-8/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "flavor show" command could not show a private flavor by flavor name becauce it could not find a private flavor by flavor name. In "until.find_resource(parsed_args.flavor)", If parsed_args.falvor is a name of a flavor, "flavors.find(name=parsed_args.flavor)"will be called to find a flavor.But the default value of "is_public" is "Ture" in "flavors.find()" so that we can only find public flavors.If we want to find all flaovrs by flavor name,we should add "is_public=None" in "flavors.find()". So I tried to change "until.find_resource(parsed_args.flavor)" to "until.find_resource(parsed_args.flavor, is_public=None)", but then I could not find any flavor by flavor id because "is_public" is an unexpected argument of "flavors.get()" in "until.find_resource()". In this case,I think "until.find_resource()" can not find a private flavor properly,and we should combine "manager.get(flavor.id)" and "manager.find(name=flavor.name, is_public=None)" by ourselve to find a flavor. Also,this bug affects other flavor commands like "flavor set/unset/delete",so I fix them in this patch too. Change-Id: I4a4ed7b0a2f522ee04d1c3270afcda7064285c39 Closes-Bug: #1575478
* | Fix error in flavor set/unset commandHuanxuan Ao2016-04-281-2/+4
| | | | | | | | | | | | | | | | | | | | In the "flavor set/unset" command,the "flavor" parameter can be a name but can not be a id of a flavor. I think we should find a flavor by using "utils.find_resource()" in these commands. Change-Id: I5836788f7ed18813f1ebde31bb808b7c3f932b80 Closes-Bug: #1575624
* | Add "server group show" commandRui Chen2016-04-201-0/+24
| | | | | | | | | | | | | | | | | | Support compute v2 "server group show" command in OSC. Implements: blueprint nova-server-group-support Closes-Bug: #1542171 Change-Id: I1a6d103151c704bda5b67cb9a49cc43c7d9f1d6a
* | Add "server group list" commandRui Chen2016-04-201-0/+57
| | | | | | | | | | | | | | | | | | Support compute v2 "server group list" command in OSC. Implements: blueprint nova-server-group-support Partial-Bug: #1542171 Change-Id: I68b80e3c4458692472af671028cd1f939736bcb8
* | Add "server group delete" commandRui Chen2016-04-201-0/+33
| | | | | | | | | | | | | | | | | | | | Support compute v2 "server group delete" command in OSC. Implements: blueprint nova-server-group-support Partial-Bug: #1542171 Related-Bug: #1563301 Change-Id: I7d792d669b147b24dc774844cfc9dbacd60d017b
* | Add "server group create" commandRui Chen2016-04-201-0/+68
|/ | | | | | | | | Support compute v2 "server group create" command in OSC. Implements: blueprint nova-server-group-support Partial-Bug: #1542171 Change-Id: I96ffb07764d3adb715e048943cfee3b879c280f6
* Doc: Unify repeatable option commentsTang Chen2016-04-121-4/+4
| | | | | | | | | | | | There are lots of "this option can be repeated" comments in the doc, which are not consistent to other similar docs. This patch changes them to the following format: "repeat option to do something" Change-Id: I54e01053091c428bf87bb36bb95f73a0b80ab6e7
* Merge "Refactor security group rule list to use SDK"Jenkins2016-04-111-103/+0
|\
| * Refactor security group rule list to use SDKRichard Theis2016-03-281-103/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | Refactored the 'os security group rule list' command to use the SDK when neutron is enabled, but continue to use the nova client when nova network is enabled. In addition, a release note was added to document the features and fixes resulting from this refactor. Change-Id: I24d04b720102ed1c60776e1ca67d4ca20e31b663 Partial-Bug: #1519512 Implements: blueprint neutron-client
* | Log hint when --enable present with --disable-reasonRui Chen2016-04-051-2/+7
| | | | | | | | | | | | | | | | | | | | --enable and --disable-reason should be mutually exclusive in "compute service set" command, but now when they are present at the same time, --disable-reason would be ignored silently. Fix these and add some hints about --disable-reason argument is ignored in this situation. Change-Id: I43254b6bc40fcae4fd0dc3457f26fad84c267072 Closes-Bug: #1556801
* | rxtx factor should be a floatSean Dague2016-04-041-3/+3
| | | | | | | | | | | | | | The rxtx factor on compute flavors is a float in the API. OSC is currently blocking float values. Change-Id: Ifa9c14825f388d2821ff4b63ab8ae83fa9c8d88b
* | Merge "Add "aggregate unset" to osc"Jenkins2016-03-301-0/+31
|\ \
| * | Add "aggregate unset" to oscRui Chen2016-03-241-0/+31
| | | | | | | | | | | | | | | | | | | | | | | | Support "aggregate unset" command in order to remove the property of aggregate object in OSC. Change-Id: I49645135586362f0fd251f5e4a4c03eff273d9e9 Closes-Bug: #1559866
* | | Wrong param type in compute-service.rstSheel Rana2016-03-301-2/+2
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | compute-service.rst file uses 'describe' for below optional parameters 1. --long 2. --service <service> 3. --host <host> This patchset changes type of these argument to option. Change-Id: Ifd57bdf058efaeaa6cb43a7d4a60ee61ddb8de14 Closes-bug:#1563700
* | Merge "Refactor security group rule create to use SDK"Jenkins2016-03-281-65/+0
|\ \
| * | Refactor security group rule create to use SDKRichard Theis2016-03-231-65/+0
| |/ | | | | | | | | | | | | | | | | | | | | | | | | Refactored the 'os security group rule create' command to use the SDK when neutron is enabled, but continue to use the nova client when nova network is enabled. Added a release note for the change in security group rules output due to Network v2. Change-Id: I8c6c99d5272ff5d410a449f73d198d834c5cd96e Partial-Bug: #1519512 Implements: blueprint neutron-client
* | [Floating IP] Neutron support for "ip floating create" commandTang Chen2016-03-241-23/+0
|/ | | | | | | | | | | | This patch adds --subnet, --port, --floating-ip-address and --fixed-ip-address options only. Project related options will be added in another patch because it relates to identity v2 and v3, which will make the unit tests too complicated in one single patch. Change-Id: I3cce4404a114ff128b74e4596f0e847be2846b17 Partial-Bug: 1519502 Related-to: blueprint neutron-client
* Fix "server unset" document issueRui Chen2016-03-231-1/+1
| | | | | | | Fix "--property" option describe issue in "server unset" document, and update the help message to keep consistent. Change-Id: I68022a187e83fad6320365400ad2a1b0c8cf9a61
* Fix keypair create --public-keyDean Troyer2016-03-181-2/+1
| | | | | | | | | | | | | Commit Id702ccaad239b916340bb17014d1ede0a28aaec9 changed the keypair create --public-key to use io.open but incorrectly reads the file in binary mode, which causes JSON serialization to fail. The unit tests mock out io.ioen (the reason for adding it in the first place actually) so any testing for this specific problem would have to be done in functional tests...yet to come. Closes-bug: 1559125 Change-Id: I7a299a542d9df543bff43d3ea1e7907fc8c5f640
* Merge "[compute] Add set host command"Jenkins2016-03-171-0/+57
|\
| * [compute] Add set host commandjichenjc2016-02-261-0/+57
| | | | | | | | | | | | set host command is missing, add it as SetHost class. Change-Id: I7acb94150718b7150598632cbebc3d85018a0d59
* | Support "--long" option in ListServiceRui Chen2016-03-141-9/+27
| | | | | | | | | | | | | | | | Add "--long" option in ListService so that compute service disabled reason can be showed. Change-Id: I1ace8f1c4e4efe0a1a8f6710425d73eb5db9e5e1 Closes-Bug: #1556815