Skip to content

Instantly share code, notes, and snippets.

@markilott
Created July 25, 2021 07:22
Show Gist options
  • Save markilott/eda0e9f88caa394bd8a652411109728b to your computer and use it in GitHub Desktop.
Save markilott/eda0e9f88caa394bd8a652411109728b to your computer and use it in GitHub Desktop.
CDK Custom Resource Policy for SES Email Identity
// Creating custom policy for CustomResource due to CDK bug (uses email: instead of ses: when creating actions)
const sesPolicy = new PolicyStatement({
actions: [
'ses:CreateConfigurationSet',
'ses:DeleteConfigurationSet',
'ses:CreateConfigurationSetEventDestination',
'ses:DeleteConfigurationSetEventDestination',
'ses:CreateEmailIdentity',
'ses:DeleteEmailIdentity',
],
resources: ['*'], // Global is required to Create. Delete could be restricted if required.
effect: Effect.ALLOW,
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment