-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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 support for Stackdriver monitored project #2605
Add support for Stackdriver monitored project #2605
Comments
Hi @aeneasr, can you try having the alert policy depend on the project services resource? The current config looks like it'll run the two of them in parallel. Let me know how that goes! If it still doesn't work, can you post a gist of debug logs? https://www.terraform.io/docs/internals/debugging.html. Thanks!! |
Hi @danawillow , thank you for the response! The dependence should be implicit because the |
@danawillow would it be possible to send you the logs privately? I think that all sensitive info (API Keys, OAuth2 Client Secrets, ...) is locked away in k8s secrets but some things popped up in the trace/logs so I feel uncomfortable with sharing that publicly. |
Sure, that's fine. first name last name at google dot com. In the meantime, @chrisst is there anything that needs to be done to enable stackdriver besides enabling the API? |
I believe that in order to use stack driver for the first time you will need to enable a stack driver "workspace" which is loosely associated with a GCP project. I was hoping to deliver that but it looks like the api to create the workspace is still in development right now :( When they release the api that supports this I'll get it added in! |
Oh I see, that's what I kinda feared. Thank you for the update. @danawillow I'll refrain from sharing the trace with you then. |
@chrisst Is there any separate github issue for building this API ? I wonder what kind of ETA are we talking about here... ? |
@jaceq Unfortunately the stack driver codebase and apis are closed source and so there isn't a good place for the community to see the feature development. I've been told by the team that they are working on it but I also don't have insight as to when it will be available. |
@chrisst Thank you for clarification. That's a bit of shame to be hanging in the dark. |
Hi, does this mean the api to create workspace is still not there from a GCP standpoint? And Terraform integration is waiting on that? |
@spmsaj that is what I understand to be the case yes. |
API is now in alpha, but projects have to be whitelisted. We can work on the stackdriver workspace resource once it goes beta (undetermined ETA). |
Hi.. any updates on this issue? |
@ocervell given it's almost half a year later... is this in beta finally? |
I'm digging around the GCP monitoring API docs and I still don't see API support for creating stackdriver workspaces. Sad. I'm also asking in the GCP slack stackdriver channel about a timeline, but no word yet. |
@danawillow any updates from your side? |
No updates on a date. If you're part of the alpha, you can ask your GCP rep to contact our team on your behalf for support. |
For the record, I'm also having the same issue. Had to create the workspace manually in StackDriver to be able to create the alert. |
Is there a workaround for this in the meantime while this is is being worked on? This is a blocker for a fully automated project set up. |
@emmaLP the only workaround that I could come up with is to get early access to the alpha for Stackdriver Workspace API. I was told to talk with our Google Cloud Support point of contact to ask to be added to that. However you would still need to write the code to use the API to create stackdriver stuff, since terraform still doesn't have support for it. |
Just a quick note since I was taking a look at this earlier- the API is still available in alpha/private preview and unavailable at beta/public preview, at which point we'll be able to make it available in the |
To work around hashicorp/terraform-provider-google#2605 Needed for #10
Another attempt to work around hashicorp/terraform-provider-google#2605
Yes. This is still pending. Was creating uptime check and failed with following error -
Created stack driver workspace manually on console and it worked fine on next run. Would be appreciated if API for workspace creation is released sooner. |
Cloud Monitoring workspace is renamed to metrics scope and the API is in Public Preview. |
Oh, yep, we're working with https://github.com/GoogleCloudPlatform/declarative-resource-client-library to make that available, and add that to the provider. Sorry- forgot to update this issue initially! |
👍 |
Ok, so how do we enable the Cloud Monitoring API using Terraform now? |
I believe you can already do so using google_project_service I seem to have linked this issue in the wrong PR, causing it to close prematurely. |
Closed in GoogleCloudPlatform/magic-modules#5218 / GoogleCloudPlatform/magic-modules#5235 (due for release Oct 4 in the |
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. |
Community Note
Terraform Version
v0.11.10
Affected Resource(s)
Terraform Configuration Files
Debug Output
Expected Behavior
It should be possible to link the project to a StackDriver account or use
google_monitoring_alert_policy
right away.Actual Behavior
I was unable to find any resources on how to link the project with the stackdriver account. It should either be documented how to achieve that (happy to do so after I know how to do it :) ) or added as a resource(?) or setting.
Steps to Reproduce
I have not tested it yet, but a minimal reproduction case is probably to create a new project and try to set up a monitoring alert right away.
References
The text was updated successfully, but these errors were encountered: