annotate INSTALL @ 979:1d558dfb32ca

server: pages redirection: when using a redirection dict, a new "page" key can be used to redirect to a named page. "args" can be added to specified named arguments to set (will be put in request.args, in addition to existing ones). The redirection is done dynamically, during the request workflow.
author Goffi <goffi@goffi.org>
date Sun, 12 Nov 2017 12:56:46 +0100
parents 1028a9c366d3
children 0d517b596568
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
777
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
1 Libervia's installation is currently a bit tricky. Please note that this file instructs
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
2 a minimal configuration of Libervia. For a complete procedure including the installation
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
3 and configuration of your XMPP server and enabling the blog and directory features,
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
4 please consult this page on the Salut à Toi wiki:
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
5
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
6 http://wiki.goffi.org/w/index.php?title=Libervia/en
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
7
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
8 == Prerequesites ==
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
9
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
10 These steps are detailed on the Salut à Toi wiki:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
11
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
12 * install and configure Salut à Toi
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
13 * install and configure a local XMPP server (we recommend using Prosody)
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
14 * install sat_pubsub
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
15
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
16 == Dependencies ==
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
17
789
1028a9c366d3 update INSTALL for Jinja2 dependency
souliane <souliane@mailoo.org>
parents: 777
diff changeset
18 * you need to install the txJSON-RPC and Jinja2 dependencies (as root):
1028a9c366d3 update INSTALL for Jinja2 dependency
souliane <souliane@mailoo.org>
parents: 777
diff changeset
19 pip install txJSON-RPC jinja2
777
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
20 * install python2-gobject2 from your distribution repositories. For example:
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
21 apt-get install python-gobject2
731
47c21905e002 fixes the INSTALL since http://pyj.be has been down for a while (Oliver)
souliane <souliane@mailoo.org>
parents: 496
diff changeset
22 * install pyjamas. We use the version which used to be on http://pyj.be, not the fork
47c21905e002 fixes the INSTALL since http://pyj.be has been down for a while (Oliver)
souliane <souliane@mailoo.org>
parents: 496
diff changeset
23 from http://pyjs.org. Since http://pyj.be has been down for a while, you can retrieve
47c21905e002 fixes the INSTALL since http://pyj.be has been down for a while (Oliver)
souliane <souliane@mailoo.org>
parents: 496
diff changeset
24 the package from our FTP.
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
25
731
47c21905e002 fixes the INSTALL since http://pyj.be has been down for a while (Oliver)
souliane <souliane@mailoo.org>
parents: 496
diff changeset
26 wget ftp://ftp.goffi.org/pyjamas/pyjamas.tar.bz2
756
9ad1a551c26d INSTALL: forcing python version should be with 2.7 and not 2.6
souliane <souliane@mailoo.org>
parents: 731
diff changeset
27 tar xvjf pyjamas.tar.bz2
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
28 cd pyjamas
777
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
29 python2.7 bootstrap.py
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
30
777
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
31 Note that we force the python version to 2.7. Salut à Toi and Libervia will be ported
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
32 to Python 3 after the Twisted framework which is our main dependency.
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
33 You can check that it works by compiling the helloworld example:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
34
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
35 cd examples/helloworld
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
36 ./build.sh
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
37
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
38 If you have no error message, it should be allright.
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
39
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
40 == Install Libervia ==
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
41
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
42 * to install Libervia using setuptools, the pyjsbuild executable should be accessible
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
43 from your environment variable "PATH". The easiest would be:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
44
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
45 cd pyjamas
757
8aa2a199d6e3 INSTALL: better explain how to create the pyjsbuild symlink (Fabien)
souliane <souliane@mailoo.org>
parents: 756
diff changeset
46 sudo ln -sf `pwd`/bin/pyjsbuild /usr/bin/pyjsbuild
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
47
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
48 * clone libervia repository:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
49
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
50 hg clone http://repos.goffi.org/libervia
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
51
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
52 * install Libervia:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
53
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
54 cd libervia
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
55 python setup.py install
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
56
777
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
57 * create an account "libervia@example.net" (replace "example.net" with your
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
58 domain or virtual host) on your XMPP server, create a profile on SàT named
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
59 "libervia", and plug the SàT profile to this account with jp or primitivus.
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
60 jp profile create libervia -j libervia@yourserver.tld -p <libervia_password>
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
61
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
62 == Configuration ==
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
63
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
64 You can configure the Libervia service from the SàT configuration file, for example:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
65
777
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
66 [libervia]
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
67 port = 8080
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
68 port_https = 8443
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
69 port_https_ext = 8443
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
70 connection_type = both
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
71 ssl_certificate = libervia.pem
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
72 redirect_to_https = 0
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
73 security_warning = 1
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
74 passphrase = <libervia_password>
c3358ea316e5 update INSTALL file
souliane <souliane@mailoo.org>
parents: 757
diff changeset
75 data_dir = ~/workspace/libervia
420
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
76
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
77 Check the wiki for more information: http://wiki.goffi.org/wiki/Configuration/en
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
78
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
79 == Usage ==
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
80
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
81 The four components must be launched in the following order:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
82
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
83 * prosody
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
84 * sat_pubsub (with the xmpp domain and password as declared in prosodi.cfg.lua)
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
85 * sat
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
86 * libervia's web server
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
87
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
88 Your command input would look like that:
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
89
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
90 cd prosody && prosodyctl start
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
91 twistd sat_pubsub --jid=sat-pubsub.<xmpp_domain> --secret=<password>
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
92 sat
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
93 libervia
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
94
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
95 You can now drop your web browser on http://localhost:8080/libervia.html
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
96
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
97 If you encounter any issue, you can ask for help on MUC room sat@chat.jabberfr.org
ac0018e4391b misc: INSTALL: convert line delimiters to UNIX
souliane <souliane@mailoo.org>
parents: 419
diff changeset
98 or use the dev mailing list: http://lists.goffi.org