libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From quent...@apache.org
Subject [1/5] libcloud git commit: Document changing signature version.
Date Mon, 16 Oct 2017 06:28:30 GMT
Repository: libcloud
Updated Branches:
  refs/heads/trunk 820ff6f70 -> be3d1e18a


Document changing signature version.

Signed-off-by: Quentin Pradet <quentinp@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/be3d1e18
Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/be3d1e18
Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/be3d1e18

Branch: refs/heads/trunk
Commit: be3d1e18ac18a694a453a004d3f72ac7e9867c4e
Parents: 6d01dda
Author: Andrew Starr-Bochicchio <a.starr.b@gmail.com>
Authored: Sun Oct 15 13:06:06 2017 -0400
Committer: Quentin Pradet <quentinp@apache.org>
Committed: Mon Oct 16 10:24:58 2017 +0400

----------------------------------------------------------------------
 docs/examples/storage/digitalocean_spaces/v4sig.py | 8 ++++++++
 docs/storage/drivers/digitalocean_spaces.rst       | 7 +++++++
 2 files changed, 15 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/libcloud/blob/be3d1e18/docs/examples/storage/digitalocean_spaces/v4sig.py
----------------------------------------------------------------------
diff --git a/docs/examples/storage/digitalocean_spaces/v4sig.py b/docs/examples/storage/digitalocean_spaces/v4sig.py
new file mode 100644
index 0000000..d370b33
--- /dev/null
+++ b/docs/examples/storage/digitalocean_spaces/v4sig.py
@@ -0,0 +1,8 @@
+from libcloud.storage.types import Provider
+from libcloud.storage.providers import get_driver
+
+cls = get_driver(Provider.DIGITALOCEAN_SPACES)
+
+driver = cls(key='DO_ACCESS_KEY',
+             secret='DO_SECRET_KEY',
+             signature_version='4')

http://git-wip-us.apache.org/repos/asf/libcloud/blob/be3d1e18/docs/storage/drivers/digitalocean_spaces.rst
----------------------------------------------------------------------
diff --git a/docs/storage/drivers/digitalocean_spaces.rst b/docs/storage/drivers/digitalocean_spaces.rst
index 919cdc8..b8739fc 100644
--- a/docs/storage/drivers/digitalocean_spaces.rst
+++ b/docs/storage/drivers/digitalocean_spaces.rst
@@ -20,6 +20,13 @@ below.
 .. literalinclude:: /examples/storage/digitalocean_spaces/instantiate.py
    :language: python
 
+Spaces supports both the v2 and v4 AWS signature types. By default, this driver
+will use v2. You can configure it to use v4 by passing the ``signature_version``
+argument when instantiating the driver as shown below.
+
+.. literalinclude:: /examples/storage/digitalocean_spaces/v4sig.py
+   :language: python
+
 Specifying canned ACLs
 ~~~~~~~~~~~~~~~~~~~~~~
 


Mime
View raw message