CfnFunctionProps

class aws_cdk.aws_sam.CfnFunctionProps(*, architectures=None, assume_role_policy_document=None, auto_publish_alias=None, auto_publish_code_sha256=None, code_signing_config_arn=None, code_uri=None, dead_letter_queue=None, deployment_preference=None, description=None, environment=None, ephemeral_storage=None, event_invoke_config=None, events=None, file_system_configs=None, function_name=None, function_url_config=None, handler=None, image_config=None, image_uri=None, inline_code=None, kms_key_arn=None, layers=None, memory_size=None, package_type=None, permissions_boundary=None, policies=None, provisioned_concurrency_config=None, reserved_concurrent_executions=None, role=None, runtime=None, tags=None, timeout=None, tracing=None, version_description=None, vpc_config=None)

Bases: object

Properties for defining a CfnFunction.

Parameters:
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_sam as sam

# assume_role_policy_document: Any

cfn_function_props = sam.CfnFunctionProps(
    architectures=["architectures"],
    assume_role_policy_document=assume_role_policy_document,
    auto_publish_alias="autoPublishAlias",
    auto_publish_code_sha256="autoPublishCodeSha256",
    code_signing_config_arn="codeSigningConfigArn",
    code_uri="codeUri",
    dead_letter_queue=sam.CfnFunction.DeadLetterQueueProperty(
        target_arn="targetArn",
        type="type"
    ),
    deployment_preference=sam.CfnFunction.DeploymentPreferenceProperty(
        alarms=["alarms"],
        enabled=False,
        hooks=sam.CfnFunction.HooksProperty(
            post_traffic="postTraffic",
            pre_traffic="preTraffic"
        ),
        role="role",
        type="type"
    ),
    description="description",
    environment=sam.CfnFunction.FunctionEnvironmentProperty(
        variables={
            "variables_key": "variables"
        }
    ),
    ephemeral_storage=sam.CfnFunction.EphemeralStorageProperty(
        size=123
    ),
    event_invoke_config=sam.CfnFunction.EventInvokeConfigProperty(
        destination_config=sam.CfnFunction.EventInvokeDestinationConfigProperty(
            on_failure=sam.CfnFunction.DestinationProperty(
                destination="destination",

                # the properties below are optional
                type="type"
            ),
            on_success=sam.CfnFunction.DestinationProperty(
                destination="destination",

                # the properties below are optional
                type="type"
            )
        ),
        maximum_event_age_in_seconds=123,
        maximum_retry_attempts=123
    ),
    events={
        "events_key": sam.CfnFunction.EventSourceProperty(
            properties=sam.CfnFunction.AlexaSkillEventProperty(
                skill_id="skillId"
            ),
            type="type"
        )
    },
    file_system_configs=[sam.CfnFunction.FileSystemConfigProperty(
        arn="arn",
        local_mount_path="localMountPath"
    )],
    function_name="functionName",
    function_url_config=sam.CfnFunction.FunctionUrlConfigProperty(
        auth_type="authType",

        # the properties below are optional
        cors="cors",
        invoke_mode="invokeMode"
    ),
    handler="handler",
    image_config=sam.CfnFunction.ImageConfigProperty(
        command=["command"],
        entry_point=["entryPoint"],
        working_directory="workingDirectory"
    ),
    image_uri="imageUri",
    inline_code="inlineCode",
    kms_key_arn="kmsKeyArn",
    layers=["layers"],
    memory_size=123,
    package_type="packageType",
    permissions_boundary="permissionsBoundary",
    policies="policies",
    provisioned_concurrency_config=sam.CfnFunction.ProvisionedConcurrencyConfigProperty(
        provisioned_concurrent_executions="provisionedConcurrentExecutions"
    ),
    reserved_concurrent_executions=123,
    role="role",
    runtime="runtime",
    tags={
        "tags_key": "tags"
    },
    timeout=123,
    tracing="tracing",
    version_description="versionDescription",
    vpc_config=sam.CfnFunction.VpcConfigProperty(
        security_group_ids=["securityGroupIds"],
        subnet_ids=["subnetIds"]
    )
)

Attributes

architectures

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-architectures

Type:

see

assume_role_policy_document

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-assumerolepolicydocument

Type:

see

auto_publish_alias

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-autopublishalias

Type:

see

auto_publish_code_sha256

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-autopublishcodesha256

Type:

see

code_signing_config_arn

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-codesigningconfigarn

Type:

see

code_uri

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-codeuri

Type:

see

dead_letter_queue

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-deadletterqueue

Type:

see

deployment_preference

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-deploymentpreference

Type:

see

description

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-description

Type:

see

environment

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-environment

Type:

see

ephemeral_storage

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-ephemeralstorage

Type:

see

event_invoke_config

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-eventinvokeconfig

Type:

see

events

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-events

Type:

see

file_system_configs

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-filesystemconfigs

Type:

see

function_name

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-functionname

Type:

see

function_url_config

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-functionurlconfig

Type:

see

handler

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-handler

Type:

see

image_config

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-imageconfig

Type:

see

image_uri

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-imageuri

Type:

see

inline_code

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-inlinecode

Type:

see

kms_key_arn

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-kmskeyarn

Type:

see

layers

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-layers

Type:

see

memory_size

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-memorysize

Type:

see

package_type

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-packagetype

Type:

see

permissions_boundary

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-permissionsboundary

Type:

see

policies

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-policies

Type:

see

provisioned_concurrency_config

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-provisionedconcurrencyconfig

Type:

see

reserved_concurrent_executions

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-reservedconcurrentexecutions

Type:

see

role

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-role

Type:

see

runtime

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-runtime

Type:

see

tags

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-tags

Type:

see

timeout

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-timeout

Type:

see

tracing

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-tracing

Type:

see

version_description

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-versiondescription

Type:

see

vpc_config

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-serverless-function.html#cfn-serverless-function-vpcconfig

Type:

see