-
Notifications
You must be signed in to change notification settings - Fork 26
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
Covers from Sonos Devices not shown - wrong HTTP-Port #487
Comments
What is the content of the state with the cover? |
The relative URL to the image with leading "/" |
So in the example it would be I'm a bit confused. I did not write that part, but for some reason there is support for URLs starting with ioBroker.lovelace/lib/server.js Line 1832 in 6f9a4b5
Not sure if the URL in Sonos should start with the string "adapter". |
correct.
As I understand the mentioned code right, it is only rewriting relative URL-parts (i.e. "/adapter/...") to something else. I have the assumption, that all URLs for frontend data (html, images, js and css) the adapter intended to be delivered by the web-server of the lovelace instance. And this is addressed by the given port in the preferences of the adapter (here: 8091). So, the parts, where data are fetched from the ioBroker itself (i.e. images for media-player) the assumption, that the lovelace-webserver delivers them is wrong and should be corrected to work correctly. |
That would be one, very hacky, way with a lot of issues. You'd need access to both servers, the server of the web instance might ask for a password, which would break lovelace, if one of both is https and the other one is not, a lot of other issues will happen. So that is why the code above reads the file from the iobroker filesystem and delivers it from the lovelace webserver. Did you try to add "/adapter/" in front of the URL? That would really help. |
fixes sonos cover image issue #487 Might solve a security (?) issue with auth enabled users would have read access to all adapter.admin files, because it did never check user before.
Describe the bug
When using a Sonos Device as etity for a media-Player, the corect URL-String is fetched from the data point.
But the wrong HTTP-Port is used.
It is used the Port from the lovelace-Webserver (in my case 8091) but the cover-Image is distributed by the IOBroker-Webserver (in my case 8082)
To Reproduce
Steps to reproduce the behavior:
http://IPADDRESS:8091/sonos/coverImage/192_168_34_233.png
Expected behavior
While changing this in developer view in Chrome into:
http://IPADDRESS:8082/sonos/coverImage/192_168_34_233.png
Screenshots & Logfiles
If applicable, add screenshots and logfiles to help explain your problem.
Versions:
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: