CloudInit#

class CloudInit(datasource_type=None, metadata=None, cloud_init_script=None, *args, **kwargs)#

Bases: object

If this field is set, the guest will be customized using cloud-init. Either user_data or custom_key_values should be provided. If custom_key_ves are provided then the user data will be generated using these key-value pairs.

Parameters:
  • datasource_type – (datasource_type)

  • metadata (max=32000 chars) – (metadata) The contents of the meta_data configuration for cloud-init. This can be formatted as YAML or JSON. The value must be base64 encoded.

  • cloud_init_script – (cloud_init_script) The script to use for cloud-init.

property cloud_init_script#

The script to use for cloud-init.

Type:

Userdata | CustomKeyValues

property datasource_type#
Type:

CloudInitDataSourceType

property metadata#

The contents of the meta_data configuration for cloud-init. This can be formatted as YAML or JSON. The value must be base64 encoded.

Type:

str

to_dict()#

Returns the model properties as a dictionary

to_str()#

Returns the string representation of the model