You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As you can see Mercure is behind the caddy reverse proxy. It is accessible only from the frankenphp shell.
inside the frankenphp docker shell i can see it is working since i'm getting 404 errors from frankenphp for all URLs but for URLs beginnning with /.well-known/mercure* i'm getting HTTP 200 OK but the length of the response is always 0 bytes.
I think the zero length is not from the mercure server but from frankenphp server because when mercure answer at localhost:3000 i'm getting something like this :
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
I'm trying to make mercure works since it is already integrated into the frankenphp docker image.
Here is my Caddyfile that is mounted into /etc/caddy/Caddyfile :
As you can see Mercure is behind the caddy reverse proxy. It is accessible only from the frankenphp shell.
inside the frankenphp docker shell i can see it is working since i'm getting 404 errors from frankenphp for all URLs but for URLs beginnning with /.well-known/mercure* i'm getting HTTP 200 OK but the length of the response is always 0 bytes.
I installed httpie package via apt
root@57729b3b5377:/app# http "https://mydomain.fr/.well-known/mercure?topic=chat/user/3/updates&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJtZXJjdXJlIjp7InN1YnNjcmliZSI6"
HTTP/1.1 200 OK
Alt-Svc: h3=":443"; ma=2592000
Content-Length: 0
Date: Mon, 13 Jan 2025 20:48:55 GMT
Server: Caddy, Caddy
I think the zero length is not from the mercure server but from frankenphp server because when mercure answer at localhost:3000 i'm getting something like this :
root@57729b3b5377:/app# http "http://localhost:3000/.well-known/mercure?topic=chat/user/3/updates&token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJtZXJjdXJlIjp7InN1YnNjcmliZSI6WyIqIl19LCJleHAiOjE3MzY4MDUxNTF9.U1UawedmyLA8i2s74tGSHMbyxSJfjzhjcCnsc7Oh6fs=&heartbeat=1&lastEventID="
HTTP/1.1 401 Unauthorized
Content-Length: 13
Content-Security-Policy: default-src 'self'
Content-Type: text/plain; charset=utf-8
Date: Mon, 13 Jan 2025 20:53:12 GMT
Server: Caddy
X-Content-Type-Options: nosniff
X-Frame-Options: DENY
X-Xss-Protection: 1; mode=block
Unauthorized
Should i have to open external ports in the docker compose config to make mercure directly accessible from the outside ?
Beta Was this translation helpful? Give feedback.
All reactions