Skip to content

TinxHQ/wazo-deployd-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

wazo-deployd-client

A python client library to access wazo-deployd

Usage

Creating a client

from wazo_deployd_client import Client
client = Client('localhost', verify_certificate=False)

Config

client.config.get()

Status

client.status.check()

Providers

List providers

client.providers.list(recurse=True)
client.providers.list(tenant_uuid=tenant_uuid)

Get informations provider

client.providers.list_images()
client.providers.list_locations()
client.providers.list_key_pairs()
client.providers.list_sizes()
client.providers.list_subnets()
client.providers.list_networks()
client.providers.list_regions()

List platforms

client.providers.platforms.list()

Create a provider

client.providers.create(provider_data)
client.providers.create(provider_data, tenant_uuid=tenant_uuid)

Get a provider

client.providers.get(provider_uuid)
client.providers.get(provider_uuid, tenant_uuid=tenant_uuid)

Update a provider

client.providers.update(provider_uuid, provider_data)
client.providers.update(provider_uuid, provider_data, tenant_uuid=tenant_uuid)

Delete a provider

client.providers.delete(provider_uuid)
client.providers.delete(provider_uuid, tenant_uuid=tenant_uuid)

Instances

List instances

client.instances.list(limit=1, offset=1, order='name', direction='desc')
client.instances.list(tenant_uuid=tenant_uuid)
client.instances.list()

# List by provider
client.instances.list(provider_uuid=provider_uuid)
client.instances.list(provider_uuid=provider_uuid, tenant_uuid=tenant_uuid)

Create an instance

client.instances.create(provider_uuid, instance_data)
client.instances.create(provider_uuid, instance_data, tenant_uuid=tenant_uuid)

Register an instance

client.instances.register(instance_data)
client.instances.register(instance_data, tenant_uuid=tenant_uuid)

Get an instance

client.instances.get(instance_uuid)
client.instances.get(instance_uuid, tenant_uuid=tenant_uuid)

Get an instance wazo

client.instances.get_wazo(instance_uuid)
client.instances.get_wazo(instance_uuid, tenant_uuid=tenant_uuid)

Update an instance

client.instances.update(instance_uuid, instance_data)
client.instances.update(instance_uuid, instance_data, tenant_uuid=tenant_uuid)

Delete an instance

client.instances.delete(provider_uuid, instance_uuid)
client.instances.delete(provider_uuid, instance_uuid, tenant_uuid=tenant_uuid)

Unregister an instance

client.instances.unregister(instance_uuid)
client.instances.unregister(instance_uuid, tenant_uuid=tenant_uuid)

Register a credential

client.instances.create_credential(instance_uuid, credential_data)
client.instances.create_credential(instance_uuid, credential_data, tenant_uuid=tenant_uuid)

Get a credential

client.instances.get_credential(instancr_uuid, credential_uuid)
client.instances.get_credential(instance_uuid, credential_uuid, tenant_uuid=tenant_uuid)

Update a credential

client.instances.update_credential(instance_uuid, credential_uuid, credential_data)
client.instances.update_credential(instance_uuid, credential_uuid, credential_data, tenant_uuid=tenant_uuid)

Delete a credential

client.instances.delete_credential(instance_uuid, credential_uuid)
client.instances.delete_credential(instance_uuid, credential_uuid, tenant_uuid=tenant_uuid)

Debian package

Follow the following steps to build a debian package for wazo-deployd-client manually.

  1. Copy the source directory to a machine with all dependencies installed
rsync -av . <builder-host>:~/wazo-deployd-client
  1. On the host, increment the changelog
dch -i
  1. Build the package
dpkg-buildpackage -us -uc