Odoo 11 How to install: Difference between revisions

From WikiMLT
mNo edit summary
 
(10 intermediate revisions by the same user not shown)
Line 1: Line 1:
<noinclude>{{ContentArticleHeader/Linux_Server}}</noinclude>
<noinclude>{{ContentArticleHeader/Linux_Server}}</noinclude>
 
[https://www.odoo.com/ Odoo] pretends to be all-in-one management software. Here is presented how to install and setup it to work over HTTPS. Here are presented two alternative methods of Odos's installation – from the GitHib project and from the repository:
[https://www.odoo.com/ Odoo] pretends to be all-in-one management software. Here is presented how to install and setup it to work over HTTPS.
* [https://www.odoo.com/documentation/11.0/setup/install.html Install Odoo from the repository].
 
* [https://github.com/Yenthe666/InstallScript Install Odoo from the GitHib project].
== Install Odoo ==
== Install Odoo from the repository ==
* Here are presented two alternative methods of Odos's installation – from the GitHib project and from the repository.
 
=== A. [https://www.odoo.com/documentation/11.0/setup/install.html Install Odoo from the repository]. ===
This should be the preferable way. Install the dependencies, add the repository and its key, update the system and install the package:
This should be the preferable way. Install the dependencies, add the repository and its key, update the system and install the package:
<syntaxhighlight lang="bash">
<syntaxhighlight lang="bash">
sudo apt update && sudo apt install postgresql
sudo apt update && sudo apt install postgresql
Line 15: Line 11:
sudo apt update && sudo apt upgrade && sudo apt install odoo
sudo apt update && sudo apt upgrade && sudo apt install odoo
</syntaxhighlight>
</syntaxhighlight>
With this configuration you can control the service by the commands:
With this configuration you can control the service by the commands:
<syntaxhighlight lang="bash">sudo systemctl status odoo.service
<syntaxhighlight lang="bash">sudo systemctl status odoo.service
sudo systemctl restart odoo.service
sudo systemctl restart odoo.service
Line 23: Line 17:
sudo systemctl stop odoo.service
sudo systemctl stop odoo.service
</syntaxhighlight>
</syntaxhighlight>
The main configuration file is: <code>/etc/odoo/odoo.conf</code>.
The main configuration file is: <code>/etc/odoo/odoo.conf</code>.
 
== Install Odoo from the GitHib project ==
=== B. [https://github.com/Yenthe666/InstallScript Install Odoo from the GitHib project]. ===
* If you've followed 1.A skip this step – go to 2.
* If you've followed 1.A skip this step – go to 2.
This section uses [https://github.com/Yenthe666/InstallScript Yenthe V.G]'s installation scrip. I found this approach in the article: [https://www.rosehosting.com/blog/install-odoo-11-on-ubuntu-16-04/ Install Odoo 11 on Ubuntu 16.04...]. Download [https://raw.githubusercontent.com/Yenthe666/InstallScript/10.0/odoo_install.sh <code>odoo_install.sh</code>]:
This section uses [https://github.com/Yenthe666/InstallScript Yenthe V.G]'s installation scrip. I found this approach in the article: [https://www.rosehosting.com/blog/install-odoo-11-on-ubuntu-16-04/ Install Odoo 11 on Ubuntu 16.04...]. Download [https://raw.githubusercontent.com/Yenthe666/InstallScript/10.0/odoo_install.sh <code>odoo_install.sh</code>]:
 
<syntaxhighlight lang="shell" line="1">
<syntaxhighlight lang="bash">
wget https://raw.githubusercontent.com/Yenthe666/InstallScript/11.0/odoo_install.sh
wget https://raw.githubusercontent.com/Yenthe666/InstallScript/11.0/odoo_install.sh
</syntaxhighlight>
</syntaxhighlight>
Edit <code>odoo_install.sh</code> and modify the parameters, under the section <code>#fixed parameters</code>:
Edit <code>odoo_install.sh</code> and modify the parameters, under the section <code>#fixed parameters</code>:
* <code>OE_USER</code> will be the username for the system user, the default one is <code>odoo</code>.
* <code>OE_USER</code> will be the username for the system user, the default one is <code>odoo</code>.


* By default the script will create user's home directory <code>/<odoo user></code>. You could leave the following values as default, but I would prefer <code>/home/<odoo user></code>:
* By default the script will create user's home directory <code>/<odoo user></code>. You could leave the following values as default, but I would prefer <code>/home/<odoo user></code>:
 
: <syntaxhighlight lang="bash" line="1" start="19">
: <syntaxhighlight lang="bash">
OE_HOME="/home/$OE_USER"
OE_HOME="/home/$OE_USER"
OE_HOME_EXT="$OE_HOME/${OE_USER}-server"
OE_HOME_EXT="$OE_HOME/${OE_USER}-server"
</syntaxhighlight>
</syntaxhighlight>
* <code>INSTALL_WKHTMLTOPDF</code> set to False if you do not want to install Wkhtmltopdf, if you want to install it you should set it to <code>True</code>.
* <code>INSTALL_WKHTMLTOPDF</code> set to False if you do not want to install Wkhtmltopdf, if you want to install it you should set it to <code>True</code>.


Line 55: Line 41:


* <code>OE_SUPERADMIN</code> is the master password for this Odoo installation. The default pass is <code>admin</code>.
* <code>OE_SUPERADMIN</code> is the master password for this Odoo installation. The default pass is <code>admin</code>.
Make <code>odoo_install.sh</code> executable and execute it as ''root'':
Make <code>odoo_install.sh</code> executable and execute it as ''root'':
 
<syntaxhighlight lang="shell" line="1">
<syntaxhighlight lang="bash">
chmod +x odoo_install.sh && sudo ./odoo_install.sh
chmod +x odoo_install.sh && sudo ./odoo_install.sh
</syntaxhighlight>
</syntaxhighlight>
You could control the application by the commands:
You could control the application by the commands:
<syntaxhighlight lang="bash">
<syntaxhighlight lang="shell" line="1">
sudo /etc/init.d/odoo-server restart
sudo /etc/init.d/odoo-server restart
sudo /etc/init.d/odoo-server start
sudo /etc/init.d/odoo-server start
sudo /etc/init.d/odoo-server stop
sudo /etc/init.d/odoo-server stop
</syntaxhighlight>
</syntaxhighlight>
The configuration file is: <code>/etc/odoo-server.conf</code>.
The configuration file is: <code>/etc/odoo-server.conf</code>.
== Proceed the installation of ODOO through the web interface ==
== Proceed the installation of ODOO through the web interface ==
* Use [https://www.odoo.com/documentation/11.0/setup/deploy.html#supported-browsers supported web browser]. Click on the image to see the animation.
{{media
 
| n = 1
{{media|img=How to install Odoo 1.gif|pos=center|bo=off|sz=640|text=off}}
| img = How to install Odoo 1.gif
| pos = center
| label = f
| sz = 1200
}}


== Reverse proxy ==
== Reverse proxy ==
In order to access your Odoo application only by using your domain name, without the port number in the URL, or through HTTPS, you need to set up a reverse proxy:
In order to access your Odoo application only by using your domain name, without the port number in the URL, or through HTTPS, you need to set up a reverse proxy:
* To use '''Apache''' as Reverse proxy – follow step 7 from the article [[:File:How To Install Odoo 11 on Ubuntu 16.04 by Jeff Wilson at RoseHosting.pdf]].
* To use '''Apache''' as Reverse proxy – follow step 7 from the article [[:File:How To Install Odoo 11 on Ubuntu 16.04 by Jeff Wilson at RoseHosting.pdf]].
: [https://httpd.apache.org/docs/2.4/howto/reverse_proxy.html '''Apache: Reverse Proxy Guide''']
* See also [https://httpd.apache.org/docs/2.4/howto/reverse_proxy.html '''Apache: Reverse Proxy Guide'''] and the repository [https://github.com/metalevel-tech/a2proxy metalevel-tech/'''a2proxy'''] at GitHub.
* To use '''Nginx''' as Reverse proxy – follow the Section [https://www.odoo.com/documentation/11.0/setup/deploy.html#https HTTPS from the Odoo's documentation].
* To use '''Nginx''' as Reverse proxy – follow the Section [https://www.odoo.com/documentation/11.0/setup/deploy.html#https HTTPS from the Odoo's documentation].
* <code>stunnel4</code> also could be applicable...
* <code>stunnel4</code> also could be applicable...
Line 86: Line 71:
{{devStage  
{{devStage  
  | Прндл  = Linux Server
  | Прндл  = Linux Server
  | Стадий = 3
  | Стадий = 6
  | Фаза  = Разработване
  | Фаза  = Утвърждаване
  | Статус = Разработван
  | Статус = Утвърден
  | ИдтПт  = Spas
  | ИдтПт  = Spas
  | РзбПт  = {{REVISIONUSER}}
  | РзбПт = Spas
| АвтПт  = Spas
| УтвПт = {{REVISIONUSER}}
  | ИдтДт  = 3.08.2022
  | ИдтДт  = 3.08.2022
  | РзбДт  = {{Today}}
  | РзбДт = 3.08.2022
| АвтДт  = 3.08.2022
| УтвДт = {{Today}}
  | ИдтРв  = [[Special:Permalink/29813|29813]]
  | ИдтРв  = [[Special:Permalink/29813|29813]]
  | РзбРв  = {{REVISIONID}}
  | РзбРв = [[Special:Permalink/29822|29822]]
| АвтРв  = [[Special:Permalink/29823|29823]]
| УтвРв = {{REVISIONID}}
}}
}}
</div>
</div>
</noinclude>
</noinclude>

Latest revision as of 10:37, 9 August 2022

Odoo pre­tends to be all-in-one man­age­ment soft­ware. Here is pre­sent­ed how to in­stall and set­up it to work over HTTPS. Here are pre­sent­ed two al­ter­na­tive meth­ods of Odos's in­stal­la­tion – from the GitHib project and from the repos­i­to­ry:

In­stall Odoo from the repos­i­to­ry

This should be the prefer­able way. In­stall the de­pen­den­cies, add the repos­i­to­ry and its key, up­date the sys­tem and in­stall the pack­age:

sudo apt update && sudo apt install postgresql
wget -O - https://nightly.odoo.com/odoo.key | sudo apt-key add -
echo "deb http://nightly.odoo.com/11.0/nightly/deb/ ./" | sudo tee /etc/apt/sources.list.d/odoo.list
sudo apt update && sudo apt upgrade && sudo apt install odoo

With this con­fig­u­ra­tion you can con­trol the ser­vice by the com­mands:

sudo systemctl status odoo.service
sudo systemctl restart odoo.service
sudo systemctl start odoo.service
sudo systemctl stop odoo.service

The main con­fig­u­ra­tion file is: /etc/odoo/odoo.conf.

In­stall Odoo from the GitHib project

  • If you've fol­lowed 1.A skip this step – go to 2.

This sec­tion us­es Yen­the V.G's in­stal­la­tion scrip. I found this ap­proach in the ar­ti­cle: In­stall Odoo 11 on Ubun­tu 16.04…. Down­load odoo_install.sh:

wget https://raw.githubusercontent.com/Yenthe666/InstallScript/11.0/odoo_install.sh

Ed­it odoo_install.sh and mod­i­fy the pa­ra­me­ters, un­der the sec­tion #fixed pa­ra­me­ters:

  • OE_USER will be the user­name for the sys­tem user, the de­fault one is odoo.
  • By de­fault the script will cre­ate user's home di­rec­to­ry /<odoo user>. You could leave the fol­low­ing val­ues as de­fault, but I would pre­fer /home/<odoo user>:
OE_HOME="/home/$OE_USER"
OE_HOME_EXT="$OE_HOME/${OE_USER}-server"
  • INSTALL_WKHTMLTOPDF set to False if you do not want to in­stall Wkhtml­topdf, if you want to in­stall it you should set it to True.
  • OE_PORT is the port where Odoo should run on, for ex­am­ple 8069.
  • OE_VERSION is the Odoo ver­sion to in­stall, for ex­am­ple 11.0 for Odoo V11.
  • IS_ENTERPRISE will in­stall the En­ter­prise ver­sion on top of 11.0 if you set it to True, set it to False if you want the com­mu­ni­ty ver­sion of Odoo 11.
  • OE_SUPERADMIN is the mas­ter pass­word for this Odoo in­stal­la­tion. The de­fault pass is ad­min.

Make odoo_install.sh ex­e­cutable and ex­e­cute it as root:

chmod +x odoo_install.sh && sudo ./odoo_install.sh

You could con­trol the ap­pli­ca­tion by the com­mands:

sudo /etc/init.d/odoo-server restart
sudo /etc/init.d/odoo-server start
sudo /etc/init.d/odoo-server stop

The con­fig­u­ra­tion file is: /etc/odoo-server.conf.

Pro­ceed the in­stal­la­tion of ODOO through the web in­ter­face

Figure 1. Steps of Odoo 11 in­stal­la­tion through the web in­ter­face. Use a sup­port­ed web brows­er. Click on the im­age to see the an­i­ma­tion.

Re­verse proxy

In or­der to ac­cess your Odoo ap­pli­ca­tion on­ly by us­ing your do­main name, with­out the port num­ber in the URL, or through HTTPS, you need to set up a re­verse proxy: