odoo學習-1

10132714發表於2024-07-01

1. 虛擬環境的使用

https://blog.csdn.net/u013379032/article/details/131556231

2. linux安裝postgresql

到官網,然後選擇自己的伺服器配置,他會給你一段程式碼,執行即可

# Install the repository RPM:
sudo dnf install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-8-x86_64/pgdg-redhat-repo-latest.noarch.rpm

# Disable the built-in PostgreSQL module:
sudo dnf -qy module disable postgresql

# Install PostgreSQL:
sudo dnf install -y postgresql12-server

# Optionally initialize the database and enable automatic start:
sudo /usr/pgsql-12/bin/postgresql-12-setup initdb
sudo systemctl enable postgresql-12
sudo systemctl start postgresql-12

3. odoo配置

在odoo/conf中新建openserver.conf檔案,並寫入:
[options]
db_name = odoo12_test
db_host = 127.0.0.1
db_port = 5432
db_user = odoo12
db_password = odoo12
addons_path = /home/odoo12/odoo/addons