distribution#

Exec module for managing Amazon Cloudfront Distribution.

async idem_aws.exec.aws.cloudfront.distribution.get(hub, ctx, name, resource_id: str) Dict[source]#

Use an un-managed Cloudfront distribution as a data-source. Supply resource_id as a filter.

Parameters:
  • name (str) – The name of the Idem state.

  • resource_id (str) – AWS cloudfront distribution id to identify the resource.

Returns:

{"result": True|False, "comment": A message List, "ret": None|Dict}

Examples

Calling this exec module function from the cli with name and resource_id

idem exec aws.cloudfront.distribution.get name="name" resource_id="resource_id"

Calling this exec module function from within a state module in pure python.

async def state_function(hub, ctx, name, resource_id):
    before = await hub.exec.aws.cloudfront.distribution.get(
    ctx, name=name, resource_id=resource_id
)