Yooooomi / your_spotify

Self hosted Spotify tracking dashboard
GNU General Public License v3.0
2.85k stars 113 forks source link

It says "Could not retrieve global preferences", when I now go to login into my Spotify #190

Closed nath2125 closed 1 year ago

nath2125 commented 1 year ago

Describe the bug

It says "Could not retrieve global preferences", when I now go to login into my Spotify. I have everything linked and mongo DB running also and restarted all 3 containers it creates in the stack in my portainer and I'm having the same issues.

I am also running this in portainer as said above.

Expected behaviour

Normally this doesn't happen and I have been running it now for a month and it works every time. Today I tried it after not looking at it for a few days and it came up with this.

My Compose

version: "3"

services:
  server:
    image: yooooomi/your_spotify_server
    restart: always
    ports:
      - "8085:8080"
    links:
      - mongo
    depends_on:
      - mongo
    environment:
      - API_ENDPOINT=http://192.168.10.7:8085 # This MUST be included as a valid URL in the spotify dashboard (see below)
      - CLIENT_ENDPOINT=http://192.168.10.7:8086
      - SPOTIFY_PUBLIC=(takenout)
      - SPOTIFY_SECRET=(takenout)
      - CORS=http://192.168.10.7:3000,http://192.168.10.7:3001,http://192.168.10.7:8086 # all if you want to allow every origin
  mongo:
    container_name: mongo
    image: mongo:4.4.8
    volumes:
      - ./your_spotify_db:/data/db

  web:
    image: yooooomi/your_spotify_client
    restart: always
    ports:
      - "8086:3000"
    environment:
      - API_ENDPOINT=http://192.168.10.7:8085

Screenshots

image

image

If there is more required let me know. I'm not to sure what I'm looking for which is why I have given as much as I can think of here

Yooooomi commented 1 year ago

Hello, sad to hear this. Can you share your browser logs too? Feels like CORS issues but not sure. Thanks

nath2125 commented 1 year ago

Do you mean like my chrome logs? or your-spotify-server-1 or your-spotify-web-1 within portainer?

Yooooomi commented 1 year ago

If I can have both this would be great :)

nath2125 commented 1 year ago

Your-Spotify-Server-1 Logs _your-spotify-server-1_logs.txt

Your-Spotify-Web-1 Logs _your-spotify-web-1_logs.txt

MongoDB Logs _mongo_logs.txt

Need to find out how to get my browser logs, because I'm unfamiliar with that.

Yooooomi commented 1 year ago

Right click your page, inspect, then head to the console tab. Refresh the page and try to log in

nath2125 commented 1 year ago

Browser Console image

Yooooomi commented 1 year ago

Oh ok it's a classic where your proxy set a custom header for the request. This is something I have to fix. You're not the only one having this issue. For the moment, you have to configure your proxy to strip this header when responding. I'll try to fix this before next weekend.

nath2125 commented 1 year ago

Il probably waits till you have it fixed. No rush ofc. Just because I'm also unsure how to do that either. There is still quite a lot I'm not sure about. Constantly a learning game for me!

Yooooomi commented 1 year ago

Should be fixed with new release :)

Kamaris521 commented 1 year ago

I updated today and started receiving this same error. I am using Caddy for my reverse proxy.

paulchartres commented 1 year ago

Same problem here, using Traefik as a reverse proxy. I'm getting this error: image

makanimike commented 1 year ago

is this something that returned in the last release? I did an update, and since then, I cannot log in anymore....