I have used the Dockerfile in the y-websocket repo to create a y-webserver. The commands I used are:
git clone https://github.com/yjs/y-websocket.git && cd y-websocket
docker build -t micrology/y-websocket .
docker run -d -t -p1234:1234 --rm micrology/y-websocket
This should expose the server in the docker image on localhost:1234. However, when I run an app accessing this, I get (in the console):
WebSocket connection to 'ws://localhost:1234/prsmVSZ-CAD-QTE-ZMM' failed:
If, however, I abort the docker image and run y-websocket server in the terminal using
HOST=localhost PORT=1234 npx y-websocket
my app works as expected.
What am I doing wrong?