dashy icon indicating copy to clipboard operation
dashy copied to clipboard

[QUESTION] Is my gl-disk-space widget config correct?

Open yed01 opened this issue 3 years ago • 10 comments

Question

Hi, I am not able to get the gl-disk-space widget to work. All the other Glances-widgets are working, and all have the same configuration.

d

- name: Disk Space
  icon: fas fa-hdd
  widgets:
  - type: gl-disk-space
    options:
      hostname: https://domain.com
      username: glances
      password: xxxxx 
      useProxy: true

Help would be appreciated.

Category

Widgets

Please tick the boxes

yed01 avatar Aug 16 '22 13:08 yed01

If you're enjoying Dashy, consider dropping us a ⭐
🤖 I'm a bot, and this message was automated

liss-bot avatar Aug 16 '22 13:08 liss-bot

Heya

Can you share the errror message in the browser console too? (here's how if you're unsure)

On some systems, some endpoints aren't available from Glances, so double check that Glances actually has this data.

It's using the fs endpoint, so the endpoint is: http://[hostname-of-glances]/api/3/fs For reference, this component is defined in Widgets/GlDiskSpace.vue.

Lissy93 avatar Aug 16 '22 13:08 Lissy93

These are the error messages:

IndexedDB UnknownErr: ActorsParent.cpp:9531
IndexedDB UnknownErr: ActorsParent.cpp:10228 2
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
WebExtension context not found! ExtensionParent.jsm:1175
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
4 common.js:4
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
index.js:5133
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
common.js:4
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
TypeError: gRecipeManager is null LoginManagerParent.jsm:136:3
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Error: Can't find profile directory. 2 XULStore.jsm:68:15
TypeError: gRecipeManager is null 2 LoginManagerParent.jsm:136:3
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
HTTPS-Only Mode: Unsichere Anfrage "http://ocsp.digicert.com/" erhält aufgrund einer Ausnahme nicht kein Upgrade.
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
HTTPS-Only Mode: Unsichere Anfrage "http://ocsp.digicert.com/" erhält aufgrund einer Ausnahme nicht kein Upgrade.
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 4 background.js:1
Sicherheitsfehler: Inhalte auf moz-extension://6bb4caa1-c9f2-40b8-83e6-dfc4ffbfdafb/ haben versucht, chrome://global/locale/intl.css zu laden, aber dürfen keine externen Daten laden, wenn sie als Grafik verwendet werden.
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
HTTPS-Only Mode: Unsichere Anfrage "http://ocsp.pki.goog/gts1c3" erhält aufgrund einer Ausnahme nicht kein Upgrade.
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
9 common.js:4
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
index.js:5133
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
3 common.js:4
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Promise resolved after context unloaded
index.js:5133
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
2 common.js:4
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 7 background.js:1
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
5 common.js:4
    sendMessage moz-extension://9904b265-bc8f-4374-a6c3-270fbe31290e/rea/common.js:4
Promise rejected after context unloaded: Actor 'Conduits' destroyed before query 'RuntimeMessage' was resolved
index.js:5133
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 5 background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 5 background.js:1
Error: Please use $(ref:runtime.getURL). 2 content.js:2
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 3 background.js:1
FrameData missing for {446900e4-71c2-419f-a6a7-df9c091e268b} page moz-extension://302d8e7f-d1bc-494c-abc0-46820bb80aba/popup/index.html ExtensionPageChild.jsm:459
FrameData missing for {8419486a-54e9-11e8-9401-ac9e17909436} page moz-extension://5b6a77f4-37a8-4b01-9f09-85e8ad0053b5/popup/build/index.html ExtensionPageChild.jsm:459
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
HTTPS-Only Mode: Unsichere Anfrage "http://r3.o.lencr.org/" erhält aufgrund einer Ausnahme nicht kein Upgrade.
[Exception... "Component returned failure code: 0x805e0006 (NS_ERROR_CONTENT_BLOCKED) [nsIChannel.asyncOpen]"  nsresult: "0x805e0006 (NS_ERROR_CONTENT_BLOCKED)"  location: "JS frame :: resource:///modules/FaviconLoader.jsm :: load :: line 188"  data: no] FaviconLoader.jsm:188:20
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 3 background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 4 background.js:1
HTTPS-Only Mode: Unsichere Anfrage "http://ocsp.sca1b.amazontrust.com/" erhält aufgrund einer Ausnahme nicht kein Upgrade.
Error: Please use $(ref:runtime.getURL). 2 content.js:2
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
WebExtension context not found! ExtensionParent.jsm:1175
Promise resolved after context unloaded
index.js:5133
Error: Please use $(ref:runtime.getURL). 2 content.js:2
HTTPS-Only Mode: Unsichere Anfrage "http://r3.o.lencr.org/" erhält aufgrund einer Ausnahme nicht kein Upgrade.
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. 2 background.js:1
FrameData missing for [email protected] page moz-extension://de0a3e5e-0aff-47cf-b92a-1f8fb9e0110f/popup-fenix.html ExtensionPageChild.jsm:459
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. background.js:1

Glances has the data and it is accessible via https://[hostname-of-glances]/api/3/fs d2

I really can't understand the issue because everything else works.

yed01 avatar Aug 16 '22 14:08 yed01

Those errors aren't coming from Dashy, but instead one of your browser extensions.

There should be a message in a yellow square saying ⚠️ Warning ⚠️ and below that some info.

You could also check the Networking tab, filter by XHR (ignore everything from your extensions), and look for the Glances request and check what the response is.

Your config looks all good, and that Glances data looks perfect... I'll also try it out on my box when I get home.

Lissy93 avatar Aug 16 '22 14:08 Lissy93

Oh, sorry.

The only things I could find are this:

s3

s4

OK, great, thank you for your help by the way.

yed01 avatar Aug 16 '22 15:08 yed01

Yup, that's the one!

Interesting, it's showing Unauthorized, but you're using exactley the same pparameters with your other Glances widgets, and they're working all fine?

Lissy93 avatar Aug 16 '22 16:08 Lissy93

Yes, all have the same configuration and the others are all working fine.

yed01 avatar Aug 16 '22 16:08 yed01

OK, I found the problem, it's the Nginx Basic Auth. After removing

auth_basic           "Administrator’s Area";
auth_basic_user_file /etc/apache2/.htpasswd;

the widget is working.

But now the Glances page is open in the Web. Is there a way to make Glances work with Dashy without the Glances WEB-UI?

It's still strange that there is only one widget which has a problem with the Nginx Authentication.

EDIT: I found a workaround but I'm not sure if it's safe to do it that way.

 location /api {
        auth_request off;
        proxy_pass http://127.0.0.1:61208/api;
    }

yed01 avatar Aug 16 '22 18:08 yed01

Nice one for figuring it out, and thanks for letting me know :)


Is there a way to make Glances work with Dashy without the Glances WEB-UI?

Yes, I think starting Glances with something like this will have the API working, but disable the web UI:

glances -w --disable-webui

but I'm not sure if it's safe to do it that way

Would probably dpend on where your runing it. I wouldn't expose it to the internet, but if it's only running within your LAN, then probably okay.


It's still strange that there is only one widget which has a problem with the Nginx Authentication.

Yeah, this is super strange. I'll look into it this weekend, I'm fairly sure this widget works the same as the rest, so I can't think of a reason for this off the top of my head.

Lissy93 avatar Aug 16 '22 21:08 Lissy93

Something has to be different with this widget, as soon as I activate some kind of authentication, in Nginx or directly in Glances, it's not working.

Great, appreciate your time.

yed01 avatar Aug 17 '22 10:08 yed01

This issue has gone 6 weeks without an update. To keep the ticket open, please indicate that it is still relevant in a comment below. Otherwise it will be closed in 5 working days.

liss-bot avatar Sep 17 '22 01:09 liss-bot

This issue was automatically closed because it has been stalled for over 6 weeks with no activity.

liss-bot avatar Sep 22 '22 01:09 liss-bot