The command line parameters, ca-file, key-file, and cert-file,
are deprecated. The problem is that the argument parser stores
the values for the deprecated parameters into the same attributes
used by Keystone. As a result the murano dashboard is overriding
the default values of the Keystone attributes with its own default
values. This is wrong.
The change is to ignore these parameters if they are not specified
on the command line. This will allow the Keystone client's method,
register_cli_options, to set them to the correct default values.
If the user specifies these parameters on the command line, then
we will honor them.
Change-Id: I08974f7fea0cd0cb2a906e26c9f197209c473b9b
Closes-bug: #1767144
From 2016/10, there is no domain with id 'default' in keystone.
And the user would create a domain whith name 'default', like this:
https://docs.openstack.org/mitaka/install-guide-obs/keystone-users.html
If a user do not specify domain_id and domain_name, it is appropriate to set
the default domain with name 'default'.
Change-Id: I4a8ff3e06362e8034eb84b0a26d8400fc733292a
There are two "completion" in the subcommand table: bash-completion
and bash_completion. but "bash_completion" is not in help information
and it is repeated with "bash-completion", so delete it.
Change-Id: Ia00061376daabeacd524b1afb01e2e9a585ac56f
Closes-Bug: #1670123
This fix will going to allow the usage Murano client with V3 Authentication
and multidomain environments.
Based on the latest template of RC where is used os_user_domain_name
instead of os_project_domain_id or os_user_domain_id.
if this variables doesn't exists will going to use the old method that was
working on older versions.
Change-Id: I420a6d825fe228279fb21bcdd5c172c9fc6369f5
Closes-Bug: #1600181
As part of the first community-wide goal [1], teams were asked
to remove the openstack/common package of their projects
if one existed. This was a byproduct of the old oslo-incubator
form of syncing common functionality.
The package, apiclient, was moved to a top level location
and cliutils was moved to the common module. There are no oslo
specific libraries, the recommended solution is to move it
in tree and maintain it there.
[1] http://governance.openstack.org/goals/ocata/remove-incubated-oslo-code.html
Change-Id: Ic6447da0ab3be843d231f9761d1767ed77fd81a2
Python-muranoclient uses tenant id when talking to glare to avoid
importing the same package twice. However tenant information was not
available in the CLI and tenant id defaulted to None.
This led to a situation, where it was possible to
import the same package multiple times if it was not public.
This patch fixes the issue by acquiring package information from
keystoneauth or from user-supplied values in case no-auth is enforced.
Murano dashboard was not affected by this issue.
Change-Id: I72ad006c76945bf5707172ab128a89f1f6a7b112
Closes-Bug: #1624943
Now the client can not initialise glance client,
give the warning msg like:
# murano environment-create test-env
Could not initialise glance client. Image creation will be unavailable.
Have two issue about this:
1. can not get the endpoint correctly, the get endpoint
are all murano's endpoint. This is due to when get the endpoint, if have
the endpoint, will return this endpoint directly.
2. Get the correctly endpoint, init the glance client, give the error:
TypeError: "__init__() got an unexpected keyword argument 'endpoint_type'"
This is due to 'endpoint_type' argument.
Change-Id: I87df369eecc9b79cb7173967729351f7e601edc0
Closes-bug: #1594731
Type of the endpoint (defined either as a --os-endpoint-type command
line parameter or OS_ENDPOINT_TYPE environment variable) now affects
which interface will be used when connecting to murano, glance and
glare apis.
Change-Id: I2033b2c122581b56ce063688c5eca99006a421fe
Closes-bug: #1590511
In murano client we've used glance client v2, so image update worked
incorrect. Now it's necessary to fall back to glance api v1, since v2
doesn't support some needed abilities.
Change-Id: I1b0d6c9dd4075cd44133ef5111192fa602406cf2
Closes-Bug: #1572492
This commit adds "glare" to valid choices list for option
"--murano-packages-service". This value is already supported in
client's code but not allowed in CLI.
Change-Id: I4976711d3cec1f7799f34c60500193d4ecd2a6b2
Closes-bug: #1561072
If auth-token not provided by user (via env or command-line api),
murano client should retrieve token from keystone and pass it to
glance client.
Also, glance HTTPClient ignore kwargs 'username' and 'password'.
Change-Id: Ib0ccda1a2becf4ea37cc03adff01fe5941140e9e
Closes-Bug: #1560403
If client is started with both auth token and username/password, token
gets higher priority and username/password are not used even if token
is invalid/expired.
This change switches muranoclient to DefaultCLI auth plugin which
removes some redundant code from murano and enables joint handling of
token and username/password with fallback option in case of expired or
invalid token.
This change applies only to Session mode and not legacy HTTPClient.
In addition the change contains local fix for keystoneclient bug #1551392
to avoid dependency on change Ic0fcde67fb2e6e2e5ff7506eab3fd29e25fc76e8.
Change-Id: I9ee326febb9bbdcf7279a35a696ecc58293d70f7
Closes-Bug: #1499329
Related-Bug: #1551392
Since glare has been moved to a separate service (instead of being
glance v3) muranoclient has to distinguish between glance and glare.
This commit adds a glare-url parameter, that is used for glare artefact
client
Change-Id: Ief54eb0b3e0bf6def7cee1e2d75f8aebaf113466
Closes-Bug: #1551733
Current implementation of token auth in CLI doesn't work at all.
_get_keystone_auth() is handling all types of authentication and gets
a superset of all possible inputs as kwargs.
Token authentication doesn't expect some of the arguments which results
in "__init__() got an unexpected keyword argument" errors.
This change keeps the "facade" function but passes only parameters
which are expected by Token() constructor.
Change-Id: Ib71ce1523f60df340c3b939f646c5b33bf0b146d
Closes-Bug: #1545187
OS_PROJECT_ID/OS_TENANT_ID and OS_PROJECT_NAME/OS_TENANT_NAME are
supposed to be used interchangeably. Current implementation doesn't
handle this properly. It requires "tenant" parameters to be present
even if "project" arguments are provided. The check is done twice
which is redundant, inconsistent and catches some paths which don't
require those arguments at all.
The redundant check has been removed and better of two available
checks has been moved to proper place in the code.
Change-Id: I7f435aedf40fa16af8417c21d778efc0c70979d6
Closes-Bug: #1545182
Since murano packages can now be stored in Glance Artifact Repository
the client needs to be instructed which service to query for them.
Appropriate argument was added to python client, however it was not
set from the shell for the CLI usage.
This patch adds appropriate command line argument to the shell script
and adds ability to instantiate artifacts_client to be passed to
muranoclient as an option.
Change-Id: I2aabc2c98ee001dfe42dbc5c6d50cb279a5a10ce
Closes-bug: #1537010
depending on any oslo-incubator code from another project is
dangerous. keystoneclient makes its exceptions public and it's
not recommended to use any code from
keystoneclient.openstack.common.apiclient since it's maintained
by oslo-incubator.
Change-Id: I869a351988354059931e132cea17b80147dffd0e
Murano does not get keystone endpoint when Keystone is configured to use
templated catalog
Change-Id: Ib99e649f4e2dc750043ee025fd56d2fef8486a8c
Closes-bug: #1514692
Depends-On: Id568c0a59b2e99dc946b1f2f55f6b233fd6a1b27
All clients should support keystone v3 till kilo. This patch adds
support for keystone sessions, keystone endpoint discovery and support
for the CLI to provide keystone v3 options. Also, bumped glance client
API version to 2 for the compatibility with v3 keystone API.
Change-Id: I565927db7f393c0bae41ebf9c03488f9cd966e79
Co-Authored-By: David Hu <david.hu@hp.com>
Co-Authored-By: Steve McLellan <steven.j.mclellan@gmail.com>
Closes-Bug: #1354129
Closes-Bug: #1507932
Implements: blueprint support-keystone-v3
For example:
* murano environment-list
* murano --debug environment-list
These two commands have the same informations print in the CLI at present.
* murano --debug environment-list
This command should include request and response informations in the CLI.
As bellow:
curl -i -X POST -H 'X-Auth-Token: 2d3cafec806d44fbbf44dd9f19778a1e' -H
......
Change-Id: I3da0c33adfebcbae00ccdfa9f5eaca9a2d3cb662
Closes-Bug: #1497890
We need to use parameter cacert instead of ca_file parameter
to work with CA certificates like python clients for other
OpenStack services.
Also fixed typo (after copy paste from Glance code).
Change-Id: Ibe36390aab2f2edb0fe7670f76f61caeb350d34b
Closes-Bug: #1487099
When typed the command like bellow,
some parameters help have a full stop(.), and others have not.
murano --help
--version show program's version number and exit
--include-password Send os-username and os-password to murano.
--murano-repo-url MURANO_REPO_URL
Defaults to env[MURANO_REPO_URL] or
http://storage.apps.openstack.org
Change-Id: I893654efe2aeac08fb8b2621cf29ad95ca16a113
Closes-Bug: #1488345
The Oslo libraries have moved all of their code out of the 'oslo'
namespace package into per-library packages. The namespace package was
retained during kilo for backwards compatibility, but will be removed by
the liberty-2 milestone. This change removes the use of the namespace
package, replacing it with the new package names.
The patches in the libraries will be put on hold until application
patches have landed, or L2, whichever comes first. At that point, new
versions of the libraries without namespace packages will be released as
a major version update.
Please merge this patch, or an equivalent, before L2 to avoid problems
with those library releases.
Blueprint: remove-namespace-packages
https://blueprints.launchpad.net/oslo-incubator/+spec/remove-namespace-packages
Change-Id: I5d325e9397404211df00d9e39195b63d9a2f2e76
If a package contains a file with a list of required images
check if they are present in glance and attempt to download them
if not. Supports v1 glanceclient only.
Change-Id: Ibb39fbbadef109b117094afefd383fe24de0a792
Partially implements: blueprint muranoclient-marketplace-support
Extend PackageManager.create to allow
importing from external repository by name.
Repository base URL can be set with cli option or env var.
Change-Id: I3107d9319183c11b324753bb96a8082ad7c4e9fb
Partially implements: blueprint muranoclient-marketplace-support
All clients should support keystone v3 in kilo. This patch adds
support for keystone sessions, keystone endpoint discovery and support
for the CLI to provide keystone v3 options.
Bumps python-keystoneclient to >=0.11.1 to bring in session support.
This patch was previously dependent on a separate one to add session
support but that work has been squashed into this and its review
(https://review.openstack.org/#/c/131309) will be abandoned.
Change-Id: I277008c1092b3e1abbbb3f76eb1bb36123f928be
Co-Authored-By: David Hu <david.hu@hp.com>
Closes-Bug: #1354129
Implements: blueprint support-keystone-v3
All clients should support keystone v3 in kilo. This patch adds
support for keystone sessions, keystone endpoint discovery and support
for the CLI to provide keystone v3 options.
Bumps python-keystoneclient to >=0.11.1 to bring in session support.
This patch was previously dependent on a separate one to add session
support but that work has been squashed into this and its review
(https://review.openstack.org/#/c/131309) will be abandoned.
Co-Authored-By: David Hu <david.hu@hp.com>
Change-Id: I0f4931f1e6566a7b83280302f884248c8db909c5
Implements: blueprint support-keystone-v3
* Update Openstack common (aa7c658156e1e46315cdce1d580718f30054da2f):
- apiclient
- importutils
- strutils
- jsonutils
- cliutils
- apiclient
* Switch from nosetests to testtools
* Update shell.py to the actual state
Change-Id: I2b8f3393ba3e700f65f1a794caae713f12856035
Do not output the INFO messages into the Console
Proper output of exceptions
"Wrong-Version" message displays proper service name
(we are grateful to Glance for providing a copy-paste source :)
but let's still call our service Application catalog, not Openstack Images )
Targets-blueprint: murano-cli-client
Change-Id: I484fa4d494584472f705fdffc35e2dc70f1f3e8a