top of page
buypeterlamar

Installing Odoo 13 on Ubuntu 20.04 with Wkhtmltopdf and Node.js



Installation steps for previous Ubuntu version(s) till version Ubuntu 16 are similar. You can visit the blog for Odoo 11 installation on ubuntu 16.04 to know the step by step installation of the previous version.


Odoo requires the wkhtmltopdf package, which is an open-source tool that converts the HTML format to PDF so that Odoo can print PDF reports. The recommended version for Odoo is 0.12.5 with patched qt, which is the latest version at the time this tutorial was written. We will download and install it with the following commands:




How to Install Odoo 13 on Ubuntu



Now when you know that the fresh Odoo installation is active and running on the server, you can access it by navigating your server IP address along with the Odoo port number. In this case, our installed Odoo uses the default port 8069 (as defined in our Odoo configuration file):


PS. If you liked this post on how to install Odoo 13 on Ubuntu 20.04, please share it with your friends on the social networks using the buttons below or simply leave a reply. Thank you.


apt-get install python3-venv build-essential python3-pillow python3-lxml python3-dev python3-pip python3-setuptools npm nodejs git gdebi libldap2-dev libsasl2-dev libxml2-dev libxslt1-dev libjpeg-dev libpq-dev -y


2. Once the PostgresSQL installation is complete you need to check a few things. During the installation process, the installer is configured to start the postgresql service and enable it to automatically start when the server is rebooted. To check if the service is up and running, and is enabled, run the following systemctl commands.


Odoo 13 requires wkhtmltopdf v0.12.05 which is not provided in the Ubuntu repositories. So you need to install it manually by running the following commands.


The latest version of ubuntu 20.04 got released this April with a particular emphasis on security and performance. As they mentioned in their release notes Ubuntu 20.04 has much better performance than previous versions.


First, we always start our installations before we ensure our system is updated. Run the following command to update the APT list of available packages and their versions. Moreover, use the upgrade command to actually install newer versions of the packages.


Once the source code downloaded, You have to go to that directory. Here you see requirement.txt file. Python dependencies listed in the requirements.txt file. You have to execute the below command to install depended Python modules using pip3.


In this tutorial, you will learn how to install Odoo 13 inside a Python virtual environment on Ubuntu 18.04. Odoo will be downloaded from its respective Github repository and we will use Nginx as a reverse proxy.


1) The wkhtmltox package has a series of open-source command-line tools that render HTML files into PDF files and other image formats. For printing PDF reports, install the wkhtmltopdf tool. We recommended Odoo 0.12.5 version but it is not accessible through default Ubuntu 18.04 repositories.


We hope this detailed guide helped you understand how to install Odoo on Ubuntu 18.04. To learn more about Odoo installation, check out the official Odoo documentation.


Wkhtmltopdf is package that is used to render HTML to PDF and other image formats. If you are using Odoo to print PDF reports you should install wkhtmltopdf tool. The recommended version for Odoo is 0.12.5. This is not included in the default Ubuntu 18.04 repository.


Hi, I solved the 500 Internal Error adding to the odoo.conf db_name = postgresql and port=5432. Then I restarted odoo service, and it started to work. You can have more information with the following command to see the log in real time: sudo tail -f /var/log/odoo/odoo-server.log


Hi, I followed all the steps correctly everything works except for nginx keeps unencrypting the site and redirecting from https to http. I have tried reinstalling the certificate, it works for a few days then stops


Installing an Odoo instance can be a challenging and time consuming process. As installing an Odoo is always nearly the same except for a few options we've created a script to automatically install Odoo. In this tutorial you will learn how to install the community or enterprise version of Odoo 13. You'll learn how to configure the script and how to execute it.


The first step is to download the installation script from Github and adding the code to a new .sh file on your Ubuntu machine. Let's download this script under your main directory in this example. Open up an Ubuntu terminal and cd into the directory where you'd like to keep the script:


There are some things you can configure/change to your likings at the top of the script. You can choose if you wish to install Wkhtmltopdf or not, which version you'd like, where the location is and most importantly what the master admin password is. Tip: always modify this for every Odoo you install! If you want the enterprise version of Odoo version 13 you should change the line IS_ENTERPRISE to true:


You will see that the script automatically starts updates, downloads required packages, creates the user, downloads the code from Github, ... Eventually, if you've chosen to install the enterprise version, you will need to give in your Github credentials to download the enterprise code (since this is a private repository). Fill in your details and let the script continue:


Since Odoo Enterprise uses code from both and we will separate the code with this script. This will make future upgrades easier and the code is nicely separated. This means that the default V13 code will be under /odoo/odoo-server/ and all the enterprise code will be under /odoo/enterprise/.


In the script you saw there was an option to change the Odoo port (OE_PORT). When you'd change this port number to 8070 in the install script it would be applied to /etc/your-config-file.conf and this would give you the ability to change the default port. To apply these changes you should restart the Odoo service with your configuration file:


Thanks to this installation script installing Odoo has never been so easy and fast. You can use this script to install any Odoo version starting from V8 and can even install multiple Odoo instances on one Ubuntu server. Take some time to read through the script so you understand all the options. It'll be a great asset for all your new installations.


To test Odoo 13, an install with 2GB or Ram is sufficient. For more information on calculating the resources needed based on approximate users and the apps you will use, see: -number-calculation


To create a new database, enter a database name. Then enter an email address, password and any other info. Select the checkbox if you would like to install demo data. Then click Create database button. After set, you should now be redirected to Odoo's admin dashboard where you can install the apps that you need.


Now, go to any PC or Laptop that can access the Server ip-address where you have installed the Docker and its container. After that, open the browser and point it to the server-ip-address along with port number 8069.


1. Put your custom add-on under the addons path.2. Goto settings -> Activate Developer Mode.3. Goto Apps -> Update Apps list4. This gives a wizard.5. Click on Update, After that search for your custom app and install.


Create a system user to run Odoo with the home directory /opt/odoo13. I am here using Odoo 13 as the user name. You can create any name for a user as long as you create a PostgreSQL user with the same name.


Odoo is a web-based OpenSource enterprise resource planning and customer relationship software that can help you to organize and grow your business. Odoo was formerly named openERP and therefore TinyERP. There are many apps available to extend Odoo, for example: billing, accounting, manufacturing, purchasing, warehouse management, and project management.if(typeof ez_ad_units!='undefined')ez_ad_units.push([[728,90],'howtoforge_com-box-3','ezslot_11',106,'0','0']);__ez_fad_position('div-gpt-ad-howtoforge_com-box-3-0');Odoo is created by Fabien Pinckaers/Odoo S.A and written in python. It is available for many operating systems, including Linux, Windows and Mac OS X. I will use Ubuntu 16.04 for the server installation. Odoo has released version 9 of their ERP software at October 1, 2015.if(typeof ez_ad_units!='undefined')ez_ad_units.push([[728,90],'howtoforge_com-medrectangle-3','ezslot_12',121,'0','0']);__ez_fad_position('div-gpt-ad-howtoforge_com-medrectangle-3-0');PrerequisitesUbuntu 16.04 - 64bit2GB memoryWhat we will do in this tutorial:Add the Odoo repositoryConfigure a userInstall and Configure PostgresqlInstall dependencies needed by OdooInstall OdooConfigure OdooStep 1 - Add the Odoo repositoryFirst you will have to add the Odoo apt repository to your repository database file /etc/apt/sources.list. First, add the Odoo key with this apt command:wget -O - apt-key add -Then add the Odoo repository with the echo command:(adsbygoogle=window.adsbygoogle[]).push();echo "deb ./" >> /etc/apt/sources.listNote: >> = add the Odoo repository to the last line in sources.list file.and update the Ubuntu package lists:apt-get updateStep 2 - Configure a Linux user for OdooCreate a new user called odoo with home directory /opt/odoo and the group odoo. You can do it with this command:if(typeof ez_ad_units!='undefined')ez_ad_units.push([[580,400],'howtoforge_com-medrectangle-4','ezslot_10',108,'0','0']);__ez_fad_position('div-gpt-ad-howtoforge_com-medrectangle-4-0');sudo adduser --system --home=/opt/odoo --group odooand create a new directory for Odoo in the /var/lib/ directory.mkdir -p /var/lib/odooStep 3 - Install and Configure PostgreSQLInstall postgreSQL with this apt-get command:sudo apt-get install postgresqland log into the PostgreSQL shell:su - postgresNow create a role for Odoo. This will allow Odoo to access/connect to the PostgreSQL server and to create, delete or modify the database. You will have to enter the password to ensure the security and keep it private.createuser --createdb --username postgres --no-createrole --no-superuser --pwprompt odoo TYPE YOUR PASSWORD HEREFinally type exit to log out from the PostgreSQL shell.Step 4 - Install dependencies neededOdoo needs many python modules, just install all package below to fullfill its prerequisites:sudo apt-get install python-cups python-dateutil python-decorator python-docutils python-feedparser \python-gdata python-geoip python-gevent python-imaging python-jinja2 python-ldap python-libxslt1 \python-lxml python-mako python-mock python-openid python-passlib python-psutil python-psycopg2 \python-pybabel python-pychart python-pydot python-pyparsing python-pypdf python-reportlab python-requests \python-simplejson python-tz python-unicodecsv python-unittest2 python-vatnumber python-vobject \python-werkzeug python-xlwt python-yaml wkhtmltopdfStep 5 - Install OdooNow you can install Odoo with apt:sudo apt-get install odooWhen the installation is complete, Odoo will be running on port 8069. You can check it with the command:netstat -plntu Odoo is installed and running on port 8069. We will run odoo on local IP, because we will use an nginx web server as reverse proxy for odoo.Edit the Odoo configuration file with vim:vim /etc/odoo/openerp-server.confAt the end of the file, paste configuration below:xmlrpc_interface = 127.0.0.1xmlrpc_port = 8069Save and exit.Step 6 - Install and Configure NginxNginx is a lightweight web server and proxy with low memory andCPUu usage. In this step, we will install nginx and configure it as reverse proxy for Odoo.Install nginx with apt:sudo apt-get install nginxGo to the nginx virtual host directory and create a new configuration file:cd /etc/nginx/sites-available/vim odooPaste the configuration below:## Odoo Backend ##upstream odooerp server 127.0.0.1:8069;## https site##server listen 443 default_server; server_name odoo.mysite.co; root /usr/share/nginx/html; index index.html index.htm; # log files access_log /var/log/nginx/odoo.access.log; error_log /var/log/nginx/odoo.error.log; # ssl files ssl on; ssl_ciphers ALL:!ADH:!MD5:!EXPORT:!SSLv2:RC4+RSA:+HIGH:+MEDIUM; ssl_protocols TLSv1 TLSv1.1 TLSv1.2; ssl_prefer_server_ciphers on; ssl_certificate /etc/nginx/ssl/odoo.crt; ssl_certificate_key /etc/nginx/ssl/odoo.key; # proxy buffers proxy_buffers 16 64k; proxy_buffer_size 128k; ## odoo proxypass with https ## location / proxy_pass ; # force timeouts if the backend dies proxy_next_upstream error timeout invalid_header http_500 http_502 http_503 http_504; proxy_redirect off; # set headers proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto https; # cache some static data in memory for 60mins location * /web/static/ proxy_cache_valid 200 60m; proxy_buffering on; expires 864000; proxy_pass ; ## http redirects to https ##server listen 80; server_name odoo.mysite.co; # Strict Transport Security add_header Strict-Transport-Security max-age=2592000; rewrite ^/.*$ permanent;Save and exit.I will run odoo under nginx with the domain name odoo.mysite.co and use a secure https connection.Next, we need to create a new ssl certificate file for odoo with openssl.Create the SSL directory:mkdir -p /etc/nginx/sslcd /etc/nginx/sslGenerate a new self-signed certificate file with the openssl command below:openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/nginx/ssl/odoo.key -out /etc/nginx/ssl/odoo.crtChange the permission of the certificate file:chmod 600 odoo.keyEnable new odoo virtual host and test the nginx configuration:ln -s /etc/nginx/sites/available/odoo /etc/nginx/sites-enabled/odoonginx -tMake sure there is no error on nginx configuration and then restart nginx web server:systemctl restart nginxStep 7 - Configure OdooOdoo and nginx are installed, open a web browser and type in the odoo URL, in my case: will be prompted to create a new database and to configure the email address and password for the admin account.Enter the details for your installation and click on 'Create database'.wait a minute for the odoo installation to finish.After odoo created the database, we can login to the odoo admin dashboard. But for the security reason, we need to setup a master password for the odoo database manager.Click on 'Manage Databases'Clik on 'Set Master Password'.Type your password and click 'Continue'.Master password has been setup, and now back to the odoo url ' '.Type your email and password and click 'Login'.Odoo admin dashboard.Odoo home page after install new app 'Forum'.Odoo 9 with nginx has been successfully installed on ubuntu 16.04.ConclusionOdoo is an open source application that helps you to manage your business. Odoo / OpenERP is easy to install and configure and supports multiple operating systems. In Odoo, there are many applications available such as billing, accounting, manufacturing, purchasing, warehouse management, and project management. These apps can help you to manage and grow your business.About Muhammad ArulMuhammad Arul is a freelance system administrator and technical writer. He is working with Linux Environments for more than 5 years, an Open Source enthusiast and highly motivated on Linux installation and troubleshooting. Mostly working with RedHat/CentOS Linux and Ubuntu/Debian, Nginx and Apache web server, Proxmox, Zimbra Administration, and Website Optimization. Currently learning about OpenStack and Container Technology. view as pdf printShare this page:Suggested articles21 Comment(s)Add commentName *Email *tinymce.init( bold italic link",);CommentsBy: DocB Reply Odoo/openERP is technically rotten and has no open License. Upgrade is difficult to impossible. Search for sorryopenerp on the web....By: JOduMonT Reply I'll not try to saying DocB is wrong. For sure migrating from 6 to 7 and 7 to 8 is a huge headache. I know some cie still using 6. About the SorryOpenERP program they discuss about it into their own forum : -1/question/worried-about-the-sorryopenerp-campaign-23304 and the GitHub is now dead : By: Rahul Reply Man this is probably the most complicated way of installing odoo!!!!!By: CarlosRamos Reply Congratulations on the Great Tutorial !!!Simply the best tutorial odoo installation in ubuntu, fully explained step by step, leaving no loose pieces of difficult understanding. I have a doubt:You can install odoo 9 in the same VPS / Cloud account (Drop / Instance) along with a small site wordpress? Type the Odoo inside a folder!www.sitewordpress.com/odoo or www.sitewordpress.com:8069Example: Instead of two VPSVPS1 2GB => Wordpress VPS2 2GB => OdooA single VPSVPS 3 or 4 GB> with Wordpres and Odoo togetherThanks for the great tutorial !!By: Vladimir Reply ln -s /etc/nginx/sites/available/odoo /etc/nginx/sites-enabled/odooyou needln -s /etc/nginx/sites-available/odoo /etc/nginx/sites-enabled/odooinsteadBy: Alawi Reply You're correct Vladimir, this typo will prevent the new odoo site from being enabled and will show ngix default page.Thanks for pointing out this error.By: Alex Reply Great tutorial !Following these steps I installed Odoo10 on Ubuntu 16.10.Replaced Step1 with : echo "deb ./" >> /etc/apt/sources.listAnd added : echo "deb vivid main universe" >> /etc/apt/sources.list" to be able to install "python-pybabel".Many thanks By: Anthony Reply When I enter su - postgres I get asked for a password. I've used my login password, 'admin' and 'password' but nothing works. Is there a default password I should be using?By: till Reply Ensure that you run the "su postgres" command as root, not as admin user. postgres user has no password by default.By: Ajay Tee Reply How do I ensure or get to run su - postgres as root?By: Ajay Tee Reply How do I ensure or get to run su - postgres as root? Turns out, all I had to do was add 'sudo' at the start of the command. I.E.sudo su - postgres Then it all worked fine..!By: Ajay Tee Reply How do I ensure or get to run su - postgres as root? Turns out, all I had to do was add 'sudo' at the start of the command. I.E.sudo su - postgres Then it all worked fine..!By: Ajay Tee Reply Hi, I'm at the point where I need to enter su - postgres in the terminal window and it's asking me for a password.I've used my login password, 'admin' and 'password' but none work.Can you please provide me the password?By: Agung Reply Thanks for your great tutorial, its very helpfull. Btw, how to restart the odoo, and how to add a command to add the path directory of addons of odoo?By: Paul Reply I have folllowed all the steps..but when i enter the domain name, i get problem loading page error. Can anyone help me troubleshoot this? Thank youBy: Mike Reply The simplest way is to provide your hosts file (/etc/hosts) with desired hostname e.g.# sudo su# echo 127.0.0.1 mydomain.co >> /etc/hostsSomething has to bind mydomain.co with your IP address. Without it, your browser will request ODOO server's IP from your default DNS server, which is not particulary good when no one knows your hostname. You may also want to use mDNS for resolving your hostname in small-medium network. Nginx example is focused on reverse proxying which allows you to secure the connection betweend clients (including workers) and your ERP server.By: Fernando Reply Hi.I followed this instructions. But, in this step 2ff7e9595c


0 views0 comments

Recent Posts

See All

Apklime GTA 5

GTA 5: um guia para baixar, instalar e jogar no PC Grand Theft Auto V, ou GTA 5 para abreviar, é um dos videogames mais populares e...

Comments


bottom of page