CfnComponentVersionProps
- class aws_cdk.aws_greengrassv2.CfnComponentVersionProps(*, inline_recipe=None, lambda_function=None, tags=None)
Bases:
object
Properties for defining a
CfnComponentVersion
.- Parameters:
inline_recipe (
Optional
[str
]) – The recipe to use to create the component. The recipe defines the component’s metadata, parameters, dependencies, lifecycle, artifacts, and platform compatibility. You must specify eitherInlineRecipe
orLambdaFunction
.lambda_function (
Union
[IResolvable
,LambdaFunctionRecipeSourceProperty
,Dict
[str
,Any
],None
]) – The parameters to create a component from a Lambda function. You must specify eitherInlineRecipe
orLambdaFunction
.tags (
Optional
[Mapping
[str
,str
]]) – Application-specific metadata to attach to the component version. You can use tags in IAM policies to control access to AWS IoT Greengrass resources. You can also use tags to categorize your resources. For more information, see Tag your AWS IoT Greengrass Version 2 resources in the AWS IoT Greengrass V2 Developer Guide . ThisJson
property type is processed as a map of key-value pairs. It uses the following format, which is different from mostTags
implementations in AWS CloudFormation templates:: “Tags”: { “KeyName0”: “value”, “KeyName1”: “value”, “KeyName2”: “value” }
- See:
- 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_greengrassv2 as greengrassv2 cfn_component_version_props = greengrassv2.CfnComponentVersionProps( inline_recipe="inlineRecipe", lambda_function=greengrassv2.CfnComponentVersion.LambdaFunctionRecipeSourceProperty( component_dependencies={ "component_dependencies_key": greengrassv2.CfnComponentVersion.ComponentDependencyRequirementProperty( dependency_type="dependencyType", version_requirement="versionRequirement" ) }, component_lambda_parameters=greengrassv2.CfnComponentVersion.LambdaExecutionParametersProperty( environment_variables={ "environment_variables_key": "environmentVariables" }, event_sources=[greengrassv2.CfnComponentVersion.LambdaEventSourceProperty( topic="topic", type="type" )], exec_args=["execArgs"], input_payload_encoding_type="inputPayloadEncodingType", linux_process_params=greengrassv2.CfnComponentVersion.LambdaLinuxProcessParamsProperty( container_params=greengrassv2.CfnComponentVersion.LambdaContainerParamsProperty( devices=[greengrassv2.CfnComponentVersion.LambdaDeviceMountProperty( add_group_owner=False, path="path", permission="permission" )], memory_size_in_kb=123, mount_ro_sysfs=False, volumes=[greengrassv2.CfnComponentVersion.LambdaVolumeMountProperty( add_group_owner=False, destination_path="destinationPath", permission="permission", source_path="sourcePath" )] ), isolation_mode="isolationMode" ), max_idle_time_in_seconds=123, max_instances_count=123, max_queue_size=123, pinned=False, status_timeout_in_seconds=123, timeout_in_seconds=123 ), component_name="componentName", component_platforms=[greengrassv2.CfnComponentVersion.ComponentPlatformProperty( attributes={ "attributes_key": "attributes" }, name="name" )], component_version="componentVersion", lambda_arn="lambdaArn" ), tags={ "tags_key": "tags" } )
Attributes
- inline_recipe
The recipe to use to create the component.
The recipe defines the component’s metadata, parameters, dependencies, lifecycle, artifacts, and platform compatibility.
You must specify either
InlineRecipe
orLambdaFunction
.
- lambda_function
The parameters to create a component from a Lambda function.
You must specify either
InlineRecipe
orLambdaFunction
.
- tags
Application-specific metadata to attach to the component version.
You can use tags in IAM policies to control access to AWS IoT Greengrass resources. You can also use tags to categorize your resources. For more information, see Tag your AWS IoT Greengrass Version 2 resources in the AWS IoT Greengrass V2 Developer Guide .
This
Json
property type is processed as a map of key-value pairs. It uses the following format, which is different from mostTags
implementations in AWS CloudFormation templates:"Tags": { "KeyName0": "value", "KeyName1": "value", "KeyName2": "value" }