Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- This installation instrucion describes how to install Tryton Server and Client from scratch for development purposes.
- #. Create virtualenv with virtualenvwrapper::
- mkvirtualenv -p /usr/bin/python2.7 trytond
- #. Install Tryton Server::
- pip install trytond==4.0.4
- #. Install optional dependencies::
- pip install psycopg2==2.6.2
- #. Create PostgreSQL database::
- sudo -u postgres psql << EOF
- CREATE USER tryton WITH SUPERUSER UNENCRYPTED PASSWORD 'tryton';
- CREATE DATABASE tryton OWNER tryton TEMPLATE=template0 ENCODING='utf-8' LC_COLLATE='en_US.UTF-8' LC_CTYPE='en_US.UTF-8';
- EOF
- #. Create configurationo file for Tryton Server::
- cat << EOF > ./tryton.conf
- [web]
- listen=127.0.0.1:8000
- [database]
- # uri = database://username:password@host:port/
- uri=postgresql://tryton:tryton@127.0.0.1:5432/tryton
- [jsonrpc]
- # Settings for the JSON-RPC network interface
- listen=127.0.0.1:8000
- data=/tryton/sao
- EOF
- #. Initialize database and update all installed modules::
- # TODO(dmu) LOW: Why should I have `-d tryton` option although database name is already configured in ./tryton.conf ?
- trytond-admin -c ./tryton.conf -v -d tryton --all
- # Type admin password when prompted
- # TODO(dmu) LOW: Use TRYTONPASSFILE to avoid typing password?
- #. Run server in development mode::
- trytond -c ./tryton.conf -v -d tryton --dev
- #. Create virtualenv with virtualenvwrapper::
- mkvirtualenv -p /usr/bin/python2.7 tryton-client
- #. Install Tryton Client::
- pip install tryton==4.0.4
- #. Fix pygtk installation for virtualenv::
- pushd $(dirname `which python`)/../lib/python2.7/site-packages
- ln -s /usr/lib/python2.7/dist-packages/pygtk.py
- ln -s /usr/lib/python2.7/dist-packages/pygtk.pth
- ln -s /usr/lib/python2.7/dist-packages/gtk-2.0/
- ln -s /usr/lib/python2.7/dist-packages/gobject/
- ln -s /usr/lib/python2.7/dist-packages/glib/
- ln -s /usr/lib/python2.7/dist-packages/cairo/
- popd
- #. Run Tryton Client::
- tryton
- # Host: 127.0.0.1:8000
- # Database: tryton
- # User name: admin
- # Password: admin
- #. [Optional] Install simple module for testing installation::
- workon trytond
- pip install trytond_party
- trytond-admin -c ./tryton.conf -v -d tryton --all
- # Restart Tryton Server:
- trytond -c ./tryton.conf -v -d tryton --dev
- # Restart Tryton Client
- tryton
- # 1. In Tryton Client open by double click: Administration -> Modules -> Modules
- # 2. Click at "Mark for installation" for "party" module
- # 3. In tool bar click "Launch action" -> "Perform Pending Installation/Upgrade"
- # 4. Click "Start Upgrade"
- # 5. Wait until upgrad finishes and click "OK"
- # 6. Cancel all wizards
- # 7. Find "Part" item in the left bar above "Administration" item
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement