-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
google_project_iam_policy removes Role for service Networking API
Google created service account
#3499
Comments
From the docs:
So to keep that role binding, you need to use google_project_iam_policy_member, for example. |
I agree that is the case for self-created service account but at least until google provider v1.20.0, google created accounts are ignored. restore_policy = {"bindings":[{"members":["serviceAccount:XXXXX-compute@developer.gserviceaccount.com"],"role":"roles/editor"}],"etag":"adsfhfsh"=","version":1} In Google Provider v2.0.0 , it seems to change. |
Is there a work around for this? |
Per above, the I'm not sure The |
Closing as working as intended- |
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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks! |
Community Note
Terraform Version
Terraform v0.11.11
Affected Resource(s)
Terraform Configuration Files
Debug Output
Panic Output
Expected Behavior
Service account and role binding that were created automatically by enabling
service Networking API
for using resourcegoogle_service_networking_connection
should be kept like other Google created service accounts.Actual Behavior
Role binding to Service account
serviceAccount:service-XXXXXXXX@service-networking.iam.gserviceaccount.com
is being removed.Steps to Reproduce
service Networking API
IAM
thatserviceAccount:service-XXXXXXXX@service-networking.iam.gserviceaccount.com
has the roleroles/servicenetworking.serviceAgent
terraform apply
IAM
again.Important Factoids
References
The text was updated successfully, but these errors were encountered: