-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add identifier to outputs #495
Comments
@bryantbiggs this change will be not breaking one. It is passed as input to resource (so it can be also outputed) here: I have created PR for this |
while the attribute may have always been there, the value for so while simply adding the |
Module in single instance scenario is working correctly under v5 provider. Issue is only with local replication instance scenario where you need pass After adding this output in module it will become working correctly with v5 provider in replication scenario (for replicated scenario). No other changes is required in module to address v5 compatibility as current |
@shilikok FYI I am currently addresing this by making workaround by extracting from instance ARN last element which represent identifier of database module "database_replica_rds" {
count = local.create_database_replica_rds ? 1 : 0
source = "terraform-aws-modules/rds/aws"
version = "5.9.0"
# Source database. For cross-region use db_instance_arn
replicate_source_db = element(split(":", module.database_rds[0].db_instance_arn), length(split(":", module.database_rds[0].db_instance_arn))-1)
.....
} |
I just had the same issue where I had to assign the |
It will be not working when you use instance_use_identifier_prefix variable. What is more it will require additional manual dependency establish between main and replica module (when you use outputs from one module dependency is done automaticlly) |
@bryantbiggs @antonbabenko |
I have environments that are currently broken when using the newer version of the Terraform AWS provider that includes the PR to change the I don't know that I have a strong opinion either way, but it would be nice for a fix to get in so that I can use the newer provider versions. The PR I was about to commit simply modified the I can see how it might make sense to match the new mapping for If I could vote, I suppose I might vote for the former, because it is less work and anyone doing a provider upgrade will be able to continue to use the module without further issue. I am not sure if it would be backwards-compatible with older supported versions of the provider, but it seems like it would, as |
aws_db_instance was updated by hashicorp/terraform-provider-aws#31232 such that the `id` attribute now tracks the resource ID, and the identifier is now returned in a new attribute named `identifier`. The resource ID is already available in `instance_resource_id`. This fix allows existing users to continue using this module with no changes and preserves the original function of the `id` attribute in this module. Fixes terraform-aws-modules#495.
This issue has been resolved in version 6.0.0 🎉 |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
Is your request related to a new offering from AWS?
Is this functionality available in the AWS provider for Terraform? See CHANGELOG.md, too.
aws provider: 5.0.0
Is your request related to a problem? Please describe.
id is no longer the AWS database identifier - id is now the dbi-resource-id. Refer to identifier instead of id to use the database's identifier
Describe the solution you'd like.
add to module outputs db identifier value
Describe alternatives you've considered.
Additional context
The text was updated successfully, but these errors were encountered: