美文网首页
ubuntu-odoo-安装

ubuntu-odoo-安装

作者: 豪威Howie | 来源:发表于2021-05-23 10:06 被阅读0次

os

ubuntu 20.04lst
with python3.8.5

postgresql13 install

# Create the file repository configuration:
sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'

# Import the repository signing key:
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -

# Update the package lists:
sudo apt-get update

# Install the latest version of PostgreSQL.
# If you want a specific version, use 'postgresql-12' or similar instead of 'postgresql':
sudo apt-get -y install postgresql-13
sudo systemctl enable postgresql
sudo systemctl start postgresql
sudo systemctl status postgresql

# add for psy
sudo apt-get install python3-psycopg2
sudo apt-get install libpq-dev
sudo apt install build-essential libxslt-dev libzip-dev libldap2-dev libsasl2-dev libssl-dev python3-dev  libxml2-dev  libxslt-dev
wget https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6-1/wkhtmltox_0.12.6-1.focal_amd64.deb
sudo dpkg -i wkhtmltox_0.12.6-1.focal_amd64.deb
sudo cp /usr/local/bin/wkhtmltoimage /usr/bin/wkhtmltoimage
sudo cp /usr/local/bin/wkhtmltopdf /usr/bin/wkhtmltopdf

配置文件

添加为服务

# sudo vi /etc/systemd/system/odoozp.service
[Unit]
Description=Odoozp
Requires=postgresql.service
After=network.target postgresql.service
[Service]
Type=simple
SyslogIdentifier=odoo14
PermissionsStartOnly=true
User=odoo
Group=odoo
ExecStart=/opt/odoo/venv/bin/python /opt/odoo/odoo-bin -c /opt/odoo/zpodoo.conf
StandardOutput=journal+console
[Install]
WantedBy=multi-user.target
sudo systemctl daemon-reload
 sudo systemctl start odoozp
 sudo systemctl restart odoozp
 sudo systemctl status odoozp
 sudo systemctl enable odoozp

相关文章

网友评论

      本文标题:ubuntu-odoo-安装

      本文链接:https://www.haomeiwen.com/subject/gopejltx.html