aws_ses_receipt_rule
Provides an SES receipt rule resource
Example Usage
# Add a header to the email and store it in S3
resource "aws_ses_receipt_rule" "store" {
name = "store"
rule_set_name = "default-rule-set"
recipients = ["[email protected]"]
enabled = true
scan_enabled = true
add_header_action {
header_name = "Custom-Header"
header_value = "Added by SES"
}
s3_action {
bucket_name = "emails"
}
}
Argument Reference
The following arguments are supported:
name- (Required) The name of the rulerule_set_name- (Required) The name of the rule setafter- (Optional) The name of the rule to place this rule afterenabled- (Optional) If true, the rule will be enabledrecipients- (Optional) A list of email addressesscan_enabled- (Optional) If true, incoming emails will be scanned for spam and virusestls_policy- (Optional) Require or Optionaladd_header_action- (Optional) A list of Add Header Action blocks. Documented below.bounce_action- (Optional) A list of Bounce Action blocks. Documented below.lambda_action- (Optional) A list of Lambda Action blocks. Documented below.s3_action- (Optional) A list of S3 Action blocks. Documented below.sns_action- (Optional) A list of SNS Action blocks. Documented below.stop_action- (Optional) A list of Stop Action blocks. Documented below.workmail_action- (Optional) A list of WorkMail Action blocks. Documented below.
Add header actions support the following:
header_name- (Required) The name of the header to addheader_value- (Required) The value of the header to addposition- (Required) The position of the action in the receipt rule
Bounce actions support the following:
message- (Required) The message to sendsender- (Required) The email address of the sendersmtp_reply_code- (Required) The RFC 5321 SMTP reply codestatus_code- (Optional) The RFC 3463 SMTP enhanced status codetopic_arn- (Optional) The ARN of an SNS topic to notifyposition- (Required) The position of the action in the receipt rule
Lambda actions support the following:
function_arn- (Required) The ARN of the Lambda function to invokeinvocation_type- (Optional) Event or RequestResponsetopic_arn- (Optional) The ARN of an SNS topic to notifyposition- (Required) The position of the action in the receipt rule
S3 actions support the following:
bucket_name- (Required) The name of the S3 bucketkms_key_arn- (Optional) The ARN of the KMS keyobject_key_prefix- (Optional) The key prefix of the S3 buckettopic_arn- (Optional) The ARN of an SNS topic to notifyposition- (Required) The position of the action in the receipt rule
SNS actions support the following:
topic_arn- (Required) The ARN of an SNS topic to notifyposition- (Required) The position of the action in the receipt rule
Stop actions support the following:
scope- (Required) The scope to applytopic_arn- (Optional) The ARN of an SNS topic to notifyposition- (Required) The position of the action in the receipt rule
WorkMail actions support the following:
organization_arn- (Required) The ARN of the WorkMail organizationtopic_arn- (Optional) The ARN of an SNS topic to notifyposition- (Required) The position of the action in the receipt rule
See the source of this document at Terraform.io