iris-web
iris-web copied to clipboard
[BUG] First launch - app creates tables before the db service is connected
Describe the bug For some setups, the app tries to create tables before the db could start the postgresql service properly. Therefore, the app crashes (Connection refused). We should modify https://github.com/dfir-iris/iris-web/blob/master/source/app/post_init.py#L72 and test the availability of the database before any table creation.
To Reproduce Steps to reproduce the behavior:
- docker compose build
- docker compose up
- The app crashes because it cannot connect to the database
Again, the bug is triggered on some setups.
Server:
- Hypervisor KVM, VM Debian