Carga inicial

This commit is contained in:
Guilherme Silva
2026-06-19 11:06:23 -03:00
parent 300775db95
commit 058cc047ef
31 changed files with 2387 additions and 2 deletions

37
nsg-database-nsg.tf Executable file
View File

@@ -0,0 +1,37 @@
resource "oci_core_network_security_group" "db-server-nsg" {
compartment_id = var.ocid_compartment_networking
display_name = "db-servers-nsg"
vcn_id = var.ocid_vcn_3_tier
}
#--------------------------------------------------------------------------------------------------------------------------------------------
resource "oci_core_network_security_group_security_rule" "nsg_db_security_ingress_rule_01" {
network_security_group_id = oci_core_network_security_group.db-server-nsg.id
description = "Ingress from sn-app."
source = var.cidr_subnet_app
source_type = "CIDR_BLOCK"
direction = "INGRESS"
protocol = "6"
tcp_options {
destination_port_range {
max = 3306
min = 3306
}
}
}
resource "oci_core_network_security_group_security_rule" "nsg_db_security_ingress_rule_02" {
network_security_group_id = oci_core_network_security_group.db-server-nsg.id
description = "Ingress from sn-app-pri."
source = var.cidr_subnet_app
source_type = "CIDR_BLOCK"
direction = "INGRESS"
protocol = "6"
tcp_options {
destination_port_range {
max = 33060
min = 33060
}
}
}
#--------------------------------------------------------------------------------------------------------------------------------------------