-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
docs: Modify passing-providers-explicitly section #35781 #35880
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tried a little rewording to see if we could make this clearer.
If the unaliased `provider` name is not present in the providers map, | ||
it will still be inherited in the same way as implicit provider inheritance. | ||
`providers` argument used in `module` block will not override the default | ||
inheritance behavior. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the unaliased `provider` name is not present in the providers map, | |
it will still be inherited in the same way as implicit provider inheritance. | |
`providers` argument used in `module` block will not override the default | |
inheritance behavior. | |
Terraform implicitly passes the un-aliased provider name to child objects, even if it is excluded from the `providers` map. As a result, child objects still inherit the provider name according to the provider inheritance. Using the `providers` argument in a `module` block does not override the default inheritance behavior. |
Is this clearer and still mean what you intended?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@trujillo-adam, I'm not sure that clears things up (at least it doesn't for me, and I know how the implementation works)
Maybe just simplifying the original works better?
Once a provider's name is used in the
providers
argument within amodule
block, it overrides
the default inheritance behavior for that provider.
Or maybe just drop that paragraph altogether, since it's main purpose is to explain a behavior which doesn't exist. That was derived from old documentation which may not have ever been accurate as the implementation is the result of various compatibility compromises.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jbardin removing that para won't help. User should be aware what happens for the provider block which doesn't have alias. Resources for unalias provider block still gets created same way even if we do not pass it explicitly in module hence I think what @trujillo-adam is clearer.
Yes it's clearer, will make this change
…On Tue, 19 Nov, 2024, 8:18 am trujillo-adam, ***@***.***> wrote:
***@***.**** commented on this pull request.
Tried a little rewording to see if we could make this clearer.
------------------------------
In website/docs/language/modules/develop/providers.mdx
<#35880 (comment)>
:
> +If the unaliased `provider` name is not present in the providers map,
+it will still be inherited in the same way as implicit provider inheritance.
+`providers` argument used in `module` block will not override the default
+inheritance behavior.
⬇️ Suggested change
-If the unaliased `provider` name is not present in the providers map,
-it will still be inherited in the same way as implicit provider inheritance.
-`providers` argument used in `module` block will not override the default
-inheritance behavior.
+Terraform implicitly passes the un-aliased provider name to child objects, even if it is excluded from the `providers` map. As a result, child objects still inherit the provider name according to the provider inheritance. Using the `providers` argument in a `module` block does not override the default inheritance behavior.
Is this clearer and still mean what you intended?
—
Reply to this email directly, view it on GitHub
<#35880 (review)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABLWBVNWFEEQLBDNHOSFXB32BKRGFAVCNFSM6AAAAABQIPCC36VHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDINBUGE3TGMJWHE>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
This is a doc issue so updated the affected documentation page terraform\website\docs\language\modules\develop\providers.mdx
1.10.x
References