Encountered unsupported property PolicyName
See original GitHub issueSo, I have created below Aspect to replace all the created Inline policy to Managed policy
export class modifyInlinePolicy implements cdk.IAspect {
constructor() {}
public visit(node: cdk.IConstruct): void {
if (!(node instanceof iam.Policy)) {
return;
}
const policyresource = node.node.findChild('Resource') as iam.CfnPolicy;
if (policyresource === undefined) {
return;
}
policyresource.addOverride("Type","AWS::IAM::ManagedPolicy");
}
}
And then applied this aspect to my stack
root.node.applyAspect(new modifyInlinePolicy());
Reproduction Steps
Error Log
Environment
- CLI Version : 1.12
- Framework Version: 1.12
- OS : Ubuntu
- Language : Typescript
Other
This is 🐛 Bug Report
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
How to name a custom managed policy created using ...
Currently is not possible to set a custom name for a IAM managed policy when creating it via CloudFormation. The same applies to...
Read more >AWS::IAM::ManagedPolicy - AWS CloudFormation
Creates a new managed policy for your AWS account. This operation creates a policy version with a version identifier of v1 and sets...
Read more >Encountered unsupported property UpdatePolicy on ...
I'm getting "Encountered unsupported property UpdatePolicy" on AWS::ElastiCache::ReplicationGroup. According to https://docs.aws.amazon.com/AWSCloudFormation/ ...
Read more >Encountered unsupported property - Seed.run
This error happens when the resources defined in your serverless.yml has attributes not supported by CloudFormation. Or the resource attributes exported in ...
Read more >Firehose Deployment Contradiction; RoleARN cannot be empty
... RoleARN cannot be empty; Encountered unsupported Property RoleARN ... sts:AssumeRole Policies: - PolicyName: ${self:service}-fhdelegate ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I was able to solve this issue by adding other missing properties filed.
Namely Path, description
If you want I can paste the whole template files, both with or without Escape Hatchet and applied one.