-
Notifications
You must be signed in to change notification settings - Fork 288
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
v1.9.0 Grafana OnCall Plugin: Can't connect to Grafana Cloud OnCall #4943
Comments
I have a similar issue, reported it on the forums a few days ago, https://community.grafana.com/t/trying-to-connect-selfhosted-grafana-to-cloud-oncall/129985 The difference in my case is that I set the Oncall Backend URL in our self-hosted Grafana to point to our self-hosted Oncall-engine and it successfully connects to it, but the token for Grafana Cloud doesn't work even though it works with curl. |
We are still running into this error. Can anyone take a look, please? |
Recently we made some changes to the way Grafana OnCall is initialized. Use 1.9.22, there were quite a few changes along the way from 1.9.0-1.9.22 to get things working.
Grafana OnCall should now be ready to use. |
@mdyerynck This resolves the issue I was previously facing, but now I’m encountering a new challenge. Here’s the error I get in the UI: And this is what the API returns: curl -X GET 'http://admin:admin@localhost:3000/api/plugins/grafana-oncall-app/resources/plugin/status' | jq . {
"pluginConnection": {
"settings": {
"ok": true
},
"service_account_token": {
"ok": true
},
"grafana_url_from_plugin": {
"ok": true
},
"grafana_url_from_engine": {
"ok": false,
"error": "Not validated"
},
"oncall_api_url": {
"ok": false,
"error": "Not validated"
},
"oncall_token": {
"ok": false,
"error": "Unauthorized/Forbidden while accessing OnCall engine: /oncall/api/internal/v1/plugin/v2/status, status code: 403, check token"
}
},
"license": "",
"version": "",
"currently_undergoing_maintenance_message": "",
"api_url": ""
} I’ve tried setting the curl -X POST \
'http://admin:admin@localhost:3000/api/plugins/grafana-oncall-app/settings' \
-H "Content-Type: application/json" \
-d '{
"enabled": true,
"jsonData": {
"stackId": 5,
"orgId": 100,
"onCallApiUrl": "<ONCALL API URL>",
"onCallApiToken": "<ONCALL API TOKEN>",
"grafanaUrl": "http://localhost:3000/"
}
}' Looking through the code in the repo (https://github.com/grafana/oncall), it seems |
Apparently, you can't connect a plugin in OSS directly to a our cloud instance. |
What went wrong?
What happened:
I tried to connect the Grafana OnCall plugin (
v1.9.0
as recommended in Grafana Community Slack, and also with newer versions) to a Grafana Cloud instance for OnCall, but ran into an issue. I set theGRAFANA_CLOUD_ONCALL_API_URL
andGRAFANA_CLOUD_ONCALL_API_TOKEN
environment variables, but they don't seem to have any effect.What did you expect to happen:
How do we reproduce it?
GRAFANA_CLOUD_ONCALL_API_URL
andGRAFANA_CLOUD_ONCALL_API_TOKEN
according to API URL and API TOKEN in your Grafana Cloud instance OnCall settings.API URL
(taken from Grafana Cloud instance) into theOnCall backend URL
. In my case it'shttps://oncall-prod-us-central-0.grafana.net/oncall/
Grafana OnCall Version
v.1.9.0
Product Area
Auth, API, Other
Grafana OnCall Platform?
I use Grafana Cloud
User's Browser?
Chrome Version 128.0.6613.85 (Official Build) (arm64)
Anything else to add?
grafana/grafana-enterprise:11.1.2
The text was updated successfully, but these errors were encountered: