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

Cover Art URI schema #1229

Open
cuthulino opened this issue May 1, 2024 · 2 comments
Open

Cover Art URI schema #1229

cuthulino opened this issue May 1, 2024 · 2 comments

Comments

@cuthulino
Copy link

cuthulino commented May 1, 2024

Describe the bug
I am serving snapweb with an reverse proxy to get https.
The frontend and all controls are working as desired.

But the coverart does not work.

To me it looks like it is hardcoded to load http://<hostname_from_config>:1780.
For my config this would be correct: https://<hostname_from_config>.

It would be great, to get an additional config, to configure the cover art url.
Or even better, build the url dependen on the url the UI is loaded.

Steps to Reproduce

  1. Serve Snapweb via reverse Proxy with https
  2. Open Snapweb and Dev-Console
  3. See logs in console

Environment details

  • OS: debian
  • Snapcast version: 0.28.0
  • Installed from .deb package

Attach logfile if applicable
grafik

@badaix
Copy link
Owner

badaix commented May 8, 2024

Related to #1139

@badaix
Copy link
Owner

badaix commented May 11, 2024

FYI: the tls branch supports HTTPS out of the box. If you want to test it, you can use a snapshot from the CI built: https://github.com/badaix/snapcast/actions/runs/9043310893

The snapserver.conf has a new section ssl, where you have to configure your certificate and key:

# Secure Socket Layer #########################################################
#
[ssl]
# https://deliciousbrains.com/ssl-certificate-authority-for-local-https-development/
# https://gist.github.com/fntlnz/cf14feb5a46b2eda428e000157447309

# Certificate file in PEM format
# certificate = 

# Private key file in PEM format
# private_key = 

# Password for decryption of the private_key (only needed for encrypted private_key file)
# key_password =

#
###############################################################################

And ssl_enabled must be set to true in the HTTP settings:

# HTTP RPC ####################################################################
#
[http]
# enable HTTP Json RPC (HTTP POST and websockets)
#enabled = true

# address to listen on, can be specified multiple times
# use "0.0.0.0" to bind to any IPv4 address or :: to bind to any IPv6 address
# or "127.0.0.1" or "::1" to bind to localhost IPv4 or IPv6, respectively
# use the address of a specific network interface to just listen to and accept
# connections from that interface
#bind_to_address = 0.0.0.0

# which port the server should listen to
#port = 1780

# enable HTTPS Json RPC (HTTPS POST and ssl websockets)
# ssl_enabled = false

# same as 'bind_to_address' but for SSL
# ssl_bind_to_address = 0.0.0.0

# same as 'port' but for SSL
# ssl_port = 1788

# serve a website from the doc_root location
# disabled if commented or empty
doc_root = /usr/share/snapserver/snapweb

# Hostname or IP under which clients can reach this host
# used to serve cached cover art
# use <hostname> as placeholder for your actual host name  
#host = <hostname>

#
###############################################################################

This is still work in progress, but I'm already using it and it's nice to see that Snapweb can be installed as PWA now, where the page is served via HTTPS.

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

2 participants