Terraform output: Error: module “rds”: “monitoring_role_arn” is not a valid argument

0 votes

I have the following code in tf:

module "rds" "app" {
  source = "git@github.com:*****/aws-terraform-rds.git"

  name                   = "${var.rds_name_app}"
  engine                 = "${var.rds_engine_app}"
  engine_version         = "${var.rds_engine_version_app}"
  family                 = "${var.rds_family_app}"
  instance_class         = "${var.rds_instance_class_app}"

  password                   = "${random_string.rds_password.result}"
  port                       = "${var.rds_port_app}"
  security_groups            = ["${aws_security_group.rds_app.id}"]
  subnets                    = ["${module.vpc.public_subnets}"]
  auto_minor_version_upgrade = "${var.rds_auto_minor_version_upgrade_app}"
  backup_retention_period    = "${var.rds_backup_retention_period_app}"
  backup_window              = "${var.rds_backup_window_app}"
  maintenance_window         = "${var.rds_maintenance_window_app}"
  environment                = "${var.environment}"
  kms_key_id                 = "${aws_kms_key.rds.arn}"
  multi_az                   = "${var.rds_multi_az_app}"
  notification_topic         = "${var.rds_notification_topic_app}"
  publicly_accessible        = "${var.rds_publicly_accessible_app}"
  storage_encrypted          = "${var.rds_storage_encrypted_app}"
  storage_size               = "${var.rds_storage_size_app}"
  storage_type               = "${var.rds_storage_type_app}"
  monitoring_interval        = "${var.rds_monitoring_interval_app}"
  monitoring_role_arn        = "${var.rds_monitoring_role_arn_app}"
  apply_immediately          = true  
The variables are present in the variables.tf file.

When I run terraform plan it gives me the following error:

Error: module "rds": "monitoring_role_arn" is not a valid argument

I am not sure why I am getting this error since the "monitoring_role_arn" is a valid terraform argument.

Sep 3 in Terraform by mgb
• 120 points

recategorized Sep 3 by MD 134 views

1 answer to this question.

0 votes

Hi@mgb,

I have checked the document. You are right this argument is there. But I also saw that the below arguments are also available.

rds_monitoring_interval 
rds_monitoring_role_arn

So I suggest you try these arguments once. If it does not work then if possible share your complete code with the Github repo link. So that I can troubleshoot in my system.

answered Sep 3 by MD
• 79,930 points

Related Questions In Terraform

0 votes
1 answer

'terraform' is not recognized as an internal or external command, operable program or batch file.

Hi@akhtar, You have to set an environment variable ...READ MORE

answered Jun 10 in Terraform by MD
• 79,930 points
1,385 views
0 votes
1 answer
0 votes
1 answer

How to create a rds snapshot from running rds instance in AWS using terraform?

Hi, I think you can use aws_db_instance resource to ...READ MORE

answered Jul 20 in Terraform by MD
• 79,930 points
538 views
+1 vote
2 answers
0 votes
1 answer