Skip to content

Commit

Permalink
fix: Enable adding event_source_name to an Event Bus to enable receiv…
Browse files Browse the repository at this point in the history
…ing events from an SaaS partner (#82)
  • Loading branch information
viorelz authored Mar 10, 2023
1 parent d1aa8f6 commit f92a78c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -458,6 +458,7 @@ No modules.
| <a name="input_create_schemas_discoverer"></a> [create\_schemas\_discoverer](#input\_create\_schemas\_discoverer) | Controls whether default schemas discoverer should be created | `bool` | `false` | no |
| <a name="input_create_targets"></a> [create\_targets](#input\_create\_targets) | Controls whether EventBridge Target resources should be created | `bool` | `true` | no |
| <a name="input_ecs_target_arns"></a> [ecs\_target\_arns](#input\_ecs\_target\_arns) | The Amazon Resource Name (ARN) of the AWS ECS Tasks you want to use as EventBridge targets | `list(string)` | `[]` | no |
| <a name="input_event_source_name"></a> [event\_source\_name](#input\_event\_source\_name) | The partner event source that the new event bus will be matched with. Must match name. | `string` | `null` | no |
| <a name="input_kinesis_firehose_target_arns"></a> [kinesis\_firehose\_target\_arns](#input\_kinesis\_firehose\_target\_arns) | The Amazon Resource Name (ARN) of the Kinesis Firehose Delivery Streams you want to use as EventBridge targets | `list(string)` | `[]` | no |
| <a name="input_kinesis_target_arns"></a> [kinesis\_target\_arns](#input\_kinesis\_target\_arns) | The Amazon Resource Name (ARN) of the Kinesis Streams you want to use as EventBridge targets | `list(string)` | `[]` | no |
| <a name="input_lambda_target_arns"></a> [lambda\_target\_arns](#input\_lambda\_target\_arns) | The Amazon Resource Name (ARN) of the Lambda Functions you want to use as EventBridge targets | `list(string)` | `[]` | no |
Expand Down
4 changes: 3 additions & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ data "aws_cloudwatch_event_bus" "this" {
resource "aws_cloudwatch_event_bus" "this" {
count = var.create && var.create_bus ? 1 : 0

name = var.bus_name
name = var.bus_name
event_source_name = try(var.event_source_name, null)

tags = var.tags
}

Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,12 @@ variable "bus_name" {
default = "default"
}

variable "event_source_name" {
description = "The partner event source that the new event bus will be matched with. Must match name."
type = string
default = null
}

variable "schemas_discoverer_description" {
description = "Default schemas discoverer description"
type = string
Expand Down

0 comments on commit f92a78c

Please sign in to comment.