หน้า 1 จากทั้งหมด 1

สอน วิธีติดตั้ง OpenERP 7.0 บน OpenSuse

โพสต์แล้ว: พุธ 19 มิ.ย. 2013 4:34 pm
โดย openerpthailand
สอน วิธีติดตั้ง OpenERP 7.0 บน OpenSuse

Install OpenSuse 12.2
Make a fresh installation for opensuse
Make this installation at your taste.
Make a distribution upgrade to your newly installed distro. Recomended but not necessary
~> sudo zypper refresh
~> sudo zypper dist-upgrade
Create a User for Openerp
Creating a Openerp Group
~> sudo /usr/sbin/groupadd openerp
Creating user with openerp as main group
~> sudo /usr/sbin/useradd -m -g openerp openerp

Login as Openerp User
~> sudo su openerp

Change directory to openerp home directory
~> cd

Installing & Setting PostgreSQL
Installing PostgreSQL
~> sudo zypper -n in postgresql-server

Enabling PostgreSQL as an active service on next restart.
Applies only to Suse Linux Enterprise Server 11 SP2
~> sudo insserv /etc/init.d/postgresql

~> sudo systemctl enable postgresql.service

Starting PostgreSQL for right-now-use
Applies only to Suse Linux Enterprise Server 11 SP2
~> sudo /etc/init.d/postgresql start

~> sudo systemctl start postgresql.service

Creating the PostgreSQL's openerp user
For openSUSE 12.2
~> sudo su postgres
~> createuser -P openerp
Enter password for new role:
Enter it again:
Shall the new role be a superuser? (y/n) n
Shall the new role be allowed to create databases? (y/n) y
Shall the new role be allowed to create more new roles? (y/n) n

For openSUSE 12.3
~> sudo su postgres
~> createuser --interactive openerp -P
Enter password for new role:
Enter it again:
Shall the new role be a superuser? (y/n) n
Shall the new role be allowed to create databases? (y/n) y
Shall the new role be allowed to create more new roles? (y/n) n

This another command can be used (NEEDS REVIEW IT'S NOT WORKING)
~> createuser -P openerp --no-superuser --createdb

--no-createrole

A shorcut to this same command can be used
~> createuser -P openerp -S -d -R

Modifying PostgreSQL's pg_hba.conf file:
Applies only to Suse Linux Enterprise Server 11 SP2
DO NOT PROCEED WITH THIS STEP, SKIP IT.

~> sudo vim /var/lib/pgsql/data/pg_hba.conf

first two green lines are related to your newly created / to be created dbusers.
last two green lines should look like mine,

Inline image 1
(Obsoletizado)
Subtitute the following line:
local all all peer

with this one:
local all all md5

Restart PostgreSQL to make the changes take effect:
~>sudo systemctl restart postgresql.service

Download openerp sources
Get bazaar
For just the CLI program:

Applies only to Suse Linux Enterprise Server 11 SP2
~> sudo zypper ar -f http://download.opensuse.org/repositori ... s:scm.repo
~> sudo zypper refresh

~> sudo zypper in bzr


In order to get the GUI (bzr-explorer):
Applies only to Suse Linux Enterprise Server 11 SP2
~> sudo zypper addrepo -f http://download.opensuse.org/repositori ... ython.repo

Add the following repo:
For openSUSE 12.2
~> sudo zypper addrepo -f http://download.opensuse.org/repositori ... s:scm.repo

For openSUSE 12.3
~> sudo zypper addrepo -f
http://download.opensuse.org/repositori ... s:scm.repo

~> sudo zypper refresh
~> sudo zypper in bzr-explorer
Get Openerp Branches
At Openerp User's home directory create the following directories
~> mkdir -p instancias/7.0/

Get into the newly created directory
~> cd instancias/7.0/

Get the sources for the server
~> bzr branch lp:openobject-server/7.0 server

Get the sources for the openerp-addons
~> bzr branch lp:openobject-addons/7.0 addons

Get the sources for the openerp-web server
~> bzr branch lp:openerp-web/7.0 web

Install Dependencies

~> sudo zypper -n in python-psycopg2 \
python-lxml python-pytz python-imaging \
python-PyYAML python-reportlab \
python-Mako python-Werkzeug \
python-psutil python-Babel \
python-dateutil python-gdata \
python-docutils python-python-openid \
python-simplejson python-feedparser \
python-ldap python-pydot\


We will add a new repository in order to be able to install PyChart library
For openSUSE 12.2
~> sudo zypper addrepo -f http://download.opensuse.org/repositori ... ython.repo

For openSUSE 12.3
~> sudo zypper addrepo -f
http://download.opensuse.org/repositori ... ython.repo

After hitting enter in the command line, you will get an output like this:

Adding repository 'Python and Python Modules (o[done]
Repository 'Python and Python Modules (openSUSE_12.2)' successfully added
Enabled: Yes
Autorefresh: Yes
GPG check: Yes
URI: http://download.opensuse.org/repositori ... SUSE_12.2/

~> sudo zypper refresh

After hitting enter when refreshing your repositories you will get
an output like this, asking for trust, you could answer 'a', for always trusting:

Retrieving repository 'Python and Python Modules ([\]

New repository or package signing key received:
Key ID: 27163A4EEDF0D733
Key Name: devel:languages:python OBS Project <devel:languages:[email protected]>
Key Fingerprint: 172CCD6B0CF49B7388F1C61127163A4EEDF0D733
Key Created: Wed 10 Oct 2012 12:07:25 PM VET
Key Expires: Fri 19 Dec 2014 12:07:25 PM VET
Repository: Python and Python Modules (openSUSE_12.2)
Do you want to reject the key, trust temporarily, or trust always? [r/t/a/?] (r): a

Now we can be able to install PyChart
~> sudo zypper -n in python-PyChart

Add this repo in order to get python libraries not available anywhere else:
~> sudo zypper addrepo -f http://download.opensuse.org/repositori ... invis.repo

~> sudo zypper ref

~> sudo zypper -n in python-vatnumber \
python-vobject python-webdav \
libxslt-python python-xlwt \
python-ZSI python-unittest2 \
python-mock python-Jinja2 python-gtk

If you were to need WebKit, you are to installing it manually:

wget http://wkhtmltopdf.googlecode.com/files ... 64.tar.bz2
tar -xjf wkhtmltopdf-0.9.9-static-amd64.tar.bz2
cp wkhtmltopdf-amd64 /usr/bin/wkhtmltopdf

wget http://wkhtmltopdf.googlecode.com/files ... 386.tar.bz

tar -xjf wkhtmltopdf-0.9.9-static-i386.tar.bz

cp wkhtmltopdf-i386 /usr/bin/wkhtmltopdf





Running Openerp
At this moment you should be trunk folder, but if you forget it, make this, to be sure

~> sudo su openerp
~> cd
~> cd instancias/trunk/server

~> ./openerp-server -r openerp -w openerp --addons-path=../addons/,../web/addons/ --load=web

Go to your preferred browser and write in the address box,

http://localhost:8069

Create a new database, for better results

Load Demonstration data:
And begin having fun!!!

ที่มาจาก: https://www.evernote.com

ปล. ผมยังไม่ได้ลองแนะนครับ บทความนี้เป็น ของคุณ hbtoarocha ที่เว็บ evernote.com
ท่านใดได้ลองใช้ OpenSuse แล้วบ้างแชร์ กันหน่อยนะครับ