Skip to content
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

Missing required config value at 'grafana.domain' #67

Open
MHoinkaBS opened this issue May 4, 2023 · 0 comments
Open

Missing required config value at 'grafana.domain' #67

MHoinkaBS opened this issue May 4, 2023 · 0 comments

Comments

@MHoinkaBS
Copy link

MHoinkaBS commented May 4, 2023

Hi,
I've encountered a problem while trying to add the Grafana plugin to the Backstage.

I have a Grafana tile on the component page but it shows an error:

Error

Missing required config value at 'grafana.domain'

Error: Missing required config value at 'grafana.domain'
    at I.getString (http://localhost:7007/static/module-backstage.43ebf01d.js:9:31881)
    at Object.factory (http://localhost:7007/static/module-k-phoen.ad3b7d0d.js:1:5163)
    at Y.load (http://localhost:7007/static/module-backstage.43ebf01d.js:9:34243)
    at Y.get (http://localhost:7007/static/module-backstage.43ebf01d.js:9:33998)
    at n (http://localhost:7007/static/module-backstage.43ebf01d.js:40:85264)
    at y (http://localhost:7007/static/870.829e099c.chunk.js:1:1011)
    at Gl (http://localhost:7007/static/module-react-dom.cde93b43.js:12:52799)
    at hs (http://localhost:7007/static/module-react-dom.cde93b43.js:16:8596)
    at cs (http://localhost:7007/static/module-react-dom.cde93b43.js:16:930)
    at Za (http://localhost:7007/static/module-react-dom.cde93b43.js:16:861)

Plugin installed as described here: https://github.com/K-Phoen/backstage-plugin-grafana/blob/main/docs/index.md#installation

My configuration:

EntityPage.tsx

import { EntityGrafanaDashboardsCard } from '@k-phoen/backstage-plugin-grafana';
// ...
const overviewContent = (
  <Grid container spacing={3} alignItems="stretch">
    {entityWarningContent}
    (...)
    <Grid item md={6}>
      <EntityGrafanaDashboardsCard />
    </Grid>
    (...)
  </Grid>
);

app-config.yaml

proxy:
//...
  '/grafana/api':
    target: https://grafana.my.tech
    headers:
      Authorization: Bearer {API_token}

//...      
      
grafana:
  domain: https://grafana.my.tech
  unifiedAlerting: false

catalog-info.yaml

apiVersion: backstage.io/v1alpha1
kind: Component
metadata:
  name: Training
  description: Training
  annotations:
    grafana/dashboard-selector: alerts-test

In config.d.ts. of the plugin there is domain: string declared in the Config interface.

I have also a Sonarqube plugin and it does not have problem with baseUrl.
Backstage is running localy in Docker container. Network traffic to Grafana is open.

When I tried to Embed dashboards on a component page (as described here:
https://github.com/K-Phoen/backstage-plugin-grafana/blob/main/docs/embed-dashboards-on-page.md )
I've got grafana.my.tech is blocked so I assume in that case grafana.domain value has been passed as expected.

I will be grateful for help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant