terraform-provider-gitlab
terraform-provider-gitlab copied to clipboard
Implement error_tracking API
There is currently no support for managing the Sentry integration via the error_tracking
API https://docs.gitlab.com/ee/api/error_tracking.html. Seems pretty easy to add, though.
Would be useful to be able to read the gitlab DSN to set-up error reporting automatically.
@timofurrer Am I correct in assuming we would need upstream work for this in go-gitlab? Probably a new connector as I don't think this would fit into any of the others
@Shocktrooper Yes, if it's not already in go-gitlab - it needs to support it first. We've decided to exclusively use go-gitlab :)
I have started to work on this
Note for @timofurrer / @armsnyder / @PatrickRice-KSC when it comes to review time. I was playing around with the go-gitlab library directly as I was developing it and it seems you cannot turn-on/configure the integration at all via the API. Attempting to enable or configure the integration without sentry or also without the integrated backend results in a 404. If you do happen to have a live sentry instance you can pull values from you have to initially configure error tracking via the UI. The API does not have the capability to configure an external sentry instance only enable/disable the settings once set in the UI.
2022/05/19 18:40:22 PATCH https://somegitlabinstance.com/api/v4/projects/123/error_tracking/settings: 404 {message: 404 Error Tracking Setting Not Found}
Going forward we should just turn on the feature flag in the startup script and just test this without sentry and only use the integrated backend.
Going forward we should just turn on the feature flag in the startup script and just test this without sentry and only use the integrated backend.
Yes, I agree. We should avoid having any external services required for our automated testing!
I've just reviewed the PR in go-gitlab, too ;)