Commit Graph

143 Commits (5cb3fc07d50d76133565717659abc886d43fc2a2)

Author SHA1 Message Date
ZhiQiang Fan 5cb3fc07d5 Support --version for heatclient
Closes-Bug: #1220524
Change-Id: Id78f7c7c78d31c0126b43f7a846f02f2542b0b7c
2013-09-04 14:29:56 +08:00
Jenkins e2cbb45036 Merge "Be backward compatible after a renaming in API" 2013-09-04 03:35:34 +00:00
Jenkins a7ffcd76d0 Merge "Fix and enable Hacking H501 warning" 2013-09-04 03:12:33 +00:00
Alex Gaynor 9d19772089 Added support for running the tests under PyPy with tox
This is a precursor to having them run under check and gate.

This also fixes a single test which fails on PyPy, the test failes at
because it assumes a ``dict`` has a particular order for its keys when
it is printed out, on PyPy dicts have a different order sometimes, the
exact ordering is not a guarnteed property of Python.

Change-Id: Ie86726a0221e5e9aa68f7303d8ca8c7acd878f65
2013-09-03 17:32:09 -07:00
Dirk Mueller d48d3587bd Fix and enable Hacking H501 warning
Enable Gating on H501. Fix the only two cases
that trigger.

Change-Id: Ib309b989df6556d7436e718e1497ce4dcacc83d6
2013-09-02 21:39:21 +02:00
Swann Croiset b95657fd15 Be backward compatible after a renaming in API
The need was introduced with the renaming of field logical_resource_id
to resource_name, so let heatclient display the good one for the two
Heat versions.

Fixes bug #1216903

Change-Id: I3e86f482a1b814a27b15be3c102727c44153221f
2013-08-29 16:37:45 +02:00
Jenkins a5d71080ef Merge "Add X-Region-Name parameter in HTTP request" 2013-08-27 15:35:58 +00:00
Swann Croiset 6f99131805 Rename event logical_resource_id to resource_name
Required by Heat change (

fixe bug #1216903

Change-Id: I77201348df401d5bafc7109bb4d032dd071468d8
2013-08-26 15:19:37 +02:00
Jenkins 0b2122eae1 Merge "Do not obscure Unauthorized error messages" 2013-08-25 23:21:18 +00:00
Nachi Ueno 1426237c38 Add X-Region-Name parameter in HTTP request
In order to specify region_name, we let client send
the OS_REGION_NAME in header file

Fixes bug 1213291

Change-Id: Ie44f700ca7e412c2504b6b8faac3fd65d4fd744b
2013-08-22 15:18:54 -07:00
Nachi Ueno e540b68416 Apply OS_REGION_NAME for endpoint selection
Even if we got OS_REGION_NAME on CLI, the value is not used.
In this commit, we apply OS_REGION_NAME for endpoint

Fixes bug 1215588

Change-Id: Ib2e2f655282b2730a9a3b7337e56993253972ce1
2013-08-22 12:24:15 -07:00
Steve Baker e81f590ea9 Do not obscure Unauthorized error messages
All Unauthorized exceptions are currently trapped and
the following message is printed:
    Invalid OpenStack Identity credentials.

This is unhelpful now that heat-api is providing structured
errors with (sometimes) helpful context for authorization failures.

This change removes this error trapping and prints the intended
error message.

Change-Id: Ibd943deb1f365e5f212225be1e675beb14accf97
2013-08-21 10:26:21 +12:00
Jenkins c0457ff0d4 Merge "Generate a template from a resource" 2013-08-13 20:57:02 +00:00
JUN JIE NAN 2d1592e934 Fix heat event list sorted order incorrect
The order is correct already if python heat client does not recorder
it. Add option to make print_list not to reorder possible, and call it
in do_event_list.

Change-Id: I3f0990aff27df39371c583d5aae3edd106542ad1
Fixes: bug #1209506
2013-08-08 16:40:17 +08:00
Monty Taylor cf4b5c82c4 Updated from global requirements
Change-Id: I1687d51bddb873549163dcf488fc40cdd9edcb29

Change-Id: Ic4a43955526fcde313ad2f2afec8fafeb87f37a6

Change-Id: Ic4a43955526fcde313ad2f2afec8fafeb87f37a6

Change-Id: Ic4a43955526fcde313ad2f2afec8fafeb87f37a6

Change-Id: If137689e5b9008c51cea16d41e648f0df490a247
2013-08-07 19:02:44 -03:00
Andrew Plunk 68999ba81f Generate a template from a resource
Setup the command line options and calls for generating
a template from an installed resource.

blueprint resource-template

Change-Id: If533bd90b1ec73bbe2603b55a0a7621879d355ec
2013-08-07 09:47:40 -05:00
Steve Baker 2c05c73a6b Remove unused Stack data method
Change-Id: Ia3fce29a58957b84f2eba33ac1b2ecfb04543939
2013-08-07 12:57:03 +12:00
Steve Baker 79dea076db Do not paginate stack list unless page_size is set
Pagination on the server has not yet been implemented, however
the client assumes it is, causing infinite recursion when paginate
is called.

With this change, no pagination is attempted unless page_size is
specified. However the 'limit' parameter is still honored, so it
is still possible to cap the total number of results returned.

heatclient users should not set page_size until pagination has been
implemented on the server. The stack list in Horizon currently
does not attempt to paginate, so is not affected.

Fixes: bug #1207839
Change-Id: I4087d3a8af48206d6ebe3edc441469464e4a401a
2013-08-07 12:56:58 +12:00
Steve Baker ea0e957978 Custom Stack get method to avoid lookup redirects
Change-Id: I15dd4e9168cba6fd05371fed097d52cbf33cb15d
2013-08-07 10:40:13 +12:00
Steve Baker 6f7239f67b Fix Stack instance delete method
The current instance delete method assumes that a Stack
instance can be passed to the manager delete method, however
the manager delete method only accepts a stack identifier.

Change-Id: I87c30be1ea43695b7e13953531ea282fd8d386f8
2013-08-07 10:37:58 +12:00
Steve Baker 18e110dbf0 Add mock as a test requirement
A project-wide concensus is forming that mox should be phased
out and mock should be encouraged for writing new tests.

This change allow mock to be used for new tests.

Change-Id: I3cdf77bbeadd419b811bddcc31f048c1c6ec38bb
2013-08-07 10:36:34 +12:00
Monty Taylor 9104cb00a1 Sync with global requirements
Change-Id: Iad82b688da07f3aa83a9850b5ea9fe2beb51019e
2013-08-05 18:43:13 -03:00
Steve Baker 529d429d49 Implement Stack status and action properties
This splits the stack_status back to an action and status,
as it is represented internally in heat-engine.

It assumes there will not be an action which contains an _.

This change is needed for code (such as tempest) which assumes a
convention of all openstack client resources having a status property.

Change-Id: If00db5508bf8469b1106cac20b8fc10f7e1a854d
2013-08-02 14:45:25 +12:00
Jenkins cae2c0fd7b Merge "Parse error object (in json format) returned by heat-api" 2013-07-30 05:09:12 +00:00
Jianing YANG 2b83260feb Parse error object (in json format) returned by heat-api
With this fix, heatclient will display a clear error message when
encounter an server-side error. Additionally, the corresponding
traceback will be displayed when "--verbose" is set.

Change-Id: I99b828465f61478a3c63fcf549d044a62523be1f
2013-07-26 20:52:04 +08:00
Jenkins e5d68a48af Merge "Set credentials headers if there is no auth token." 2013-07-22 17:23:49 +00:00
Jenkins 34993c6b69 Merge "Validate heat url is supplied for --os-no-client-auth." 2013-07-22 17:22:48 +00:00
Steve Baker 78c98ee91b Set credentials headers if there is no auth token.
Credentials will be set instead of a token for all invocations where
--os-no-client-auth is specified.

Change-Id: I35a81a9518833ce9758228266deb36c8073f9fb8
2013-07-19 14:09:34 +12:00
Steve Baker 0254ad50a2 Validate heat url is supplied for --os-no-client-auth.
Currently an obscure error is returned if --heat-url is not

Change-Id: Ia9fbb694f38e583a0cf1898f576a894d1007f697
2013-07-19 13:15:49 +12:00
Jenkins a49cf4c148 Merge "Cleanup in preperation for release." 2013-07-16 23:42:39 +00:00
Steve Baker 3f1b15cdce Cleanup in preperation for release.
Change-Id: Iaeb926b929d4f8210ebbfa310134b1fb50dce276
2013-07-17 10:42:28 +12:00
JUN JIE NAN e14758686f Display yaml format for stack deployed via hot template
Determine hot template and display yaml format for it, display json
format for others.

Change-Id: Ie8d72c222a992ee0048897d040e8bc88fcf51760
Fixes: bug #1201482
2013-07-16 14:01:14 +08:00
Jenkins b417688d21 Merge "Only set X-Auth-User, X-Auth-Key on stack create/update." 2013-07-16 03:22:00 +00:00
Angus Salkeld 710f7512bb Make the parameter checking consistent.
Make format_parameters() raise CommandError with
the same message. Rather than raise MalformedRequestBody
and then catch that and raise CommandError. This just
simplifies things.

Change-Id: Ic05af32dd916e953e6b162daccc4525cb4734a46
2013-07-16 12:24:35 +10:00
Jenkins ff2033a8c1 Merge "Rename to README.rst" 2013-07-14 22:13:07 +00:00
Dirk Mueller 43b6b0cdc4 Rename to README.rst
The content looks more like restructured text to me,
and it seems to be more common amongst OpenStack projects.

Change-Id: Iba8c21985c055f1712069a6e70d345bb920381bf
2013-07-14 18:29:08 +02:00
Dirk Mueller 011fff3416 Raise requirements to be in sync with OpenStack/Requirements
Mainly due to the testing deps being outdated. Also
fixes client capping.

Fixes LP Bug #1200214

Change-Id: I39c18144bc19189513fc4c1f9712b8938bd719cf
2013-07-14 18:16:28 +02:00
Jenkins a4208dc54d Merge "Fix "heat validate" (add needed environment option)" 2013-07-11 11:03:34 +00:00
Lin Hua Cheng cb5b027d76 Update upper bound of keystoneclient version.
This is the intermediate step so that we can update the the lower
bound of keystoneclient in openstack-requirements.

Change-Id: I1b73bfaafdf404634fc321b4e536f65b6dd65a3a
2013-07-10 14:44:59 -07:00
Angus Salkeld 2198a76839 Fix "heat validate" (add needed environment option)
since it calls template-validate it needs that same options.

Change-Id: Ic024707240af59b862146d4f478e495a93b5cd7a
2013-07-08 14:58:14 +10:00
Steve Baker 42592898c3 Only set X-Auth-User, X-Auth-Key on stack create/update.
All heat operations can be performed with only a token.

User credentials are required for stack create/update as they are
stored for later stack operations.

This change prevents credentials unnecessarily being sent over the wire.

Change-Id: I5ad18067c5db8ada9994d131e98f27af70a7ca06
2013-07-05 10:10:20 +12:00
Jenkins 9cba3dab02 Merge "Format resource required_by in resource-show." 2013-07-03 22:45:52 +00:00
Jenkins 8dd6074d88 Merge "Unit tests for pretty table special formatters." 2013-07-03 22:35:18 +00:00
Steve Baker 5320a3a49a Format resource required_by in resource-show.
This change has no effect if the resource details contains
no requires key (such as for older API versions).

Change-Id: I5bce5cf6a7c7cd3f531453cd126fb7b7b3e227ef
2013-07-04 09:18:35 +12:00
Steve Baker f535cf99d0 Unit tests for pretty table special formatters.
Change-Id: If07b4a5fc0c4ae2eecf486433134864270757945
2013-07-04 09:18:32 +12:00
Steven Hardy 0a23b8bd55 Add support for suspend/resume actions
Adds support for action-suspend and action-resume

blueprint stack-suspend-resume

Change-Id: If82e6b19756d3eae8a379141ae1f25565895e262
2013-07-03 17:04:39 +01:00
Angus Salkeld 7774ac3217 Upload provider templates referenced in the environment.
blueprint provider-upload
Change-Id: I3cbfe90dd8b4d152837666fa7f50b4b4a33bee27
2013-06-29 20:54:38 +10:00
Angus Salkeld a77fd1348d Fix all but H302 hacking rules.
Change-Id: Iac329617428b851df42579d5bd0b299d2f6e2c0a
2013-06-27 13:22:07 +10:00
Angus Salkeld 2fcd4570f3 Fix all the pep8 E* and F* errors.
Change-Id: I34bab949e4795073544c64c9796237c60ace4d65
2013-06-27 13:13:14 +10:00
Dirk Mueller 61ce60358e Fix various smaller pep8 issues
Change-Id: Icc015418e0e231311ac0a0cc507fa3f8842d8811
2013-06-20 20:43:19 +02:00