AWS Messaging 0.12.5Last updated in version 0.12.4
View Source
Release Notes
Simple Notification Service (SNS) Topic to Simple Queuing Service (SQS) Connection Module
This module makes it easy to subscribe a SQS to a SNS topic after both have been successfully created.
Sample Usage
- Terraform
- Terragrunt
main.tf
# ------------------------------------------------------------------------------------------------------
# DEPLOY GRUNTWORK'S SNS-SQS-CONNECTION MODULE
# ------------------------------------------------------------------------------------------------------
module "sns_sqs_connection" {
source = "git::git@github.com:gruntwork-io/terraform-aws-messaging.git//modules/sns-sqs-connection?ref=v0.12.5"
# ----------------------------------------------------------------------------------------------------
# REQUIRED VARIABLES
# ----------------------------------------------------------------------------------------------------
# The arn of the topic to subscribe to.
sns_topic_arn = <string>
# The queue arn for the Simple Queue Service (SQS).
sqs_arn = <string>
# The queue URL for the Simple Queue Service (SQS).
sqs_queue_url = <string>
# ----------------------------------------------------------------------------------------------------
# OPTIONAL VARIABLES
# ----------------------------------------------------------------------------------------------------
# (Optional) JSON String with the filter policy that will be used in the
# subscription to filter messages seen by the target resource. Refer to the
# SNS docs for more details
# https://docs.aws.amazon.com/sns/latest/dg/sns-message-filtering.html.
filter_policy = null
}
terragrunt.hcl
# ------------------------------------------------------------------------------------------------------
# DEPLOY GRUNTWORK'S SNS-SQS-CONNECTION MODULE
# ------------------------------------------------------------------------------------------------------
terraform {
source = "git::git@github.com:gruntwork-io/terraform-aws-messaging.git//modules/sns-sqs-connection?ref=v0.12.5"
}
inputs = {
# ----------------------------------------------------------------------------------------------------
# REQUIRED VARIABLES
# ----------------------------------------------------------------------------------------------------
# The arn of the topic to subscribe to.
sns_topic_arn = <string>
# The queue arn for the Simple Queue Service (SQS).
sqs_arn = <string>
# The queue URL for the Simple Queue Service (SQS).
sqs_queue_url = <string>
# ----------------------------------------------------------------------------------------------------
# OPTIONAL VARIABLES
# ----------------------------------------------------------------------------------------------------
# (Optional) JSON String with the filter policy that will be used in the
# subscription to filter messages seen by the target resource. Refer to the
# SNS docs for more details
# https://docs.aws.amazon.com/sns/latest/dg/sns-message-filtering.html.
filter_policy = null
}
Reference
- Inputs
- Outputs
Required
sns_topic_arn
stringThe arn of the topic to subscribe to.
sqs_arn
stringThe queue arn for the Simple Queue Service (SQS).
sqs_queue_url
stringThe queue URL for the Simple Queue Service (SQS).
Optional
filter_policy
string(Optional) JSON String with the filter policy that will be used in the subscription to filter messages seen by the target resource. Refer to the SNS docs for more details https://docs.aws.amazon.com/sns/latest/dg/sns-message-filtering.html.
null