libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anthonys...@apache.org
Subject [19/50] libcloud git commit: Docs for ECS driver
Date Wed, 20 Jan 2016 03:44:07 GMT
Docs for ECS driver


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

Branch: refs/heads/trunk
Commit: 0999e520ed9e768c904f0dd7e53c7f4474fcdc50
Parents: 5473771
Author: anthony-shaw <anthony.p.shaw@gmail.com>
Authored: Sat Jan 2 07:35:55 2016 +1100
Committer: anthony-shaw <anthony.p.shaw@gmail.com>
Committed: Sat Jan 2 07:35:55 2016 +1100

----------------------------------------------------------------------
 docs/container/drivers/ecs.rst                  | 25 ++++++++++++++++++++
 .../container/ecs/instantiate_driver.py         | 12 ++++++++++
 2 files changed, 37 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/libcloud/blob/0999e520/docs/container/drivers/ecs.rst
----------------------------------------------------------------------
diff --git a/docs/container/drivers/ecs.rst b/docs/container/drivers/ecs.rst
new file mode 100644
index 0000000..45cc2f8
--- /dev/null
+++ b/docs/container/drivers/ecs.rst
@@ -0,0 +1,25 @@
+Amazon Elastic Container Service Documentation
+==============================================
+
+Elastic Container Service is a container-as-a-service feature of `AWS`_.
+
+.. figure:: /_static/images/provider_logos/aws.svg
+    :align: center
+    :width: 300
+    :target: http://aws.amazon.com/
+
+Instantiating the driver
+-------------------------------------
+        
+.. literalinclude:: /examples/container/ecs/instantiate_driver.py
+   :language: python
+   
+API Docs
+--------
+
+.. autoclass:: libcloud.container.drivers.ecs.ElasticContainerDriver
+    :members:
+    :inherited-members:
+
+
+.. _`AWS`: https://aws.amazon.com/
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/libcloud/blob/0999e520/docs/examples/container/ecs/instantiate_driver.py
----------------------------------------------------------------------
diff --git a/docs/examples/container/ecs/instantiate_driver.py b/docs/examples/container/ecs/instantiate_driver.py
new file mode 100644
index 0000000..a854745
--- /dev/null
+++ b/docs/examples/container/ecs/instantiate_driver.py
@@ -0,0 +1,12 @@
+from libcloud.container.types import Provider
+from libcloud.container.providers import get_driver
+
+import libcloud.security
+libcloud.security.VERIFY_SSL_CERT = False
+
+cls = get_driver(Provider.ECS)
+
+conn = cls(access_id='AKIAI7OR4GWEEPRIFBBA', secret='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',
region='ap-southeast-2')
+conn.connection.set_http_proxy(proxy_url='http://localhost:8888')
+
+print(conn.list_containers())


Mime
View raw message