安全Websocket无法使用AWS ELB + Cloudflare SSL

I'm building a chat using websocket in php.

Everything work's fine using ws but i receive an error 504 bad gateway when i try to use wss (secure).

SSL in use is the default one on cloudflare (full, always use https) and all traffic without www are redirected to www

My websocket use port 8443 that work on cloudflare

On AWS i use a application load balancer containing only 1 instance and security group allow port 8443 as it work without the secure Websocket.

Any idea where my problem could be ?