diff --git a/README.md b/README.md index e1eaaa7ba..761fa519a 100644 --- a/README.md +++ b/README.md @@ -187,6 +187,14 @@ The following table lists the released DSFKit versions, their release date and a 1. Refactored directory structure.
2. Released to terraform registry.
3. Supported hub/gw on RedHat 7 ami.
4. Restricted permissions for Sonar installation.
5. Added the module's version to the examples. + + 26 Jan 2023 + + 1.3.5 + + 1. Enable creating RDS MsSQL with synthetic data for POC purposes.
2. Fix manual and automatic installer machine deployments. + + diff --git a/examples/poc/basic_deployment/main.tf b/examples/poc/basic_deployment/main.tf index e7f960118..e965b2ff5 100644 --- a/examples/poc/basic_deployment/main.tf +++ b/examples/poc/basic_deployment/main.tf @@ -19,8 +19,6 @@ module "key_pair" { data "aws_availability_zones" "available" { state = "available" } -data "aws_region" "current" {} - locals { workstation_cidr_24 = [format("%s.0/24", regex("\\d*\\.\\d*\\.\\d*", module.globals.my_ip))] } @@ -139,7 +137,7 @@ module "rds_mysql" { security_group_ingress_cidrs = local.workstation_cidr } -module "db_onboarding" { +module "db_onboarding_mysql" { for_each = { for idx, val in module.rds_mysql : idx => val } source = "imperva/dsf-poc-db-onboarder/aws" version = "1.3.5" # latest release tag @@ -169,15 +167,16 @@ module "db_onboarding" { # create a RDS SQL Server DB module "rds_mssql" { count = contains(var.db_types_to_onboard, "RDS MsSQL") ? 1 : 0 - source = "../../../modules/aws/rds-mssql-db" + source = "imperva/dsf-poc-db-onboarder/aws//modules/rds-mssql-db" + version = "1.3.5" # latest release tag rds_subnet_ids = module.vpc.public_subnets security_group_ingress_cidrs = local.workstation_cidr - friendly_name = local.deployment_name_salted } module "db_onboarding_mssql" { for_each = { for idx, val in module.rds_mssql : idx => val } source = "imperva/dsf-poc-db-onboarder/aws" + version = "1.3.5" # latest release tag sonar_version = module.globals.tarball_location.version hub_info = { hub_ip_address = module.hub.public_ip @@ -199,7 +198,7 @@ module "db_onboarding_mssql" { depends_on = [ module.federation, module.rds_mssql, - module.db_onboarding + module.db_onboarding_mysql ] } diff --git a/examples/poc/hadr_deployment/main.tf b/examples/poc/hadr_deployment/main.tf index 8e09ec469..14afc8609 100644 --- a/examples/poc/hadr_deployment/main.tf +++ b/examples/poc/hadr_deployment/main.tf @@ -188,7 +188,7 @@ module "rds_mysql" { security_group_ingress_cidrs = local.workstation_cidr } -module "db_onboarding" { +module "db_onboarding_mysql" { for_each = { for idx, val in module.rds_mysql : idx => val } source = "imperva/dsf-poc-db-onboarder/aws" version = "1.3.5" # latest release tag @@ -219,10 +219,10 @@ module "db_onboarding" { # create a RDS SQL Server DB module "rds_mssql" { count = contains(var.db_types_to_onboard, "RDS MsSQL") ? 1 : 0 - source = "../../../modules/aws/rds-mssql-db" + source = "imperva/dsf-poc-db-onboarder/aws//modules/rds-mssql-db" + version = "1.3.5" # latest release tag rds_subnet_ids = module.vpc.public_subnets security_group_ingress_cidrs = local.workstation_cidr - friendly_name = local.deployment_name_salted } module "db_onboarding_mssql" { @@ -250,7 +250,7 @@ module "db_onboarding_mssql" { depends_on = [ module.federation, module.rds_mssql, - module.db_onboarding + module.db_onboarding_mysql ] } diff --git a/modules/aws/rds-mssql-db/README.md b/modules/aws/rds-mssql-db/README.md index aca19a351..73f47ffea 100644 --- a/modules/aws/rds-mssql-db/README.md +++ b/modules/aws/rds-mssql-db/README.md @@ -61,7 +61,6 @@ module "rds_mssql" { source = "imperva/dsf-poc-db-onboarder/aws//modules/rds-mssql-db" rds_subnet_ids = "${aws_subnet.example.id}" security_group_ingress_cidrs = "${aws_cidr.example}" - friendly_name = "${var.db_name}" } ``` diff --git a/modules/aws/rds-mssql-db/iam_role.tf b/modules/aws/rds-mssql-db/iam_role.tf index 8c07b7fec..97db4993b 100644 --- a/modules/aws/rds-mssql-db/iam_role.tf +++ b/modules/aws/rds-mssql-db/iam_role.tf @@ -127,7 +127,7 @@ locals { resource "aws_iam_role" "rds_db_og_role" { name_prefix = replace("${local.db_identifier}-og-role", "_", "-") - description = replace("${local.db_identifier}-og-role-${var.friendly_name}", "_", "-") + description = replace("${local.db_identifier}-og-role", "_", "-") managed_policy_arns = null assume_role_policy = local.rds_db_og_role_assume_role_policy inline_policy { @@ -144,7 +144,7 @@ resource "aws_iam_instance_profile" "lambda_mssql_infra_instance_iam_profile" { resource "aws_iam_role" "lambda_mssql_infra_role" { count = var.role_arn != null ? 0 : 1 name_prefix = "imperva-mssql-infra-role" - description = "imperva-mssql-infra-role-${var.friendly_name}" + description = "imperva-mssql-infra-role" managed_policy_arns = null assume_role_policy = local.role_assume_role_policy inline_policy { diff --git a/modules/aws/rds-mssql-db/variables.tf b/modules/aws/rds-mssql-db/variables.tf index 0e6a96bb0..3e1beb811 100644 --- a/modules/aws/rds-mssql-db/variables.tf +++ b/modules/aws/rds-mssql-db/variables.tf @@ -50,12 +50,3 @@ variable "role_arn" { description = "IAM role to assign to the RDS SQL Server DB" } -variable "friendly_name" { - type = string - default = "imperva-dsf-mssql" - description = "Friendly name, MsSQL Instance Name" - validation { - condition = length(var.friendly_name) > 3 - error_message = "Deployment name must be at least 3 characters" - } -}