`DeployTimeSubstitutedFile` is an extension of `BucketDeployment` that allows users to upload individual files and specify to make substitutions in the file.
import { DeployTimeSubstitutedFile } from 'aws-cdk-lib/aws-s3-deployment';Or use the module namespace:
import * as s3_deployment from 'aws-cdk-lib/aws-s3-deployment';
// s3_deployment.DeployTimeSubstitutedFileConfiguration passed to the constructor as DeployTimeSubstitutedFileProps.
destinationBucketRequiredIBucketThe S3 bucket to sync the contents of the zip file to.
sourceRequiredstringPath to the user's local file.
substitutionsRequired{ [key: string]: string }User-defined substitutions to make in the file. Placeholders in the user's local file must be specified with double curly brackets and spaces. For example, if you use the key 'xxxx' in the file, it must be written as: {{ xxxx }} to be recognized by the construct as a substitution.
destinationKeyOptionalstringThe object key in the destination bucket where the processed file would be written to.
Default: - Fingerprint of the file content would be used as object key
roleOptionalIRoleExecution role associated with this function.
Default: - A role is automatically created
Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.
Subscribe to Newsletteraws-s3-deployment