Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error connecting to websocket on login page #134

Open
alorimer opened this issue Nov 18, 2019 · 3 comments
Open

Error connecting to websocket on login page #134

alorimer opened this issue Nov 18, 2019 · 3 comments

Comments

@alorimer
Copy link

Hi, I've been battling with Ownphotos for the last few days and trying to learn Docker in the process, and I'm at the stage where I need some help.

I have set up the Docker containers with docker-compose exactly as it appears in docker-compose.yml.template in this repo. So BACKEND_HOST is set to localhost:3000. Btw, I'm accessing the frontend through an SSH tunnel (the containers are running on a headless server) to eliminate any issues with CORS or hostnames. Thus, localhost:3000 on my local machine is really server:3000, but appears to both the server and local machine as localhost.

Anyway, I can load the login page fine, but after entering the details (the default demo and demo1234), the page doesn't load and it's as if nothing actually gets to the backend. Looking at the browser console, there seems to be trouble connecting to the backend websocket (these messages appear soon after the page is loaded):

14:30:02.019 Firefox can’t establish a connection to the server at ws://localhost:3000/sockjs-node/468/ttwper4c/websocket. websocket.js:6
14:30:04.898 The development server has disconnected. Refresh the page if necessary. webpackHotDevClient.js:76
14:30:10.178 TypeError: _jp.ayglh5t is not a function jsonp:1:9
14:30:31.637  action FETCH_SITE_SETTINGS_REJECTED @ 14:30:31.637 redux-logger.js

Upon clicking "log in", I get:

14:38:04.057 action LOGIN @ 14:38:04.057 redux-logger.js:1
14:38:25.458 action FETCH_SITE_SETTINGS_REJECTED @ 14:38:25.458 redux-logger.js:1
14:38:33.218 Object { match: {…}, location: {…}, history: {…}, staticContext: undefined, errors: {…}, siteSettings: {}, isAuthenticated: false, onSubmit: onSubmit(), fetchSiteSettings: fetchSiteSettings()}
login.js:23
14:38:33.231 Warning: Received `true` for a non-boolean attribute `secondary`. index.js:2178
    ...
14:38:33.233 action LOGIN_REJECTED @ 14:38:33.218 redux-logger.js:1

and then I get the "No connection to backend server" error.

In the logs for the ownphotos-backend container, it looks like a worker is failing to start. The following messages seem to loop indefinitey (I'm not sure if the SSE4.1 error is related - the server only has an Atom processor, so presumably dlib fails on import):

Dlib was compiled to use SSE41 instructions, but these aren't available on your machine.
Dlib was compiled to use SSE41 instructions, but these aren't available on your machine.
[2019-11-18 03:34:47 +0000] [99] [CRITICAL] WORKER TIMEOUT (pid:29833)
[2019-11-18 03:34:47 +0000] [99] [CRITICAL] WORKER TIMEOUT (pid:29834)
[2019-11-18 03:34:47 +0000] [29833] [INFO] Worker exiting (pid: 29833)
[2019-11-18 03:34:47 +0000] [29834] [INFO] Worker exiting (pid: 29834)
[2019-11-18 03:34:48 +0000] [29849] [INFO] Booting worker with pid: 29849
[2019-11-18 03:34:48 +0000] [29850] [INFO] Booting worker with pid: 29850
/miniconda/lib/python3.6/site-packages/sklearn/externals/joblib/externals/cloudpickle/cloudpickle.py:47: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
  import imp
/miniconda/lib/python3.6/site-packages/sklearn/externals/joblib/externals/cloudpickle/cloudpickle.py:47: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
  import imp

I tried pinging the containers from each of them to make sure the networking is okay, and that seems fine. I'm really not sure what to do at this point. I considered trying to compile dlib without SSE4.1, but I can't even find where it used (or located) in the backend container. But surely the frontend should still work even without a working dlib install?

Any ideas?

@Elektroman2
Copy link

Same error here. Also on Atom server (Intel D510MO)

@phantomtypist
Copy link

FYI, the project may be going to a new home as the former benevolent dictator has disappeared. Please see #137.

@derneuere
Copy link

The BACKEND_HOST should be from the point of view from the person opening the browser. So it should be an absolute url, something like 192.168.82.12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants