Closed vasyugan closed 5 years ago
Just to be sure: did Uwazi also stores data inside the uwazi service? It is not only on the mongodb with extra indices for fast searches on elasticsearch?
If yes, then we have a problem that could need changes to Uwazi itself.
That would be the uploaded_documents folder, where all the documents live, and the logs dir.
With an environment variable, it can be stored in a different location, see https://github.com/huridocs/uwazi/issues/2005#issuecomment-429755143
I would suggest passing the environment variable to the uwazi container and adding a named volume or bind mount for the directory.
Wow. That was really one undocumented feature on the Uwazi itself.
I would suggest to add backup and restore functionality that can be passed to the container, similar to "first run", where in backup a database dump and a copy of the uploaded_documents directory are saved on the host and with restore, the reverse is done, plus a run of yarn reindex.
Created another issue just for that.
And, about the uploaded_documents, that was not really a undocumented feature. Even without the environment variable to move the folder outside the repository, with docker still possible to mount a different volume on any path, but I forgot to setup that explicit and only now someone reported.
The contents of the Uwazi document directory and the mongodb database seem to be the two things which contain all the payload of Uwazi. Thus the documents dir should not be part of the Uwazi container but on a separate volume, like the db.