at the moment we have a few odoo databases for one instance of odoo running with one of them as a test database. Since it can be problematic to upload a newer version of a module to test on the test database while it's already installed on another database it seems that we have to use at least another instance of odoo for our test databases. Is there maybe another solution? We are working with odoo community 14. What's your approach for testing?
1 Answers
1st solution : how about installing another instance of odoo community ?
2nd solution : you could install Odoo.sh Enterprise, so that you get multiple Git-"Branches" running with several database copies.
3rd solution : You could install several virtual environnment on your local computer (see : Odoo Cookboook).
step 1 : install python 3.8 + and virtualenv , postgresql and pgAdmin https://www.postgresql.org/download/macosx/
step 2 : download odoo source file : https://www.odoo.com/fr_FR/page/download
step 3 : create 2 virtualenv using this command to use it for odoo
virtualenv -p python3.8 Odoo13-virtualenv
virtualenv -p python3.8 Odoo13bis-virtualenv
which create a python3.8 virtualenv for your odoo installation. Let's install all odoo requirements in your virtualenv. Open the virtualenv folder from your terminal and activate you virtualenv :
source bin/activate
step 4 : create a src folder for odoo :
mkdir src
then unzip the odoo source.zip file you downloaded from odoo website , in the src folder , then install all the requirements for odoo from the requirements.txt file :
cd src
git clone https://github.com/odoo/odoo.git -b 14.0 --depth=1
pip3 install -r requirements.txt
Run the setup.py file to install your odoo virtualenv:
cd src/odoo
python setup.py install
sudo pip3 install --user -U psycopg2==2.8
step 5 :install pgAdmin, connect it, and create a new database : db14
step 6 : Start your odoo virtualenv:
odoo --addons-path=addons --database=db14 --db_host=127.0.0.1 -u base