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

Setting photonix behind proxy #364

Open
gk1089 opened this issue Dec 21, 2021 · 1 comment
Open

Setting photonix behind proxy #364

gk1089 opened this issue Dec 21, 2021 · 1 comment

Comments

@gk1089
Copy link

gk1089 commented Dec 21, 2021

Describe the bug
I am facing issues in setting photonix up on a Ubuntu VM in a network that is connected to the internet through a proxy.

To Reproduce
I am able to set proxies for the VM, curl and for Docker and was able to install Photonix as described on the GitHib page. I am able to access the application in a browser on port 8888 and able to log into the application using the chosen credentials. However, upon adding the images to the data/photos folder, they did not automatically show up, so I restarted the docker and noticed a number of warnings and errors, most of which seem to be due to urllib not being able to connect to the internet. My main requirement is detection of faces in the photos and I guess Photonix wants to download models and tensorflow files for that, which is not happening. Upon restarting the docker, the images got detected but face detection did not happen.

Expected behavior
Functioning face detection feature on Photonix.

Screenshots
I have copied some sections of the errors that I felt were relevant:

photonix | 2021-12-21 05:36:30,207 ERROR Traceback (most recent call last):
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 489, in resolve_from_executor
photonix | executor(resolve, reject)
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 756, in executor
photonix | return resolve(f(*args, **kwargs))
photonix | File "/usr/local/lib/python3.8/site-packages/graphql/execution/middleware.py", line 75, in make_it_promise
photonix | return next(*args, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/mutations.py", line 60, in mutate
photonix | return cls.refresh(*arg, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/decorators.py", line 110, in wrapper
photonix | result = f(cls, root, info, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/mixins.py", line 24, in refresh
photonix | refresh_token = get_refresh_token(refresh_token, context)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/shortcuts.py", line 20, in get_refresh_token
photonix | raise JSONWebTokenError(
('Invalid refresh token'))
photonix | graphql.error.located_error.GraphQLLocatedError: Invalid refresh token

8", referrer: "http://172.xx.yy.zz:8888/login"
photonix | 2021/12/21 05:38:00 [error] 51#51: *1 no live upstreams while connecting to upstream, client: 172.xx.yy.pp, server: , request: "POST /graphql HTTP/1.1", upstream: "http://localhost/graphql", host: "172.xx.yy.zz:8888", referrer: "http://172.xx.yy.zz:8888/"
photonix | 2021/12/21 05:38:04 [error] 51#51: *1 no live upstreams while connecting to upstream, client: 172.xx.yy.pp, server: , request: "POST /graphql HTTP/1.1", upstream: "http://localhost/graphql", host: "172.xx.yy.zz:8888", referrer: "http://172.xx.yy.zz:8888/"
photonix | 2021-12-21 05:38:04,991 INFO success: app_server entered RUNNING state, process has stayed up for > than 5 seconds (startsecs)
photonix | 2021-12-21 05:38:05,962 INFO Watching new path: /data/photos
photonix | 2021-12-21 05:38:06,623 INFO Starting 1 raw processor workers
photonix | 2021-12-21 05:38:07,713 INFO Starting 1 thumbnail processor workers
photonix | 2021/12/21 05:38:07 [error] 51#51: *1 no live upstreams while connecting to upstream, client: 172.xx.yy.pp, server: , request: "POST /graphql HTTP/1.1", upstream: "http://localhost/graphql", host: "172.xx.yy.zz:8888", referrer: "http://172.xx.yy.zz:8888/"
photonix | 2021-12-21 05:38:08,993 INFO success: watch_photos entered RUNNING state, process has stayed up for > than 10 seconds (startsecs)
photonix | 2021-12-21 05:38:09,814 INFO Starting 1 classify.color workers
photonix | 2021/12/21 05:38:09 [error] 51#51: *1 no live upstreams while connecting to upstream, client: 172.xx.yy.pp, server: , request: "POST /graphql HTTP/1.1", upstream: "http://localhost/graphql", host: "172.xx.yy.zz:8888", referrer: "http://172.xx.yy.zz:8888/"
photonix | HTTPSConnectionPool(host='photonix.org', port=443): Max retries exceeded with url: /models.json (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f8f53b67490>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution'))
photonix | 2021-12-21 05:38:11,840 INFO exited: classification_location_processor (exit status 0; not expected)
photonix | 2021-12-21 05:38:12,844 INFO spawned: 'classification_location_processor' with pid 96
photonix | 2021-12-21 05:38:14,853 INFO success: raw_processor entered RUNNING state, process has stayed up for > than 16 seconds (startsecs)
photonix | 2021-12-21 05:38:14,853 INFO success: raw_scheduler entered RUNNING state, process has stayed up for > than 15 seconds (startsecs)
photonix | 2021-12-21 05:38:16,689 ERROR Traceback (most recent call last):
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 489, in resolve_from_executor
photonix | executor(resolve, reject)
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 756, in executor
photonix | return resolve(f(*args, **kwargs))
photonix | File "/usr/local/lib/python3.8/site-packages/graphql/execution/middleware.py", line 75, in make_it_promise
photonix | return next(*args, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/mutations.py", line 60, in mutate
photonix | return cls.refresh(*arg, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/decorators.py", line 110, in wrapper
photonix | result = f(cls, root, info, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/mixins.py", line 24, in refresh
photonix | refresh_token = get_refresh_token(refresh_token, context)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/shortcuts.py", line 20, in get_refresh_token
photonix | raise JSONWebTokenError(
('Invalid refresh token'))
photonix | graphql.error.located_error.GraphQLLocatedError: Invalid refresh token

photonix | 2021-12-21 05:38:16,690 INFO success: thumbnail_scheduler entered RUNNING state, process has stayed up for > than 17 seconds (startsecs)
photonix | 2021-12-21 05:38:17,198 INFO Starting 1 classify.event workers
photonix | 2021-12-21 05:38:17,201 INFO success: classification_scheduler entered RUNNING state, process has stayed up for > than 18 seconds (startsecs)
photonix | 2021-12-21 05:38:18,203 INFO success: classification_color_processor entered RUNNING state, process has stayed up for > than 19 seconds (startsecs)
photonix | 2021-12-21 05:38:18,707 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:18,748 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:18,752 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:18,813 WARNING Limited tf.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:19,739 INFO Starting 1 classify.face workers
photonix | 2021-12-21 05:38:19,863 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:19,901 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:19,902 INFO success: classification_face_detection_processor entered RUNNING state, process has stayed up for > than 21 seconds (startsecs)
photonix | 2021-12-21 05:38:19,904 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:19,962 WARNING Limited tf.summary API due to missing TensorBoard installation.
photonix | HTTPSConnectionPool(host='photonix.org', port=443): Max retries exceeded with url: /models.json (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7faa70a767f0>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution'))
photonix | 2021-12-21 05:38:20,732 INFO exited: classification_style_processor (exit status 0; not expected)
photonix | 2021-12-21 05:38:21,291 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:21,326 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:21,329 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:21,383 WARNING Limited tf.summary API due to missing TensorBoard installation.
photonix | HTTPSConnectionPool(host='photonix.org', port=443): Max retries exceeded with url: /models.json (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f914c4576d0>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution'))
photonix | 2021-12-21 05:38:22,043 INFO spawned: 'classification_style_processor' with pid 107
photonix | 2021-12-21 05:38:22,052 INFO success: classification_object_processor entered RUNNING state, process has stayed up for > than 23 seconds (startsecs)
photonix | 2021-12-21 05:38:22,053 INFO exited: classification_object_processor (exit status 0; expected)
photonix | 2021-12-21 05:38:23,056 INFO success: classification_event_processor entered RUNNING state, process has stayed up for > than 24 seconds (startsecs)
photonix | HTTPSConnectionPool(host='photonix.org', port=443): Max retries exceeded with url: /models.json (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f563490d490>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution'))
photonix | 2021-12-21 05:38:25,300 INFO exited: classification_location_processor (exit status 0; not expected)
photonix | 2021-12-21 05:38:27,308 INFO spawned: 'classification_location_processor' with pid 111
photonix | 2021-12-21 05:38:38,013 ERROR Traceback (most recent call last):
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 489, in resolve_from_executor
photonix | executor(resolve, reject)
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 756, in executor
photonix | return resolve(f(*args, **kwargs))
photonix | File "/usr/local/lib/python3.8/site-packages/graphql/execution/middleware.py", line 75, in make_it_promise
photonix | return next(*args, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/mutations.py", line 60, in mutate
photonix | return cls.refresh(*arg, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/decorators.py", line 110, in wrapper
photonix | result = f(cls, root, info, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/mixins.py", line 24, in refresh
photonix | refresh_token = get_refresh_token(refresh_token, context)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/shortcuts.py", line 20, in get_refresh_token
photonix | raise JSONWebTokenError(
('Invalid refresh token'))
photonix | graphql.error.located_error.GraphQLLocatedError: Invalid refresh token

photonix | 2021-12-21 05:38:39,900 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:39,936 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | 2021-12-21 05:38:39,940 WARNING Limited tf.compat.v2.summary API due to missing TensorBoard installation.
photonix | HTTPSConnectionPool(host='photonix.org', port=443): Max retries exceeded with url: /models.json (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f926b729490>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution'))
photonix | 2021-12-21 05:38:39,998 WARNING Limited tf.summary API due to missing TensorBoard installation.
photonix | HTTPSConnectionPool(host='photonix.org', port=443): Max retries exceeded with url: /models.json (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f6097cb57f0>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution'))
photonix | 2021-12-21 05:38:40,178 INFO exited: classification_location_processor (exit status 0; not expected)
photonix | 2021-12-21 05:38:41,576 INFO exited: classification_style_processor (exit status 0; not expected)
photonix | 2021-12-21 05:38:43,587 INFO spawned: 'classification_style_processor' with pid 118
photonix | 2021-12-21 05:38:43,591 INFO spawned: 'classification_location_processor' with pid 119
photonix | 2021-12-21 05:38:53,315 ERROR Traceback (most recent call last):
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 489, in resolve_from_executor
photonix | executor(resolve, reject)
photonix | File "/usr/local/lib/python3.8/site-packages/promise/promise.py", line 756, in executor
photonix | return resolve(f(*args, **kwargs))
photonix | File "/usr/local/lib/python3.8/site-packages/graphql/execution/middleware.py", line 75, in make_it_promise
photonix | return next(*args, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/mutations.py", line 60, in mutate
photonix | return cls.refresh(*arg, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/decorators.py", line 110, in wrapper
photonix | result = f(cls, root, info, **kwargs)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/mixins.py", line 24, in refresh
photonix | refresh_token = get_refresh_token(refresh_token, context)
photonix | File "/usr/local/lib/python3.8/site-packages/graphql_jwt/refresh_token/shortcuts.py", line 20, in get_refresh_token
photonix | raise JSONWebTokenError(
('Invalid refresh token'))
photonix | graphql.error.located_error.GraphQLLocatedError: Invalid refresh token

Server (please complete the following information):
VM: Ubuntu 20.04 server edition, 2 Cores, 8 GB RAM, 100 GB HDD

Desktop (please complete the following information):
Being accessed using the latest chrome browser on a Windows 10 installation in the same network series.

Additional context
How do I make Photonix work behind proxy?

@audioscavenger
Copy link

same question here although i have none of those errors, just http 400

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

2 participants