Skip to content

Commit

Permalink
fix: batch rule names
Browse files Browse the repository at this point in the history
  • Loading branch information
Wi11Shell committed Oct 8, 2024
1 parent 800787b commit 436062d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
4 changes: 2 additions & 2 deletions infra/terraform/modules/service/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_assets_version"></a> [assets\_version](#input\_assets\_version) | The version of the assets | `string` | n/a | yes |
| <a name="input_batch"></a> [batch](#input\_batch) | Configuration for the batch process | <pre>object({<br> version = string<br> repository = string<br> subnet_ids = list(string)<br> task_iam_role_statements = list(object({<br> effect = string<br> actions = list(string)<br> resources = list(string)<br> }))<br> jobs = list(object({<br> name = string<br> commands = list(string)<br> cpu = optional(number, 1)<br> memory = optional(number, 2048)<br> timeout = optional(number, 300)<br> schedule = optional(string, "")<br> }))<br> })</pre> | n/a | yes |
| <a name="input_batch"></a> [batch](#input\_batch) | Configuration for the batch process | <pre>object({<br/> version = string<br/> repository = string<br/> subnet_ids = list(string)<br/> task_iam_role_statements = list(object({<br/> effect = string<br/> actions = list(string)<br/> resources = list(string)<br/> }))<br/> jobs = list(object({<br/> name = string<br/> commands = list(string)<br/> cpu = optional(number, 1)<br/> memory = optional(number, 2048)<br/> timeout = optional(number, 300)<br/> schedule = optional(string, "")<br/> }))<br/> })</pre> | n/a | yes |
| <a name="input_domain_name"></a> [domain\_name](#input\_domain\_name) | The domain name for the environment | `string` | n/a | yes |
| <a name="input_elasticache_url"></a> [elasticache\_url](#input\_elasticache\_url) | The URL of the Elasticache cluster | `string` | n/a | yes |
| <a name="input_environment"></a> [environment](#input\_environment) | The environment to deploy to | `string` | n/a | yes |
| <a name="input_legacy_environment"></a> [legacy\_environment](#input\_legacy\_environment) | The legacy environment to deploy use | `string` | n/a | yes |
| <a name="input_services"></a> [services](#input\_services) | The services to deploy | <pre>map(object({<br> version = string<br> repository = string<br> cpu = number<br> memory = number<br> task_iam_role_statements = list(object({<br> effect = string<br> actions = list(string)<br> resources = list(string)<br> }))<br> add_cdn_url_to_env = optional(bool, false)<br> lb_listener_arn = string<br> // The reason for this was to enable the parallel running of ECS and EC2 services.<br> // This boolean will control the flow of traffic. If `true`, traffic will go to ECS. If `false`, traffic will go to EC2.<br> // Can be removed when EC2 services are removed.<br> listener_rule_enable = optional(bool, true)<br> listener_rule_priority = optional(number, 10)<br> listener_rule_host_header = optional(string, "*")<br> security_group_ids = list(string)<br> subnet_ids = list(string)<br> vpc_id = optional(string, null)<br> }))</pre> | `{}` | no |
| <a name="input_services"></a> [services](#input\_services) | The services to deploy | <pre>map(object({<br/> version = string<br/> repository = string<br/> cpu = number<br/> memory = number<br/> task_iam_role_statements = list(object({<br/> effect = string<br/> actions = list(string)<br/> resources = list(string)<br/> }))<br/> add_cdn_url_to_env = optional(bool, false)<br/> lb_listener_arn = string<br/> // The reason for this was to enable the parallel running of ECS and EC2 services.<br/> // This boolean will control the flow of traffic. If `true`, traffic will go to ECS. If `false`, traffic will go to EC2.<br/> // Can be removed when EC2 services are removed.<br/> listener_rule_enable = optional(bool, true)<br/> listener_rule_priority = optional(number, 10)<br/> listener_rule_host_header = optional(string, "*")<br/> security_group_ids = list(string)<br/> subnet_ids = list(string)<br/> vpc_id = optional(string, null)<br/> }))</pre> | `{}` | no |
| <a name="input_vpc_id"></a> [vpc\_id](#input\_vpc\_id) | The VPC ID | `string` | n/a | yes |

## Outputs
Expand Down
7 changes: 1 addition & 6 deletions infra/terraform/modules/service/batch.tf
Original file line number Diff line number Diff line change
Expand Up @@ -166,11 +166,8 @@ module "eventbridge_sns" {

create_bus = false

role_name = "vol-app-${var.environment}-batch-fail-role"

rules = {
batch-fail-sns = {
name = "${var.environment}-batch-fail-event"
"${var.environment}-batch-fail-event" = {
description = "Capture failed Batch Events sent to SNS"
event_pattern = jsonencode({
"source" : ["aws.batch"],
Expand Down Expand Up @@ -205,8 +202,6 @@ module "sns_batch_fail" {

name = "vol-app-${var.environment}-batch-fail-topic"
use_name_prefix = true
display_name = "batch-event-failed"


create_topic_policy = true
enable_default_topic_policy = true
Expand Down

0 comments on commit 436062d

Please sign in to comment.