Code Monkey home page Code Monkey logo

Comments (5)

tabic avatar tabic commented on August 15, 2024 2

I just tried but I cannot reproduce your issue

from ansible-grafana.

nop33 avatar nop33 commented on August 15, 2024

When I replace curl with get_url, it works. However, I see that in #77 it was changed from get_url to curl because:

[some] dashboards are so big that they don't fit into some cache used by get_url module

get_url:
  url: "https://grafana.com/api/dashboards/{{ item.dashboard_id }}/revisions/{{ item.revision_id }}/download"
  dest: "{{ _tmp_dashboards.path }}/{{ item.dashboard_id }}.json"

from ansible-grafana.

nop33 avatar nop33 commented on August 15, 2024

I tested all dashboards that were said to have an issue when using get_url (6239, 704 and 5566) and I am happy to report that it worked for all of them:

TASK [cloudalchemy.grafana : download grafana dashboard from grafana.net to local directory] *************************
ok: [monitoring.plte.ch] => (item={'dashboard_id': 3662, 'revision_id': 2, 'datasource': 'PL Prometheus'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 12019, 'revision_id': 2, 'datasource': 'PL Loki'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 6239, 'revision_id': 1, 'datasource': 'PL Prometheus'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 704, 'revision_id': 1, 'datasource': 'PL Prometheus'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 5566, 'revision_id': 5, 'datasource': 'PL Prometheus'})

TASK [cloudalchemy.grafana : Set the correct data source name in the dashboard] **************************************
ok: [monitoring.plte.ch] => (item={'dashboard_id': 3662, 'revision_id': 2, 'datasource': 'PL Prometheus'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 12019, 'revision_id': 2, 'datasource': 'PL Loki'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 6239, 'revision_id': 1, 'datasource': 'PL Prometheus'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 704, 'revision_id': 1, 'datasource': 'PL Prometheus'})
ok: [monitoring.plte.ch] => (item={'dashboard_id': 5566, 'revision_id': 5, 'datasource': 'PL Prometheus'})

TASK [cloudalchemy.grafana : Import grafana dashboards through API] **************************************************
[WARNING]: Unable to find 'dashboards' in expected paths (use -vvvvv to see paths)
skipping: [monitoring.plte.ch] => (item=None)
skipping: [monitoring.plte.ch] => (item=None)
skipping: [monitoring.plte.ch] => (item=None)
skipping: [monitoring.plte.ch] => (item=None)
skipping: [monitoring.plte.ch] => (item=None)
skipping: [monitoring.plte.ch]

TASK [cloudalchemy.grafana : Create/Update dashboards file (provisioning)] *******************************************
ok: [monitoring.plte.ch]

TASK [cloudalchemy.grafana : Register previously copied dashboards] **************************************************
skipping: [monitoring.plte.ch]

TASK [cloudalchemy.grafana : Import grafana dashboards] **************************************************************
[WARNING]: Unable to find 'dashboards' in expected paths (use -vvvvv to see paths)
ok: [monitoring.plte.ch] => (item=/tmp/ansible.uq60auor/3662.json)
changed: [monitoring.plte.ch] => (item=/tmp/ansible.uq60auor/704.json)
changed: [monitoring.plte.ch] => (item=/tmp/ansible.uq60auor/5566.json)
ok: [monitoring.plte.ch] => (item=/tmp/ansible.uq60auor/12019.json)
ok: [monitoring.plte.ch] => (item=/tmp/ansible.uq60auor/6239.json)

So, I will consider switching back to get_url is a valid solution and switch back to it. I'll create a PR.

from ansible-grafana.

baronfel avatar baronfel commented on August 15, 2024

I've had this problem on my own debian 10 hosts for months now, thanks for linking to the PR that fixes it.

from ansible-grafana.

SuperQ avatar SuperQ commented on August 15, 2024

This role has been deprecated in favor of a the grafana-ansible-collection collection.

from ansible-grafana.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.