Documentshow-to-show-grafana-dashboards-in-pisignage-players

How to show Grafana dashboards in PiSignage players

Create a read only Grafana service account, copy its token and show the kiosk URL as a webpage with an Authorization header.

1. Create a service account

  1. Open Grafana and go to Administration > Users and Access > Service Accounts.
  2. Click Add service account.
  3. Name it, for example pisignage.
  4. Set the Role to Viewer. Change this if your requirements differ.
  5. Click Apply, then Create.

2. Generate a token

  1. Open the new service account.

  2. Click Add Service Account Token.

  3. Name the token, for example PiSignage-Token.

  4. Click Generate Token.

  5. Copy the token. You need it for PiSignage. It looks like this (sample)

    glsa_P7TUMwo7rTXnbGjYh1P1y4xxxxx_bae5ff42
    

The token should never expire, or have an expiry that matches your security policy.

3. Assign dashboard permissions

  1. Go to Dashboards and select the dashboard to share.
  2. Click Edit.
  3. Go to Settings > Permissions.
  4. Add View permission for the service account (pisignage) on this dashboard.
  5. Save the dashboard and exit Edit mode.

4. Enable kiosk mode

  1. Click Enable Kiosk Mode at the top right of the dashboard.
  2. Copy the URL shown in the browser address bar.

5. Configure PiSignage

  1. Log in to PiSignage and go to Assets.

  2. Click Add Asset and choose the Webpage type (the old article called this Add Link).

  3. Paste the Grafana kiosk URL in the Link Address field.

  4. In Optional Headers add the token

    Authorization: Bearer <Token>
    

    For example

    Authorization: Bearer glsa_3Vr2BR6UUDBxxxxxx_06a66dc8
    

6. Save and verify

Save the asset, add it to a playlist and deploy. Check that the dashboard displays correctly on the screen.

Grafana is resource intensive. When scheduling, keep the page open for 60 seconds or more.

More on the Webpage type and headers in Assets. A similar login based setup is in How to display webpages and dashboards that require login.