cloudaccount#

async idem_vra.states.vra.iaas.cloudaccount.present(hub, ctx, name: str, cloudAccountProperties: Any, regions: Any, cloudAccountType: Any, privateKey: Any, privateKeyId: Any, **kwargs)[source]#
Parameters:
  • cloudAccountProperties (object) – (required in body) Cloud Account specific properties supplied in as name value pairs

  • regions (array) – (required in body) A set of regions to enable provisioning on.Refer to /iaas/api/cloud- accounts/region-enumeration. ‘regionInfos’ is a required parameter for AWS, AZURE, GCP, VSPHERE, VMC, VCF cloud account types.

  • cloudAccountType (string) – (required in body) Cloud account type

  • privateKey (string) – (required in body) Secret access key or password to be used to authenticate with the cloud account. In case of AAP pass a dummy value.

  • name (string) – (required in body) A human-friendly name used as an identifier in APIs that support this option.

  • privateKeyId (string) – (required in body) Access key id or username to be used to authenticate with the cloud account

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

  • validateOnly (string) – (optional in query) If provided, it only validates the credentials in the Cloud Account Specification, and cloud account will not be created.

  • associatedCloudAccountIds (array) – (optional in body) Cloud accounts to associate with this cloud account

  • description (string) – (optional in body) A human-friendly description.

  • certificateInfo (Any) – (optional in body)

  • tags (array) – (optional in body) A set of tag keys and optional values to set on the Cloud Account

  • createDefaultZones (boolean) – (optional in body) Create default cloud zones for the enabled regions.

  • customProperties (object) – (optional in body) Additional custom properties that may be used to extend the Cloud Account. In case of AAP, provide environment property here.Example: “customProperties”: { “environment”: “aap” }

  • associatedMobilityCloudAccountIds (object) – (optional in body) Cloud Account IDs and directionalities create associations to other vSphere cloud accounts that can be used for workload mobility. ID refers to an associated cloud account, and directionality can be unidirectional or bidirectional. Only supported on vSphere cloud accounts.

async idem_vra.states.vra.iaas.cloudaccount.absent(hub, ctx, name: str, **kwargs)[source]#
Parameters:
  • p_id (string) – (required in path) The ID of the Cloud Account

  • apiVersion (string) – (optional in query) The version of the API in yyyy-MM-dd format (UTC). For versioning information refer to /iaas/api/about

async idem_vra.states.vra.iaas.cloudaccount.describe(hub, ctx)[source]#
idem_vra.states.vra.iaas.cloudaccount.is_pending(hub, ret: dict, state: str = None, **pending_kwargs)[source]#
class idem_vra.states.vra.iaas.cloudaccount.CloudaccountState(hub, ctx)[source]#

Bases: object

async present(hub, ctx, name: str, cloudAccountProperties: Any, regions: Any, cloudAccountType: Any, privateKey: Any, privateKeyId: Any, **kwargs)[source]#
async absent(hub, ctx, name: str, **kwargs)[source]#
async describe(hub, ctx)[source]#
async paginate_find(hub, ctx, **kwargs)[source]#

Paginate through all resources using their ‘find’ method.

is_pending(hub, ret: dict, state: str = None, **pending_kwargs)[source]#

State reconciliation

async remap_resource_structure(hub, ctx, obj: dict) dict[source]#
class idem_vra.states.vra.iaas.cloudaccount.CloudaccountStateImpl(hub, ctx)[source]#

Bases: CloudaccountState

async present(hub, ctx, name: str, cloudAccountProperties: Any, privateKey: Any, regions: Any, cloudAccountType: Any, privateKeyId: Any, **kwargs)[source]#
is_pending(hub, ret: dict, state: str = None, **pending_kwargs) bool[source]#

State reconciliation for cloud accounts

This method enables state specific implementation of is_pending logic, based on resource specific attribute(s). Usage ‘idem state <sls-file> –reconciler=basic’, where the reconciler attribute can be missed.

Parameters:
  • hub – The Hub into which the resolved callable will get placed.

  • ret – The returned dictionary of the last run.

  • state – The name of the state.

  • pending_kwargs – (dict, Optional) May include ‘ctx’ and ‘reruns_wo_change_count’.

Returns:

True | False

async idem_vra.states.vra.iaas.cloudaccount.remap_associated_cloudaccount_ids(hub, ctx, resource)[source]#