unable to run mayan-edms.py -> Your database backend is set to use SQLite [SOLVED]

Questions, comments, discussions. Over time certain topics might be moved to their own category.
Post Reply
fulkron
Posts: 2
Joined: Fri Mar 26, 2021 5:25 pm

unable to run mayan-edms.py -> Your database backend is set to use SQLite [SOLVED]

Post by fulkron »

Hello everybody,
I'm Mayan newbie and forgive me if this question is trivial...

I installed Mayan on Ubuntu Server 20.04 using direct installation (no Docker).
It is OK and I would like to install document_analizer app (as for https://gitlab.com/startmat/document_analyzer) to extract Meta-Data from OCR using RegEx (Is it the best way ?)

The last step in the read-me says: run the migrations for the app: mayan-edms.py migrate

The first error message I receive (always also without the command "migrate") is:

/opt/mayan-edms/lib/python3.8/site-packages/mayan/apps/common/apps.py:142: DatabaseWarning: Your database backend is set to use SQLite. SQLite should only be used for development and testing, not for production.

... and I receive several other error messages but I think are a consequence.

PostgreSQL is installed (of course) and working (seems fine to me because is able to store documents).

I do not know how to sort it.

Any help is very appreciated!

Thanks

Dario
Last edited by fulkron on Tue Mar 30, 2021 6:30 am, edited 1 time in total.
fulkron
Posts: 2
Joined: Fri Mar 26, 2021 5:25 pm

Re: unable to run mayan-edms.py -> Your database backend is set to use SQLite

Post by fulkron »

Solved by myself and this post is for somebody else in case of the same issue :

I forgot to preceed the command with the database data ... so the complete command is:

sudo -u mayan MAYAN_DATABASES="{'default':{'ENGINE':'django.db.backends.postgresql','NAME':'mayan','PASSWORD':'mayanuserpass','USER':'mayan','HOST':'127.0.0.1'}}" \
MAYAN_MEDIA_ROOT=/opt/mayan-edms/media \
/opt/mayan-edms/bin/mayan-edms.py migrate
Post Reply