24/02/2022

Hướng dẫn cài đặt Odoo 13 trên Ubuntu 18.04 LTS

Cùng tìm hiểu về Odoo – Phần mềm ERP quản trị doanh nghiệp phổ biến nhất hiện nay

1. Odoo là gì?

Odoo là một phần mềm quản trị doanh nghiệp mã nguồn mở sử dụng ngôn ngữ lập trình Python, bao gồm các module Bán hàng, Chăm sóc khách hàng, Quản trị dự án, Quản trị kho, Quản trị sản xuất, Quản lý tài chính và Quản trị nguồn nhân lực,…Odoo/OpenERP cung cấp đa dạng các lựa chọn với hơn 1000 mô-đun. Odoo/OpenERP được tích hợp công nghệ điện toán đám mây, cực kỳ phù hợp với các doanh nghiệp vừa và nhỏ trong mọi ngành nghề, lĩnh vực. Hiện tại, Odoo vẫn luôn là lựa chọn hàng đầu cho các doanh nghiệp, không chỉ ở Việt Nam, trên thế giới số lượng người quan tâm tới Odoo cũng vượt trội.

2. Triển khai Odoo trên Cloud 365 của Nhân Hòa

Nhân Hòa hướng dẫn bạn cài đặt Odoo 13 phiên bản Community trên Ubuntu 18.04 LTS theo cách đơn giản và hiệu quả nhất.

+ Bật universe repository để cài python3-pip bằng cách mở file /etc/apt/sources.list thêm 3 dòng sau vào cuối file

<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">deb <a class="external-link" href="http://archive.ubuntu.com/ubuntu" rel="nofollow">http://archive.ubuntu.com/ubuntu</a> bionic main universe</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">deb <a class="external-link" href="http://archive.ubuntu.com/ubuntu" rel="nofollow">http://archive.ubuntu.com/ubuntu</a> bionic-security main universe</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">deb <a class="external-link" href="http://archive.ubuntu.com/ubuntu" rel="nofollow">http://archive.ubuntu.com/ubuntu</a> bionic-updates main universe</span>

+ Chạy lệnh sau để cài đặt Odoo

<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">#apt-get update && apt-get upgrade</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">#apt-get install python3-pip</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">#pip3 install xlwt</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">#pip3 install num2words</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">#wget -O - <span class="nolink">https://nightly.odoo.com/odoo.key</span> | apt-key add -</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">#echo "deb http://nightly.odoo.com/13.0/nightly/deb/ ./" >> /etc/apt/sources.list.d/odoo.list</span>
<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">#apt-get update && apt-get install odoo</span>

Sau khi quá trình cài đặt hoàn tất bạn truy cập Odoo bằng IP vps /server ở cổng 8069, nếu cần sử dụng port 80 hoặc 443 (SSL) bạn có thể cấu hình nghinx proxy ở file: /etc/nginx/sites-enabled/default

Ngoài ra bạn có thể forward port 80 → 8069 bằng IPTABLES

<span style="font-family: 'times new roman', times, serif; font-size: 14pt;">iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8069</span>

Chúc các bạn thành công!