@Generated(value="jsii-pacmak/1.58.0 (build f8ba112)",
date="2022-05-27T16:27:54.026Z")
public interface CustomResourceProviderProps
Example:
String serviceToken = CustomResourceProvider.getOrCreate(this, "Custom::MyCustomResourceType", CustomResourceProviderProps.builder() .codeDirectory(String.format("%s/my-handler", __dirname)) .runtime(CustomResourceProviderRuntime.NODEJS_12_X) .description("Lambda function created by the custom resource provider") .build()); CustomResource.Builder.create(this, "MyResource") .resourceType("Custom::MyCustomResourceType") .serviceToken(serviceToken) .build();
Modifier and Type | Interface and Description |
---|---|
static class |
CustomResourceProviderProps.Builder
A builder for
CustomResourceProviderProps |
static class |
CustomResourceProviderProps.Jsii$Proxy
An implementation for
CustomResourceProviderProps |
Modifier and Type | Method and Description |
---|---|
static CustomResourceProviderProps.Builder |
builder() |
java.lang.String |
getCodeDirectory()
A local file system directory with the provider's code.
|
default java.lang.String |
getDescription()
A description of the function.
|
default java.util.Map<java.lang.String,java.lang.String> |
getEnvironment()
Key-value pairs that are passed to Lambda as Environment.
|
default Size |
getMemorySize()
The amount of memory that your function has access to.
|
default java.util.List<java.lang.Object> |
getPolicyStatements()
A set of IAM policy statements to include in the inline policy of the provider's lambda function.
|
CustomResourceProviderRuntime |
getRuntime()
The AWS Lambda runtime and version to use for the provider.
|
default Duration |
getTimeout()
AWS Lambda timeout for the provider.
|
java.lang.String getCodeDirectory()
The code will be bundled into a zip asset and wired to the provider's AWS Lambda function.
CustomResourceProviderRuntime getRuntime()
default java.lang.String getDescription()
Default: - No description.
default java.util.Map<java.lang.String,java.lang.String> getEnvironment()
Default: - No environment variables.
default Size getMemorySize()
Increasing the function's memory also increases its CPU allocation.
Default: Size.mebibytes(128)
default java.util.List<java.lang.Object> getPolicyStatements()
Please note: these are direct IAM JSON policy blobs, not iam.PolicyStatement
objects like you will see in the rest of the CDK.
Default: - no additional inline policy
Example:
CustomResourceProvider provider = CustomResourceProvider.getOrCreateProvider(this, "Custom::MyCustomResourceType", CustomResourceProviderProps.builder() .codeDirectory(String.format("%s/my-handler", __dirname)) .runtime(CustomResourceProviderRuntime.NODEJS_12_X) .policyStatements(List.of(Map.of( "Effect", "Allow", "Action", "s3:PutObject*", "Resource", "*"))) .build());
default Duration getTimeout()
Default: Duration.minutes(15)
static CustomResourceProviderProps.Builder builder()