NIP-42 failed on non-443 with Flotilla(used behind nginx in Flotilla because of port mismatch) #2
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
this is my original issue link in github: https://github.com/coracle-social/zooid/issues/13
i showed the error and the line that cause it in the above link
in summary i have a nginx running on non-default port(8443) and the auth request fails because the public relay url that zooid thinks it has does not contain port i cannot include port in
hostin zooid config fileThanks for re-opening, I believe this is a configuration error, the host should include the port the client is connecting on (8443 if I understand correctly). Why aren't you able to set the port in the config file?
i tried "zooid.mydomain.com:8443" in zooid configuration but then zooid sends 404 for everything.
my guess is that i does that because:
client request(from x to zooid.mydomain.com:8443) -> nginx -> sets
Hostsheader to "zooid.mydomain.com" and sends it to zooid -> zooid -> compares requestHostsheader withhostincluded in configuration file which means"zooid.mydomain.com" != "zooid.mydomain.com:8443"-> so returns 404now i tried doing
proxy_set_header Host $host:$server_port;instead ofproxy_set_header Host $host;in nginx and still same issue (edit: now i understand why this failed too. i had using a nginx stream block which redirects requests to nginx http block. in my situation this makes$server_portwrong value and it's not equal to8443)Wowwww. replacing
proxy_set_header Host $host;withproxy_set_header Host $http_host;in nginx and usinghostwith port in zooid configuration seems worked!!!thank you very much
can you place add a notice in README to notify peaple that they should include port in
hostzooid configution if they are not using 443?and using wrong
proxy_set_header Host $host;is very common. it's nice to have a notice for that too.i found that in this link: https://serverfault.com/questions/363159/nginx-proxy-pass-redirects-ignore-port#407983
Thank you for the detailed information! Fixed in
64bde74