於 CentOS 7.0 安裝 odoo 8.0

You are here:
< All Topics

記得最後有遇到 Aeroo Report 卡關

open-vm-tools
http://partnerweb.vmware.com/GOSIG/CentOS_7.html

su
yum -y update
yum -y install open-vm-tools
要下載 WKHTMLTOPDF
yum -y install wkhtmltox-0.12.2.1_linux-centos7-amd64.rpm

How to Setup OpenERP (Odoo) on CentOS 7

Install Odoo 8 (OpenERP) in CentOS & Red Hat Enterprise Linux

Warning
with RHEL-based distributions (RHEL, CenOS, Scientific Linux), EPEL must be added to the distribution’s repositories for all of Odoo’s dependencies to be available. For CenOS:

$ sudo yum install -y epel-release
For other RHEL-based distribution, see the EPEL documentation.
$ sudo yum install -y postgresql-server
$ sudo postgresql-setup initdb
$ sudo systemctl enable postgresql
$ sudo systemctl start postgresql
$ sudo yum-config-manager –add-repo=https://nightly.odoo.com/8.0/nightly/rpm/odoo.repo
$ sudo yum install -y odoo
$ sudo systemctl enable odoo
$ sudo systemctl start odoo
Danger
to print PDF reports, you must install wkhtmltopdf yourself: the version of wkhtmltopdf available in Fedora/CentOS repositories does not support headers and footers so it can not be installed automatically. Use the version available on the wkhtmltopdf download page.
Configuration

The configuration file can be found at /etc/odoo/openerp-server.conf

When the configuration file is edited, Odoo must be restarted via SystemD:

$ sudo systemctl restart odoo
odoo location
/usr/lib/python2.7/site-packages/openerp/addons

odoo config file
/etc/odoo/openerp-server.conf
logfile = /var/log/odoo/odoo-server.log

2015-05-11 07:31:29,757 7579 INFO ? openerp.http: HTTP Configuring static files
2015-05-11 07:31:29,767 7579 INFO GAPL openerp.modules.loading: loading 1 modules…
2015-05-11 07:31:29,782 7579 INFO GAPL openerp.modules.loading: 1 modules loaded in 0.01s, 0 queries
2015-05-11 07:31:29,783 7579 WARNING GAPL openerp.modules.module: module process: module not found
2015-05-11 07:31:29,783 7579 WARNING GAPL openerp.modules.graph: module process: not installable, skipped
2015-05-11 07:31:29,785 7579 WARNING GAPL openerp.modules.module: module magento_bridge: module not found
2015-05-11 07:31:29,785 7579 WARNING GAPL openerp.modules.graph: module magento_bridge: not installable, skipped
2015-05-11 07:31:29,789 7579 WARNING GAPL openerp.modules.module: module base_status: module not found
2015-05-11 07:31:29,789 7579 WARNING GAPL openerp.modules.graph: module base_status: not installable, skipped
2015-05-11 07:31:29,789 7579 WARNING GAPL openerp.modules.module: module report_aeroo_ooo: module not found
2015-05-11 07:31:29,790 7579 WARNING GAPL openerp.modules.graph: module report_aeroo_ooo: not installable, skipped
2015-05-11 07:31:29,793 7579 WARNING GAPL openerp.modules.module: module report_aeroo: module not found
2015-05-11 07:31:29,793 7579 WARNING GAPL openerp.modules.graph: module report_aeroo: not installable, skipped
2015-05-11 07:31:29,803 7579 WARNING GAPL openerp.modules.module: module magento_openerp_stock: module not found
2015-05-11 07:31:29,803 7579 WARNING GAPL openerp.modules.graph: module magento_openerp_stock: not installable, skipped
apt-get -y install xfonts-75dpi xfonts-base wkhtmltox
dpkg -i wkhtmltox-0.12.2.1_linux-precise-i386.deb
cd /usr/share/fonts/
wget http://okay.googlecode.com/files/DejaVuSans-Oblique.ttf http://okay.googlecode.com/files/DejaVuSans-BoldOblique.ttf http://okay.googlecode.com/files/DejaVuSans-Bold.ttf http://okay.googlecode.com/files/DejaVuSans.ttf
fc-cache -fv

https://www.odoo.com/forum/help-1/question/how-to-use-custom-fonts-in-rml-reports-71030
參照上方的方式載入字型

接下來修改 rml report 中的 stylesheet
在用到的 paraStyle 中加入 fontName=”DejaVuSansYuanTi-Regular”
*******
如果要安裝report_xls or Export Current View 模組需要安裝相關的模組
easy_install xlwt
Aeroo report on CentOS 7.0

easy_install genshi lxml uno pyoo
yum install cairo-devel

cd /opt/odoo_apps
git clone https://github.com/aeroo/aeroolib.git
cd /opt/odoo_apps/aeroolib
python setup.py install
#9 sudo vi /etc/init.d/office

#!/bin/sh

/usr/bin/soffice –nologo –nofirststartwizard –headless –norestore –invisible “–accept=socket,host=localhost,port=8100,tcpNoDelay=1;urp;” &
yum install libreofficelibreoffice-headless libreoffice-pyuno

easy_install jsonrpc2 daemonize configparser
cd /opt/odoo_apps
git clone https://github.com/aeroo/aeroo_docs.git
cd aeroo_docs/
python /opt/odoo_apps/aeroo_docs/aeroo-docs start -c /etc/aeroo-docs.conf
ln -s ‘/opt/odoo_apps/aeroo_docs/aeroo-docs’ ‘/etc/systemd/system/multi-user.target.wants/aeroo-docs’
echo /opt/openoffice4/program |tee /usr/lib/python2.7/site-packages/unohelper.pth
python /opt/odoo_apps/aeroo_docs/aeroo-docs start -c /etc/aeroo-docs.conf

卡住了
sudo ldconfig -v /usr/lib/openoffice/program

systemctl start nginx.service
systemctl enable nginx.service
git clone https://github.com/aeroo/aeroolib.git
git clone https://github.com/aeroo/aeroolib.git

pyoo??
python-relatorio: A templating library able to output odt and pdf files
python-genshi: Toolkit for stream-based generation of output for the web
PyYAML: YAML parser and emitter for Python
pycairo: Python bindings for the cairo library
pycha (install through python self installer # easy_install pycha, not included in base Centos distribution)
python-openoffice: Python libraries for interacting with OpenOffice.org
openoffice.org-pyuno : Python bindings for OpenOffice.org
OpenOffice.org v.2.3.x or above.

Previous 於 CentOS 7.0 安裝 odoo 10.0(遠端資料庫)- 安裝篇
Next 於 CentOS 7.0 安裝 odoo 9.0
Table of Contents