You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by to...@apache.org on 2013/12/04 00:08:27 UTC

[2/2] git commit: Add new driver for Ikoula public cloud (http://express.ikoula.co.uk/cloudstack).

Add new driver for Ikoula public cloud (http://express.ikoula.co.uk/cloudstack).


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

Branch: refs/heads/trunk
Commit: 74dd726877810bfd7e4e85b822e2228ceac5fe16
Parents: 75236ec
Author: Tomaz Muraus <to...@apache.org>
Authored: Tue Dec 3 18:18:05 2013 +0100
Committer: Tomaz Muraus <to...@apache.org>
Committed: Tue Dec 3 18:18:05 2013 +0100

----------------------------------------------------------------------
 libcloud/compute/drivers/ikoula.py   | 31 +++++++++++++++++++++++++++++++
 libcloud/compute/providers.py        |  2 ++
 libcloud/compute/types.py            |  2 ++
 libcloud/test/compute/test_ikoula.py | 28 ++++++++++++++++++++++++++++
 4 files changed, 63 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/libcloud/blob/74dd7268/libcloud/compute/drivers/ikoula.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/drivers/ikoula.py b/libcloud/compute/drivers/ikoula.py
new file mode 100644
index 0000000..554c647
--- /dev/null
+++ b/libcloud/compute/drivers/ikoula.py
@@ -0,0 +1,31 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+from libcloud.compute.providers import Provider
+from libcloud.compute.drivers.cloudstack import CloudStackNodeDriver
+
+__all__ = [
+    'IkoulaNodeDriver'
+]
+
+
+class IkoulaNodeDriver(CloudStackNodeDriver):
+    type = Provider.IKOULA
+    name = 'Ikoula'
+    website = 'http://express.ikoula.co.uk/cloudstack'
+
+    # API endpoint info
+    host = 'cloudstack.ikoula.com'
+    path = '/client/api'

http://git-wip-us.apache.org/repos/asf/libcloud/blob/74dd7268/libcloud/compute/providers.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/providers.py b/libcloud/compute/providers.py
index 55c2abf..343a7f2 100644
--- a/libcloud/compute/providers.py
+++ b/libcloud/compute/providers.py
@@ -139,6 +139,8 @@ DRIVERS = {
     ('libcloud.compute.drivers.cloudframes', 'CloudFramesNodeDriver'),
     Provider.EXOSCALE:
     ('libcloud.compute.drivers.exoscale', 'ExoscaleNodeDriver'),
+    Provider.IKOULA:
+    ('libcloud.compute.drivers.ikoula', 'IkoulaNodeDriver'),
 }
 
 

http://git-wip-us.apache.org/repos/asf/libcloud/blob/74dd7268/libcloud/compute/types.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/types.py b/libcloud/compute/types.py
index a421bab..bc74b1d 100644
--- a/libcloud/compute/types.py
+++ b/libcloud/compute/types.py
@@ -73,6 +73,7 @@ class Provider(object):
     :cvar ABIQUO: Abiquo driver
     :cvar NEPHOSCALE: NephoScale driver
     :cvar EXOSCALE: Exoscale driver.
+    :cvar IKOULA: Ikoula driver.
     """
     DUMMY = 'dummy'
     EC2 = 'ec2_us_east'
@@ -116,6 +117,7 @@ class Provider(object):
     NEPHOSCALE = 'nephoscale'
     CLOUDFRAMES = 'cloudframes'
     EXOSCALE = 'exoscale'
+    IKOULA = 'ikoula'
 
     # Deprecated constants which are still supported
     EC2_US_EAST = 'ec2_us_east'

http://git-wip-us.apache.org/repos/asf/libcloud/blob/74dd7268/libcloud/test/compute/test_ikoula.py
----------------------------------------------------------------------
diff --git a/libcloud/test/compute/test_ikoula.py b/libcloud/test/compute/test_ikoula.py
new file mode 100644
index 0000000..cda92b6
--- /dev/null
+++ b/libcloud/test/compute/test_ikoula.py
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to You under the Apache License, Version 2.0
+# (the "License"); you may not use this file except in compliance with
+# the License.  You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+import sys
+
+from libcloud.compute.drivers.ikoula import IkoulaNodeDriver
+from libcloud.test.compute.test_cloudstack import CloudStackCommonTestCase
+
+from libcloud.test import unittest
+
+
+class ExoscaleNodeDriverTestCase(CloudStackCommonTestCase, unittest.TestCase):
+    driver_klass = IkoulaNodeDriver
+
+if __name__ == '__main__':
+    sys.exit(unittest.main())