The service type overrides in get_service_type() fail if the
API version keys are not present in the config dict, which happens
when CloudConfig is created without reading defaults.
Change-Id: I8d035cfd1afc1cad01ceac7cd643568e94897e27
get_one_cloud() and get_one_cloud_osc() iterate over config
values and try to expand any variables in those values by
calling value.format(), however some config values
(e.g. password) should never have format() applied to them, not
only might that change the password but it will also cause the
format() function to raise an exception if it can not parse the
format string. Examples would be single brace (e.g. 'foo{')
which raises an ValueError because it's looking for a matching
end brace or a brace pair with a key value that cannot be found
(e.g. 'foo{bar}') which raises a KeyError.
It is not reasonsable to try to escape any braces because:
1) Escaping all braces breaks valid use of the format string syntax.
2) Trying to determine exactly which braces should be escaped and
which should be preserved is a daunting task and likely would not be
robust.
3) Some strings might look like valid format syntax but still should
be escaped (e.g. "foo{bar}", if this appeared in a password we
wouldn't escape it and there would be a key error on the 'bar' key.
4) In general passwords should never be modified, you never want to
apply formatting to them.
The right approach is to maintain a list of config values which are
excluded from having formatting applied to them. At the moment that
list just includes 'password' but perhaps down the road other
exceptions might crop up. This patch follows this approach,
the list of excluded values can easily be updated if others are
discovered.
Change-Id: I187bdec582d4c2cc6c7fda47a1538194137c616b
Closes-Bug: 1635696
Signed-off-by: John Dennis <jdennis@redhat.com>
Release notes are version independent, so remove version/release
values. We've found that projects now require the service package
to be installed in order to build release notes, and this is entirely
due to the current convention of pulling in the version information.
Release notes should not need installation in order to build, so this
unnecessary version setting needs to be removed.
This is needed for new release notes publishing, see
I56909152975f731a9d2c21b2825b972195e48ee8 and the discussion starting
at
http://lists.openstack.org/pipermail/openstack-dev/2017-November/124480.html
.
Change-Id: I8eca3dae9db90d7c592eb5bcebb2273a81d1a571
shade provides a project-template to run its functional tests against
tips of key libraries, such as os-client-config and keystoneauth.
Add these to os-client-config so we can ensure we don't break anything.
Change-Id: I9619fc09ca7c0f6fd3021d3b5194131ad172ad16
Depends-On: I544fdf515f8df38d73cee64a6de799ab384a326e
In some more complex clouds there can not only be more than one valid network
on a server that NAT can attach to, there can also be more than one valid
network from which to get a NAT address. Allow flagging a network so that it
can be found.
Change-Id: I3d8dd6d734a1013d2d4a43e11c3538c3a345820b
Breaking shade with changes to os-client-config is bad. Add shade's
unittest jobs that are configured to work against os-client-config
master.
Also move the legacy osc dsvm job here so we can remove it from
project-config.
Change-Id: Ie3e9a4deca1d74b94e810e87e130706fe15fe2c9
Depends-On: I5b411be5c5aa43535fa89a51d6099aadd7a8ea60
Using make_rest_client on clouds that put unversioned endpoints in the
catalog results in incorrectly set up adapters.
Add the plumbing to get_session_client to pass version args to
keystoneauth. Then use that from make_rest_client.
Change-Id: I69ad746f672ef0b12680e9db3c7b0c691c9f87e4
In ansible/ansible#28746 it was reported that there are times
when a p_opt is getting here that does not have a prompt
attribute. Protecting against that is fairly easy to do.
Change-Id: Ia02528f4a107893e480135bc214aa156b8684507
Closes-Bug: #1717906
If there is only one cloud and that cloud is envvars, things work as
expected. If there is only one cloud in clouds.yaml and no envvars
cloud, we throw an error, even though it should be obvious which cloud
was intended.
Change-Id: Ia49d0fb2cc7dca36476d0e5ae3fe2b2aa1209e59
The right way to update these globals is to use a lock
and ensure that nobody else is updating them at the same
time. Also update a temporary dictionary before setting
the global one so that nobody sees partial updates to the
global one.
This should help fix the thread-safety of shade (and other
tooling built ontop of this library).
Change-Id: Ie0e0369d98ba6a01edcbf447378a786eec3f13f9
OSIC has been decommissioned, remove the now useless vendor data.
Change-Id: I57c6043018e96c0069c7db777b9f585cb7d535e7
Related-Change: I2d1b0710e875bd1ebc305fb5b184b68bf18f2ef7
Set some of the new config values and enable openstackdocstheme as an
extension so it will inject values into the page context as it writes
each documentation page. This ensures the pages link to the right bug
tracker, etc.
Change-Id: Id9cc61e81aa43f4b69883d338090716005477d0a
Signed-off-by: Doug Hellmann <doug@doughellmann.com>