SHA256
1
0
forked from pool/trytond

Accepting request 526511 from Application:ERP:Tryton:Factory

bnc1054032 bugfix release for GNU Health

OBS-URL: https://build.opensuse.org/request/show/526511
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/trytond?expand=0&rev=12
This commit is contained in:
Dominique Leuenberger 2017-09-17 20:38:53 +00:00 committed by Git OBS Bridge
parent 592e25799e
commit 4d6b830e14
2 changed files with 39 additions and 58 deletions

View File

@ -7,13 +7,14 @@ How to get it running (Without reading the instructions)
You have already installed the package trytond and found this documentation. Good.
1) Log in as root and start the database
#su
#systemctl start postgresql
> su
> systemctl start postgresql
2) Change postgres parameters. You need to log in as user postgres, in order to avoid authorisation issues. Assuming we have nano as editor:
<you are logged in as user 'root'>
#su postgres
#nano /var/lib/pgsql/data/pg_hba.conf
> su postgres
> nano /var/lib/pgsql/data/pg_hba.conf
Change the line
local all all md5
@ -24,29 +25,24 @@ Save your input.
Save your input.
3) Create a role for 'tryton' in the database (sill as user postgres)
#psql -c "CREATE USER tryton WITH CREATEDB;"
> psql -c "CREATE USER tryton WITH CREATEDB;"
4) exit as user postgres and restart postgres
#exit
#systemctl restart postgresql
> exit
> systemctl restart postgresql
5) Now lets look at /etc/tryton/trytond.conf. Uncomment the line with super_pwd (it is recommended that you set your own password here!
#nano /etc/tryton/trytond.conf
uncomment super_pwd
5) start trytond:
> systemctl start trytond
6) start trytond:
#systemctl start trytond
6) Install the tryton client:
> zypper in tryton
7) Install the tryton client:
#zypper in tryton
8) Open the tryton client:
#tryton
7) Open the tryton client:
>tryton
go to 'manage profiles' -> add -> name it 'localhost' -> Host: localhost
-> you should now see a selection of available databases
Note: Fron Tryton Release 4.2 onwards it is not possible anymore to create databases
from the Frontend. You need to do this manually (see below)
Note: From Tryton Release 4.2 onwards it is not possible anymore to create databases from the Frontend. You need to do this manually (see below)
DONE.
@ -70,7 +66,7 @@ We can distinguish two scenarios, to which the following description will refere
* In both cases, make sure PostgreSQL is running:
# systemctl status postgresql
> systemctl status postgresql
Note: If PostgreSQL runs on another machine than the Tryton server, make sure
you have setup database password authentication. Please refer to the
@ -96,17 +92,10 @@ We can distinguish two scenarios, to which the following description will refere
The Tryton Server runs as user 'tryton', so we need a role in postgres for this.
Case 1)
For manual database creation it is sufficient to create the user as follows:
For manual database creation (standard as from Tryton 4.2 onwards) it is sufficient to create the user as follows:
su postgres
psql -c "CREATE USER tryton WITH CREATEDB;"
Case 2)
In case 2 the user needs additionally an encrypted password to log into the DB:
su postgres
psql -c "ALTER ROLE tryton ENCRYPTED PASSWORD 'tryton_password' ;"
> su postgres
> psql -c "CREATE USER tryton WITH CREATEDB;"
Note: If you want to run the database as another user than 'tryton', you
need to replace 'tryton' above with the user you want to use instead.
@ -121,17 +110,7 @@ Preparing the Tryton server
It contains all settings for a locally running database and manual database
configuration.
Adjust /etc/tryton/trytond.conf to reflect the setup of your system by using
the database user and password from step 1 for the database URI.
For case 1 you do not need to do anything additional.
For case 2 (creation of database from Tryton frontend) you need to set the
Super password in the configuration file.
See section super_pwd in
http://trytond.readthedocs.org/en/latest/topics/configuration.html
As a result you will get an encypted password in the form
super_pwd = grlvvq5T4r5BQ
which is entered in /etc/tryton/trytond.conf
Adjust /etc/tryton/trytond.conf to reflect any different the setup of your system.
* If the Tryton server shall listen on some external interface (i.e. shall be
available for clients connecting from other machines), change the jsonrpc
@ -145,7 +124,7 @@ Preparing the Tryton server
* Restarting trytond:
# systemctl restart trytond
> systemctl restart trytond
Note: The fingerprint of connected servers is stored in the clients
known_hosts file. When a server is changed for its SSL usage, the client
@ -159,11 +138,11 @@ Now you are ready to connect with a client, e.g. tryton-client.
Creating the database for Tryton
--------------------------------
For case 1, manual creation of the database, the folowing steps are to be performed:
For manual creation of the database, the folowing steps are to be performed:
* Creating the database:
# su - postgres -c "createdb mydb --encoding='UTF-8' --owner=tryton"
> su - postgres -c "createdb mydb --encoding='UTF-8' --owner=tryton"
Note: The owner of the database should be the same user, as under which the
tryton server runs (default:tryton) Enter a name for the database
@ -173,17 +152,14 @@ For case 1, manual creation of the database, the folowing steps are to be perfor
Log in as user tryton:
# sudo su tryton -s /bin/bash
# /usr/bin/trytond-admin -c /etc/tryton/trytond.conf --all -d mydb
> sudo su tryton -s /bin/bash
> /usr/bin/trytond-admin -c /etc/tryton/trytond.conf --all -d mydb
Note: Use the database name you chose in the previous step (here as default:
mydb). You will be asked for the admin password for this database.
mydb). You will be asked for the admin password for this database. For the first time, log in to the newly initialized database with user admin and password as set during initialization.
As result you will have a bare Tryton database with the base modules installed.
For case 2, you need to create an encrypted password and enter it in the
configuration file as super_pwd
See: http://doc.tryton.org/4.2/trytond/doc/topics/configuration.html
@ -191,7 +167,7 @@ Installation of the Webfrontend for tryton (sao) from package
-------------------------------------------------------------
For most openSUSE Flavours tryton-sao is packed. You can install it with
zypper install tryton-sao
> zypper install tryton-sao
You need to edit /etc/tryton/trytond.conf. Installation of tryton-sao follows the
standards for nodejs-installations, so the path is within the node-modules:
@ -209,15 +185,15 @@ sao bases on nodejs, and it comes as separate package. Download and extract
tryton-sao into a directory, say /srv/tryton-sao
Make sure you have nodejs and git installed:
zypper install nodejs git
> zypper install nodejs git
Now change into to installation directory and install sao:
cd /srv/tryton-sao/package
npm install
> cd /srv/tryton-sao/package
> npm install
Now you need to run grunt. make sure it is run from the locally installed version:
cd /srv/tryton-sao/package
node_modules/grunt-cli/bin/grunt
> cd /srv/tryton-sao/package
> node_modules/grunt-cli/bin/grunt
Last but not least, edit /etc/tryton/trytond.conf
In the section [web], set the path:
@ -233,7 +209,7 @@ Upgrade
version string) you have to update your database(s).
After the categorically recommended backup do:
# /usr/bin/trytond-admin -c /etc/tryton/trytond.conf --all -d mydb
> /usr/bin/trytond-admin -c /etc/tryton/trytond.conf --all -d mydb
Remember to replace tryton with the name of your database.
@ -275,4 +251,4 @@ Now, you're finished with the system setup. Please be aware of the following thi
* Only the same major version of Tryton client and Tryton server can connect.
-- Axel Braun <axel.braun@gmx.de> TUE Jun 20 15:40:04 UTC 2017
-- Axel Braun <axel.braun@gmx.de> THU Sep 14 19:24:07 UTC 2017

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Thu Sep 14 19:24:19 UTC 2017 - axel.braun@gmx.de
- Documentation updated
-------------------------------------------------------------------
Thu Aug 10 20:04:47 UTC 2017 - axel.braun@gmx.de