weslambert / velocistack

GNU General Public License v3.0
49 stars 15 forks source link

IRIS web app not available #8

Closed CyberKaizen closed 1 year ago

CyberKaizen commented 2 years ago

Following the instructions in the README, all services are setup and reachable except for the IRIS web app.

I've spent about an hour troubleshooting and was unable to identify what was causing it not to be accessible.

Using curl from the same VM in which the services is hosted causes a 502 regardless of using the loopback address or assigned IP of the system.

I also checked the docker containers related to it to make sure they are up and functional and did not find any issues there.

Any advice?

weslambert commented 2 years ago

You might try having a look at the container logs for iris-web, using docker logs.

Ex. sudo docker logs iris-web

I know in the past, the app might time out waiting for the DB if it is not ready, etc. Maybe you are experiencing something similar?

CyberKaizen commented 2 years ago

This is the output I got from that command: db:5432 - accepting connections Running iriswebapp ... [2022-09-19 22:18:15 +0000] [8] [INFO] Starting gunicorn 20.1.0 [2022-09-19 22:18:15 +0000] [8] [INFO] Listening at: http://0.0.0.0:8000 (8) [2022-09-19 22:18:15 +0000] [8] [INFO] Using worker: eventlet [2022-09-19 22:18:15 +0000] [11] [INFO] Booting worker with pid: 11 [2022-09-19 22:18:16 +0000] [11] [ERROR] Exception in worker process Traceback (most recent call last): File "/opt/venv/lib/python3.9/site-packages/gunicorn/arbiter.py", line 589, in spawn_worker worker.init_process() File "/opt/venv/lib/python3.9/site-packages/gunicorn/workers/geventlet.py", line 134, in init_process super().init_process() File "/opt/venv/lib/python3.9/site-packages/gunicorn/workers/base.py", line 134, in init_process self.load_wsgi() File "/opt/venv/lib/python3.9/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi self.wsgi = self.app.wsgi() File "/opt/venv/lib/python3.9/site-packages/gunicorn/app/base.py", line 67, in wsgi self.callable = self.load() File "/opt/venv/lib/python3.9/site-packages/gunicorn/app/wsgiapp.py", line 58, in load return self.load_wsgiapp() File "/opt/venv/lib/python3.9/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp return util.import_app(self.app_uri) File "/opt/venv/lib/python3.9/site-packages/gunicorn/util.py", line 359, in import_app mod = importlib.import_module(module) File "/usr/local/lib/python3.9/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in _load_unlocked File "", line 850, in exec_module File "", line 228, in _call_with_frames_removed File "/iriswebapp/app/init.py", line 66, in app.config.from_object('app.configuration.Config') File "/opt/venv/lib/python3.9/site-packages/flask/config.py", line 162, in from_object obj = import_string(obj) File "/opt/venv/lib/python3.9/site-packages/werkzeug/utils.py", line 871, in import_string import(import_name) File "/iriswebapp/app/configuration.py", line 34, in PGACCOUNT = os.environ.get('DB_USER', config.get('POSTGRES', 'PG_ACCOUNT')) File "/usr/local/lib/python3.9/configparser.py", line 781, in get d = self._unify_values(section, vars) File "/usr/local/lib/python3.9/configparser.py", line 1152, in _unify_values raise NoSectionError(section) from None configparser.NoSectionError: No section: 'POSTGRES' [2022-09-19 22:18:16 +0000] [11] [INFO] Worker exiting (pid: 11) [2022-09-19 22:18:17 +0000] [8] [INFO] Shutting down: Master [2022-09-19 22:18:17 +0000] [8] [INFO] Reason: Worker failed to boot. db:5432 - accepting connections Running iriswebapp ... [2022-09-19 23:22:14 +0000] [8] [INFO] Starting gunicorn 20.1.0 [2022-09-19 23:22:14 +0000] [8] [INFO] Listening at: http://0.0.0.0:8000 (8) [2022-09-19 23:22:14 +0000] [8] [INFO] Using worker: eventlet [2022-09-19 23:22:14 +0000] [27] [INFO] Booting worker with pid: 27 [2022-09-19 23:22:50 +0000] [27] [ERROR] Exception in worker process Traceback (most recent call last): File "/opt/venv/lib/python3.9/site-packages/gunicorn/arbiter.py", line 589, in spawn_worker worker.init_process() File "/opt/venv/lib/python3.9/site-packages/gunicorn/workers/geventlet.py", line 134, in init_process super().init_process() File "/opt/venv/lib/python3.9/site-packages/gunicorn/workers/base.py", line 134, in init_process self.load_wsgi() File "/opt/venv/lib/python3.9/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi self.wsgi = self.app.wsgi() File "/opt/venv/lib/python3.9/site-packages/gunicorn/app/base.py", line 67, in wsgi self.callable = self.load() File "/opt/venv/lib/python3.9/site-packages/gunicorn/app/wsgiapp.py", line 58, in load return self.load_wsgiapp() File "/opt/venv/lib/python3.9/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp return util.import_app(self.app_uri) File "/opt/venv/lib/python3.9/site-packages/gunicorn/util.py", line 359, in import_app mod = importlib.import_module(module) File "/usr/local/lib/python3.9/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in _load_unlocked File "", line 850, in exec_module File "", line 228, in _call_with_frames_removed File "/iriswebapp/app/init.py", line 66, in app.config.from_object('app.configuration.Config') File "/opt/venv/lib/python3.9/site-packages/flask/config.py", line 162, in from_object obj = import_string(obj) File "/opt/venv/lib/python3.9/site-packages/werkzeug/utils.py", line 871, in import_string import(import_name) File "/iriswebapp/app/configuration.py", line 34, in PGACCOUNT = os.environ.get('DB_USER', config.get('POSTGRES', 'PG_ACCOUNT')) File "/usr/local/lib/python3.9/configparser.py", line 781, in get d = self._unify_values(section, vars) File "/usr/local/lib/python3.9/configparser.py", line 1152, in _unify_values raise NoSectionError(section) from None configparser.NoSectionError: No section: 'POSTGRES' [2022-09-19 23:22:50 +0000] [27] [INFO] Worker exiting (pid: 27) [2022-09-19 23:22:51 +0000] [8] [INFO] Shutting down: Master [2022-09-19 23:22:51 +0000] [8] [INFO] Reason: Worker failed to boot.

weslambert commented 2 years ago

Thanks! Let me see if I can replicate it. We recently pulled in some changes, so maybe there is something that needs adjusting. Thanks again for testing!

weslambert commented 2 years ago

I've made some recent changes to the configuration. Please try again using a fresh install, or by removing all directories/docker volumes/images, and let me know if you run into the same issue.

CyberKaizen commented 2 years ago

Thanks, I'll try it out and get back to you.

weslambert commented 1 year ago

Please re-open this issue if you still have problems.