juju.juju

Summary

Juju

Methods:

Reference

class juju.juju.Juju[source]

Bases: object

add_cloud(name, definition, replace=False)[source]

Add a user-defined cloud to Juju from among known cloud types.

Parameters:
  • name (str) – Name of cloud
  • definition (dict) – Cloud definition

Example cloud definition, as yaml:

type: openstack
auth-types: [ userpass ]
regions:
  london:
    endpoint: https://london.mycloud.com:35574/v3.0/
agree(*terms)[source]

Agree to the terms of a charm.

Parameters:*terms (str) – Terms to agree to
autoload_credentials()[source]

Finds cloud credentials and caches them for use by Juju when bootstrapping.

create_budget()[source]

Create a new budget.

get_agreements()[source]

Return list of terms to which the current user has agreed.

get_budgets()[source]

Return list of available budgets.

get_cloud(name)[source]

Get a cloud by name.

Parameters:name (str) – Name of cloud
get_clouds()[source]

Return list of all available clouds.

get_controller(name, include_passwords=False)[source]

Get a controller by name.

Parameters:
  • name (str) – Name of controller
  • include_passwords (bool) – Include passwords for accounts

(maybe move this to Cloud?)

get_controllers()[source]

Return list of all available controllers.

(maybe move this to Cloud?)

get_plans(charm_url)[source]

Return list of plans available for the specified charm.

Parameters:charm_url (str) – Charm url
register(registration_string)[source]

Register a user to a controller.

Parameters:registration_string (str) – The registration string
set_budget(name, limit)[source]

Set a monthly budget limit.

Parameters:
  • name (str) – Name of budget
  • limit (int) – Monthly limit
update_clouds()[source]

Update public cloud info available to Juju.

version()[source]

Return the Juju version.