Skip to content

Commit f373758

Browse files
authored
feat: Added nexi sysntetic tests (#2696)
added nexi sysntetic tests
1 parent 6babcaf commit f373758

File tree

13 files changed

+167
-9
lines changed

13 files changed

+167
-9
lines changed

src/next-core/03_tools_cae.tf

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,19 @@ resource "azurerm_container_app_environment" "tools_cae" {
2323
log_analytics_workspace_id = azurerm_log_analytics_workspace.log_analytics_workspace.id
2424
infrastructure_subnet_id = azurerm_subnet.tools_cae_subnet.id
2525
}
26+
27+
28+
module "route_table_peering_nexi" {
29+
source = "git::https://github.com/pagopa/terraform-azurerm-v3.git//route_table?ref=v8.33.0"
30+
31+
name = format("%s-tools-to-nexi-rt", local.product)
32+
location = var.location
33+
resource_group_name = module.vnet.resource_group_name
34+
disable_bgp_route_propagation = false
35+
36+
subnet_ids = [azurerm_subnet.tools_cae_subnet.id]
37+
38+
routes = var.route_tools
39+
40+
tags = var.tags
41+
}

src/next-core/99_variables.tf

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1116,3 +1116,13 @@ variable "enable_node_forwarder_debug_instance" {
11161116
default = false
11171117
description = "Enable the creation of a separate 'debug' instance of node forwarder"
11181118
}
1119+
1120+
variable "route_tools" {
1121+
type = list(object({
1122+
name = string
1123+
address_prefix = string
1124+
next_hop_type = string
1125+
next_hop_in_ip_address = string
1126+
}))
1127+
description = "AKS routing table"
1128+
}

src/next-core/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
| <a name="module_node_forwarder_snet"></a> [node\_forwarder\_snet](#module\_node\_forwarder\_snet) | git::https://github.com/pagopa/terraform-azurerm-v3.git//subnet | v7.69.1 |
5151
| <a name="module_redis"></a> [redis](#module\_redis) | git::https://github.com/pagopa/terraform-azurerm-v3.git//redis_cache | v7.50.0 |
5252
| <a name="module_redis_snet"></a> [redis\_snet](#module\_redis\_snet) | git::https://github.com/pagopa/terraform-azurerm-v3.git//subnet | v7.50.0 |
53+
| <a name="module_route_table_peering_nexi"></a> [route\_table\_peering\_nexi](#module\_route\_table\_peering\_nexi) | git::https://github.com/pagopa/terraform-azurerm-v3.git//route_table | v8.33.0 |
5354
| <a name="module_route_table_peering_sia"></a> [route\_table\_peering\_sia](#module\_route\_table\_peering\_sia) | git::https://github.com/pagopa/terraform-azurerm-v3.git//route_table | v7.62.0 |
5455
| <a name="module_vnet"></a> [vnet](#module\_vnet) | git::https://github.com/pagopa/terraform-azurerm-v3.git//virtual_network | v7.62.0 |
5556
| <a name="module_vnet_core_peering"></a> [vnet\_core\_peering](#module\_vnet\_core\_peering) | git::https://github.com/pagopa/terraform-azurerm-v3.git//virtual_network_peering | v8.32.0 |
@@ -492,6 +493,7 @@
492493
| <a name="input_redis_version"></a> [redis\_version](#input\_redis\_version) | The version of Redis to use: 4 (deprecated) or 6 | `string` | `"6"` | no |
493494
| <a name="input_redis_zones"></a> [redis\_zones](#input\_redis\_zones) | (Optional) Zone list where redis will be deployed | `list(string)` | <pre>[<br/> "1"<br/>]</pre> | no |
494495
| <a name="input_route_table_peering_sia_additional_routes"></a> [route\_table\_peering\_sia\_additional\_routes](#input\_route\_table\_peering\_sia\_additional\_routes) | (Optional) additional routes for route table peering sia | <pre>list(object({<br/> address_prefix = string<br/> name = string<br/> next_hop_in_ip_address = string<br/> next_hop_type = string<br/> }<br/> ))</pre> | `[]` | no |
496+
| <a name="input_route_tools"></a> [route\_tools](#input\_route\_tools) | AKS routing table | <pre>list(object({<br/> name = string<br/> address_prefix = string<br/> next_hop_type = string<br/> next_hop_in_ip_address = string<br/> }))</pre> | n/a | yes |
495497
| <a name="input_schema_ip_nexi"></a> [schema\_ip\_nexi](#input\_schema\_ip\_nexi) | Nodo Pagamenti Nexi schema://ip | `string` | n/a | yes |
496498
| <a name="input_storage_queue_private_endpoint_enabled"></a> [storage\_queue\_private\_endpoint\_enabled](#input\_storage\_queue\_private\_endpoint\_enabled) | Whether private endpoint for Azure Storage Queues is enabled | `bool` | `true` | no |
497499
| <a name="input_tags"></a> [tags](#input\_tags) | n/a | `map(any)` | <pre>{<br/> "CreatedBy": "Terraform"<br/>}</pre> | no |

src/next-core/env/dev/terraform.tfvars

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -750,3 +750,12 @@ apicfg_selfcare_integ_service_path_value = "pagopa-api-config-selfcare-integrati
750750
law_sku = "PerGB2018"
751751
law_retention_in_days = 30
752752
law_daily_quota_gb = 10
753+
route_tools = [
754+
{
755+
# dev aks nodo oncloud
756+
name = "tools-outbound-to-nexy-nodo"
757+
address_prefix = "10.70.66.200/32"
758+
next_hop_type = "VirtualAppliance"
759+
next_hop_in_ip_address = "10.230.8.150"
760+
}
761+
]

src/next-core/env/prod/terraform.tfvars

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -854,3 +854,12 @@ monitor_env_test_urls = [
854854
]
855855

856856
enable_node_forwarder_debug_instance = false
857+
route_tools = [
858+
{
859+
# dev aks nodo oncloud
860+
name = "tools-outbound-to-nexy-nodo"
861+
address_prefix = "10.79.20.34/32"
862+
next_hop_type = "VirtualAppliance"
863+
next_hop_in_ip_address = "10.230.10.150"
864+
}
865+
]

src/next-core/env/uat/terraform.tfvars

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -801,3 +801,14 @@ app_gateway_allowed_paths_upload = [
801801
"/fdr-legacy/nodo-per-pa/.*",
802802
"/fdr-psp/.*" # Added temporarily as workaround for bug https://pagopa.atlassian.net/browse/PAGOPA-2263
803803
]
804+
805+
806+
route_tools = [
807+
{
808+
# dev aks nodo oncloud
809+
name = "tools-outbound-to-nexy-nodo"
810+
address_prefix = "10.70.74.200/32"
811+
next_hop_type = "VirtualAppliance"
812+
next_hop_in_ip_address = "10.230.9.150"
813+
}
814+
]

src/synthetic-monitoring/02_monitoring.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,6 @@ module "monitoring_function" {
4545
check_position_body = var.check_position_body
4646
alert_enabled = var.synthetic_alerts_enabled
4747
verify_payment_internal_expected_outcome = var.verify_payment_internal_expected_outcome
48+
nexi_node_ip = var.nexi_node_ip
4849
})
4950
}

src/synthetic-monitoring/99_variables.tf

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,3 +113,8 @@ variable "verify_payment_internal_expected_outcome" {
113113
type = string
114114
description = "(Required) Expected outcome for verify payment notice internal"
115115
}
116+
117+
variable "nexi_node_ip" {
118+
type = string
119+
description = "Nodo Pagamenti Nexi ip"
120+
}

src/synthetic-monitoring/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@
5151
| <a name="input_law_sku"></a> [law\_sku](#input\_law\_sku) | Sku of the Log Analytics Workspace | `string` | `"PerGB2018"` | no |
5252
| <a name="input_location"></a> [location](#input\_location) | One of westeurope, northeurope | `string` | n/a | yes |
5353
| <a name="input_location_short"></a> [location\_short](#input\_location\_short) | One of wue, neu | `string` | n/a | yes |
54+
| <a name="input_nexi_node_ip"></a> [nexi\_node\_ip](#input\_nexi\_node\_ip) | Nodo Pagamenti Nexi ip | `string` | n/a | yes |
5455
| <a name="input_prefix"></a> [prefix](#input\_prefix) | n/a | `string` | n/a | yes |
5556
| <a name="input_self_alert_enabled"></a> [self\_alert\_enabled](#input\_self\_alert\_enabled) | (Optional) enables the alert on the function itself | `bool` | `true` | no |
5657
| <a name="input_storage_account_replication_type"></a> [storage\_account\_replication\_type](#input\_storage\_account\_replication\_type) | (Required) table storage replication type | `string` | n/a | yes |

src/synthetic-monitoring/env/weu-dev/terraform.tfvars

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,3 +39,4 @@ check_position_body = {
3939
notice_number = "310115803416020234"
4040
}
4141
verify_payment_internal_expected_outcome = "KO"
42+
nexi_node_ip = "10.70.66.200"

0 commit comments

Comments
 (0)