We are seeing the following error when we deploy a Gramex portal in production as time passes by.
Inotify._raise_error()
File "/opt/conda/lib/python3.7/site-packages/watchdog/observers/inotify_c.py", line 421, in _raise_error
raise OSError(errno.ENOSPC, "inotify watch limit reached")
OSError: [Errno 28] inotify watch limit reached
The error does not occur immediately after we deploy. It occurs after 1 or 2 hours after deployment. After that, the portal stops working. We're restarting our docker containers when the application stops responding after 2 or 3 hours.
Set
watch: false
underapp:
in yourgramex.yaml
.You can increase the inotify limit in the host, but you can't set these in docker containers.
This means that if your files change, Gramex needs to be restarted. But it won't fail due to the inotify limit.