A consistent interface to multiple IaaS clouds; in Python http://cloudbridge.cloudve.org

nuwan_ag 4b55b1a977 Refactored - added support for objects with lifecycles. %!s(int64=10) %!d(string=hai) anos
cloudbridge 4b55b1a977 Refactored - added support for objects with lifecycles. %!s(int64=10) %!d(string=hai) anos
test c2b2a132f9 Fixed pylint warnings - avoid use of keyword id, fix up format string %!s(int64=10) %!d(string=hai) anos
.gitignore bc79e797a9 Add .DS_Store to .gitignore %!s(int64=10) %!d(string=hai) anos
.travis.yml e090981cb5 Simplified tox coverage. Fixed typos %!s(int64=10) %!d(string=hai) anos
LICENSE 1500caecff Initial commit %!s(int64=10) %!d(string=hai) anos
README.md 2574c82589 Add testing docs to README %!s(int64=10) %!d(string=hai) anos
example.py 1cfae21f31 Merge branch 'master' of https://github.com/gvlproject/cloudbridge %!s(int64=10) %!d(string=hai) anos
requirements.txt 4b12ccfb9b Added setup.py %!s(int64=10) %!d(string=hai) anos
setup.py e090981cb5 Simplified tox coverage. Fixed typos %!s(int64=10) %!d(string=hai) anos
tox.ini e655553d97 Add the option to run the test suite on a specific cloud only (set via env vars) %!s(int64=10) %!d(string=hai) anos

README.md

cloudbridge

cloudbridge provides a layer of abstraction over different cloud providers. It's a straightfoward implementation of the bridge pattern.

Code Climate Code Health Coverage Status Build Status Release Status

Usage example

from cloudbridge.providers.interfaces import CloudProviderFactory
from bunch import Bunch

config = Bunch(access_key='a_key',
               secret_key='s_key')

provider = CloudProviderFactory().create_provider(ProviderList.EC2, config)
print(provider.security.list_key_pairs())

Running tests

To run the test suite locally, install tox with pip install tox and run tox command. This will run all the tests for all the environments defined in file tox.ini. In order to properly run the tests, you should have all the environment variables listed in tox.ini file (under passenv) exported.

If you’d like to run the tests on a specific environment only, use a command like this: tox -e py27 (or python setup.py test directly). If you'd like to run the tests for a specific cloud only, you should export env var CB_TEST_PROVIDER and specify the desired provider name (e.g., ec2 or openstack) and then run the tox command.

Note that running the tests will create various cloud resources, for which you may incur costs.