Commit Graph

406 Commits

Author SHA1 Message Date
Andreas Jaeger 8011cb177c Retire repo
This repo was created by accident, use deb-python-os-client-config
instead.

Needed-By: I1ac1a06931c8b6dd7c2e73620a0302c29e605f03
Change-Id: I81894aea69b9d09b0977039623c26781093a397a
2017-04-17 19:25:35 +02:00
Monty Taylor a6840f69ff
Pop domain-id from the config if we infer values
If the user specifies a project_{name,id}, then we currently infer that
a domain_{name,id} is meant to be shorthand for user_domain_{name,id} and
project_domain_{name,id}. However, in other contexts, domain_id is a
perfectly valid value to pass to the auth plugins - such as when doing
domain-scoped activities.

The problem that was uncovered by the correction of argument precedence
is that we didn't pop the domain-id out of the root config dict, so if a
user set OS_DOMAIN_ID in the environment, we were happily setting the
user and project versions, but then leaving domain_id set as well. This
then meant that when we do the pass to pull valid arguments from the
root dict to the auth dict, we also pulled in domain_id - which led to
the error:

  AuthorizationFailure: Authentication cannot be scoped to multiple
  targets. Pick one of: project, domain, trust or unscoped

Popping the value from the root dict causes the things to work as
documented.

Change-Id: I6d208e5ec4115d2e72d30b2fedc90a81ea754d5a
2016-08-11 08:14:39 -05:00
Mathieu Gagné 600a638e74 Update Internap information
* Add sin01 and sjc01 regions
* Add support for Glance v2

Change-Id: Iaf4ad7c807a28c24040b928f65f4aadc1a234d6e
2016-08-05 15:23:48 -04:00
Jenkins 1d18b9193b Merge "Add test for precedence rules" 2016-08-05 13:59:23 +00:00
Jenkins dbd4666fb5 Merge "Pass the argparse data into to validate_auth" 2016-08-05 13:56:25 +00:00
Jenkins 572f470eca Merge "Revert "Fix precedence for pass-in options"" 2016-08-05 13:56:11 +00:00
Monty Taylor cfa87b1e7f
Add test for precedence rules
This should cover both the OSC and the ansible incoming use cases.

Change-Id: I3fdc83837692d31c5579d91892a387a5d1023785
2016-08-05 06:36:14 -05:00
Monty Taylor ddfed7f2fb
Pass the argparse data into to validate_auth
We have two contradictory precedence needs that are impossible to
satisfy because we're losing knowledge of the source of data as
we build the ultimate dict of data. If we carry the argparse data
along in a separate bucket for longer, we can check to see if it's
there so that it can win, but so that in situations where kwargs
is complex and contains both a top-level and an auth dict we don't
assume that the values that are not in the auth dict came from
argparse.

By doing this, we can establish that precedence for auth args is:
- argparse
- auth dict
- top level kwargs

Change-Id: I9eca5937077f5873f7896b6745951fb8d8c4747c
2016-08-04 16:18:42 -05:00
Monty Taylor d71a902203 Revert "Fix precedence for pass-in options"
This reverts commit 05b3c933b3.

Change-Id: I07dd701ca911cd12701519d2e6d624c69baa0848
2016-08-04 20:45:49 +00:00
Jenkins 8e4a1ebc97 Merge "Add release notes for 1.19.0 release" 2016-08-03 21:31:24 +00:00
Jenkins 8cbb5fc599 Merge "Add the new DreamCompute cloud" 2016-08-03 19:04:59 +00:00
Dean Troyer 37dcc7e8d8 Add release notes for 1.19.0 release
Change-Id: I92ffcf611d31f7a4f11e5228022ea64864823389
2016-08-03 10:44:47 -05:00
Jenkins a8a0cfe4be Merge "Fix precedence for pass-in options" 2016-08-03 15:00:01 +00:00
Monty Taylor 9c699ed3a6
Add the new DreamCompute cloud
It does things the happy way - direct routing of IPv4 and IPv6. However,
it's a respin, so we're naming it dreamcompute rather than dreamhost so
that users don't get broken by the shift.

Remove dreamhost from the docs - people looking at documentation should
be using the new region.

Change-Id: I92eb38635c4389d2e9326fab038137a673497fa8
2016-08-03 09:45:12 -05:00
Jenkins 9d4a1d81dc Merge "Refactor fix magic in get_one_cloud()" 2016-08-03 14:44:03 +00:00
Jenkins ae864d49be Merge "Add support for listing a cloud as shut down" 2016-08-03 14:43:35 +00:00
Jenkins 9f0a7a31f4 Merge "Add support for deprecating cloud profiles" 2016-08-03 14:42:41 +00:00
Dean Troyer 05b3c933b3 Fix precedence for pass-in options
The passed-in argparse Namespace is flat and does not have an 'auth'
dict, all of the auth options are in the top level.  If the loaded
dict from clouds.yaml as an 'auth' dict, that used to totally override
any passed-in options.

This is backwards.

Make the passed-in auth options always win over clouds.yaml as this is
the only way to change/override those values from the command line.

Change-Id: Ic2752a396d45deeda19a16389437679829e0844d
2016-08-02 21:15:53 -05:00
Monty Taylor 1f7ecbc3ff Update citycloud to list new regions
Frankfurt, Buffalo and Los Angeles - oh my!

Change-Id: I17d6f46de2a9af82f221b971a359d53eb471f8fa
2016-08-02 18:49:59 +00:00
Monty Taylor d9e9bb791b
Add support for listing a cloud as shut down
We've had one vendor cloud go away in the past, and there is one
existing deprecated cloud currently. Add support for providing the
user with an informative error message in the case where they
attempt to use such a cloud.

Change-Id: I894e0c0a4786e60fce1238bb2883828e89d44b01
2016-07-16 07:23:27 +08:00
Monty Taylor 481be16b8b
Add support for deprecating cloud profiles
We've had HP shut down their public cloud, and DreamHost has recent spun
up a new cloud with a different operational profile and auth_url that is
essentially a replacement cloud. That means people using the old
information need to do things, so we need to be able to communicate that
to them.

Add support for adding a deprecated status to a vendor profile, as well
as a verbose message explaining what the user may do to remediate.

Change-Id: I19b67d7cd71fba2d9da0e3a6adb2d229ead65396
2016-07-09 17:45:47 +09:00
Dean Troyer 891fa1c60f Refactor fix magic in get_one_cloud()
Extract the magic argument fixes from get_ne_cloud() so they can be
extended or modified.

Needed by OSC in order to maintain compatibility due to the much
earlier loading of auth plugins than before.  Have I mentioned
that really fouled things up for OSC?

Change-Id: I22cd890f9cbd605dcd615f82b3e65c58f52ff114
2016-06-18 08:18:18 -05:00
Jenkins 51b4cbee52 Merge "Reword the entries in the README a bit" 2016-06-02 07:34:32 +00:00
Jenkins 5d36663f1a Merge "Add shade constructor helper method" 2016-06-02 07:31:31 +00:00
Monty Taylor 4f36eca18f
Reword the entries in the README a bit
Wanted to make each section a little better, but also to start to
indicate that legacy clients should really not be your first choice.

Change-Id: I26e08d037c7b28ced22a2a0126693d7e3e779f58
2016-06-02 10:07:30 +03:00
Monty Taylor 7d63f12edd
Add shade constructor helper method
We have helper factory methods for REST Client, legacy client and
OpenStack SDK all with the same interface ... we might as well have one
for shade too. It makes documenting and talking about the simple case of
all of them easy.

Change-Id: I046da85ae4a3e2a6333223921d5ae9ce3673121d
2016-06-02 10:07:27 +03:00
Jenkins afbb28817e Merge "Rename session_client to make_rest_client" 2016-06-01 14:48:20 +00:00
Jenkins 6ea67cd458 Merge "Add helper method for OpenStack SDK constructor" 2016-06-01 14:09:33 +00:00
Monty Taylor 6a834063a2
Rename session_client to make_rest_client
While writing some docs, it became clear that session_client was just a
horrible horrible name and that I'm a bad person. Rename it so that we
can make docs that make humans happy.

Also, move the REST client section of the README up a bit.

Change-Id: I1a27853e3031489da5916308a76f19bc72185d24
2016-06-01 10:39:42 +03:00
Monty Taylor 41ac1562b5
Add helper method for OpenStack SDK constructor
openstacksdk already has a helper method for dealing with occ, but if a
user is already using the occ helper methods, there is no reason we
should not provide them an easy path to using the SDK.

Change-Id: I1040efb94385fdac0aa02ac960ba95089b954377
2016-06-01 10:26:24 +03:00
Jenkins 765c406c69 Merge "Trivial: Remove 'MANIFEST.in'" 2016-06-01 05:09:29 +00:00
Jenkins 84cd4c494d Merge "Trivial: remove openstack/common from flake8 exclude list" 2016-06-01 05:09:21 +00:00
Jenkins 583807689b Merge "drop python3.3 support in classifier" 2016-06-01 05:00:17 +00:00
Alvaro Lopez Garcia fbe1b382df Add missing "cloud" argument to _validate_auth_ksc
The function _validate_auth_ksc was missing a "cloud" parameter so the
exception formatting failed as it could not find that variable.

Change-Id: Ia1caaa29fcb14d6ce7c16de1f78bbcae6c24adb0
2016-05-23 11:40:05 +02:00
Monty Taylor 090a265669
Workaround bad required params in troveclient
troveclient requires username and password as parameters to the Client
object, but if a Session is passed (like we do) that's not needed. A
patch has been submitted to troveclient, but until that has been
released, simply send None to both parameters.

Change-Id: Ie130a4e83cceb7cab69bfbeb559493d195ef35e1
2016-05-09 05:01:09 -05:00
ChangBo Guo(gcb) 44efe9c955 Trivial: Remove 'MANIFEST.in'
Everything in this file is automatically generated by pbr.
There appears to be no good reason to keep it around.

Change-Id: I73eb120dedbdb6685862d26493fc178e6dee1353
2016-05-07 17:02:37 +08:00
ChangBo Guo(gcb) 189a604754 Trivial: remove openstack/common from flake8 exclude list
openstack/common was used to kepp copied files from
oslo-incubator, we don't use oslo-incubator stuff,
so remove it.

Change-Id: Id426c41e6ae277ed1f829820771d5ffc31a81166
2016-05-07 16:59:20 +08:00
ChangBo Guo(gcb) b0fa4383b0 drop python3.3 support in classifier
We don't run python 3.3 CI jobs anymore,
so just drop it from classifier.

Change-Id: I871269ae54067aae40f5dc06affbd4354104ee91
2016-05-07 16:56:32 +08:00
Jenkins 16ed02735b Merge "Fix formatting in readme file" 2016-05-02 21:24:21 +00:00
Jenkins 785932ad52 Merge "Remove discover from test-requirements.txt" 2016-05-02 21:23:49 +00:00
Ilya Shakhat 700ab6f282 Fix formatting in readme file
Change-Id: Ifa37d38b3c7689f703c7129459b15a367e2aafff
2016-04-22 18:01:17 +03:00
Thomas Bechtold 1028f5ad7e Remove discover from test-requirements.txt
discover is only needed for python 2.6 which is
no longer supported.

Change-Id: I8faeb05def94ac4adb2fe870fe141678dbd412ae
2016-04-11 10:31:11 +02:00
Jamie Lennox d9f9c05bfb Add version string
Use PBR to add an __version__ string to os-client-config.

Change-Id: I2293b2bd0dbbe0108e805be8ba02fbba9a5ab064
2016-04-11 16:05:27 +10:00
Monty Taylor 5605034fc3
Pull the network settings from the actual dict
Turns out self._openstack_config is not the config dict. self.config is.
Also, return names.

Change-Id: Ib2013e737b506b3a2acd7aa7b7884240c25384c5
2016-04-06 19:18:52 -04:00
Monty Taylor fdb80ad04f Clarify one-per-cloud network values
Make it clear in the docs that default_interface and nat_destination can
each be set only once per cloud.

Change-Id: Ic862b9f4dc31580c4e192f13f100428bbec7faa2
2016-04-02 09:47:52 -05:00
Monty Taylor 7c439073f3 Flesh out netowrk config list
Add support for indicating default_interface. Also, add some validation
and normalization code, some interface methods and, shockingly,
documentation.

Change-Id: Ib45b68894585ac02821d5d2376510fd7a8e8ee40
2016-04-02 09:09:54 -05:00
Monty Taylor 278a761df6 Change network info indication to a generic list
Networks can have more information than just internal or external. Notably,
if you have two private networks and you're trying to assign floating
ips, you need to know which network should be the recipient.

This should be backwards compatible with existing external_network and
internal_network options.

Change-Id: I0d469339ba00486683fcd3ce2995002fa0a576d1
2016-03-30 16:15:49 -07:00
Jenkins 9d49a7a873 Merge "Update reno for stable/mitaka" 2016-03-14 17:27:11 +00:00
Doug Hellmann a71511468e Update reno for stable/mitaka
Fix a few page titles at the same time

Change-Id: I68d082f1cad51bbe58deed6a7e4b0de122c22fc7
2016-03-11 15:06:47 -05:00
Jenkins f99445bd2f Merge "Add osic vendor profile" 2016-03-10 21:47:02 +00:00