A helper function that returns a strongly-typed resource validation function, used to check only resources of the specified resource class.
For example:
validateResource: validateResourceOfType(aws.s3.Bucket, (bucket, args, reportViolation) => { if (bucket.acl === "public-read" || bucket.acl === "public-read-write") { reportViolation("You cannot set public-read or public-read-write on an S3 bucket."); }}), Copy
validateResource: validateResourceOfType(aws.s3.Bucket, (bucket, args, reportViolation) => { if (bucket.acl === "public-read" || bucket.acl === "public-read-write") { reportViolation("You cannot set public-read or public-read-write on an S3 bucket."); }}),
Used to filter this check to only resources of the specified resource class.
A callback function that validates if the resource definition violates a policy.
A helper function that returns a strongly-typed resource validation function, used to check only resources of the specified resource class.
For example: