rdbeach / wb

Online collaborative Whiteboard that is simple, free, easy to use and to deploy
https://lcfprep.com/wb2/wb.html
GNU Affero General Public License v3.0
24 stars 13 forks source link

Stuck at loading screen #3

Closed sujeet-agrahari closed 4 years ago

sujeet-agrahari commented 4 years ago

It's always stuck at loading image. Also, whitebaord data is not being saved on the server.

After refreshing all the drawing is lost.

Also, after opening the board with the same names as create, board is always clean.

image

rdbeach commented 4 years ago

Hi. If the loading image does not go away, it usually indicates some error, such as the inability to connect to the server. Are you able to draw on the board? Are you using the board locally or on a public site?

If you open the developer tools on chrome and go to the javascript console, you can see if there are any javascript error messages. If there are some, post them here. If you are using it on a public site, send me the link and I will take a look.

If you want to save the board, you will have to turn that on in the server/configuration.js file.

/** Save board data */
     SAVE_BOARDS: process.env['SAVE_BOARDS'] || true,

BTW this is a developmental board, not a finished product. So you may have to tinker with it a bit to get it working on your site. (It works though, I use it daily with my clients)

sujeet-agrahari commented 4 years ago

Actually, I have deployed it using docker. I am having CORS errror, but using cors package and it works fine for http and https requests. I have also deployed the the app that you have forked from, and it works fine.

:5002/board.html?board=Middleware#0,0,1.00:1 Access to XMLHttpRequest at 'http://glu.antino.io:8080/socket.io/?EIO=3&transport=polling&t=ND_4UoV' from origin 'http://glu.antino.io:5002' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
socket.io.js:5 GET http://glu.antino.io:8080/socket.io/?EIO=3&transport=polling&t=ND_4UoV net::ERR_FAILED
sujeet-agrahari commented 4 years ago

I think the problem might with using docker. I am running it with below command. sudo docker run -d --publish 5002:80 --volume $(pwd)/test-boards:/opt/app/server-data whiteboard

It will set PORT to 5002 in the server configuration, and I also set port to 80 in board.js file as it is running inside the container.

Also, tried changing board.js PORT to 5002, and setting nothing io.connect('', but still getting same error.

sujeet-agrahari commented 4 years ago

It fixed it thanks, closing this issue.

spoorun commented 3 years ago

It fixed it thanks, closing this issue.

We're having the same issue. @sujeet-agrahari do you mind explaining your fix? Thanks