Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
[LIBCLOUD-568] Fixing cross service OAuth scopes for Google Compute Engine / DNS / Storage #302
Prior to this fix, a user could call "get_driver()" for GCE but authorization was only allowed for the "compute" scope. With the addition of the DNS module, users calling its "get_driver()" would only be authorized to the DNS service.
This change allows scopes to be set as keyword params in get_driver() (or via secrets.py) that get propagated down to the authorization connection class. The default behavior is to grant authorization via scopes to all supported google services (compute, storage, dns).
It should be noted that the storage authorization via oauth scopes is bogus, but sets the stage for future enhancements we expect to contribute over the summer.
@wrigri, @franckcuny - A review would be much appreciated!
I've merged it into trunk with a minor fix - I've changed the default value for
The problem is that default values for arguments are created at the time of the function definition. This means that if you would mutate