Labs/Weave/Sync/1.0/Setup: Difference between revisions

Jump to navigation Jump to search
no edit summary
m (→‎Sample virtual host config: this "hint" about http authentication doesn't apply anymore because weave handles auth by itself now)
No edit summary
Line 25: Line 25:
Don't forget to set up the weave directory in a virtual-host-directive (or similar), or else php will not work. (See sample virtual host config below)
Don't forget to set up the weave directory in a virtual-host-directive (or similar), or else php will not work. (See sample virtual host config below)


3) Copy /server/sync/1.0/default_constants.php.dist to /server/sync/1.0/default_constants.php and edit it as described below. If you have mutiple hostnames, you can put override constant files into {HOST_NAME}_constants.php
3) Copy 1.0/default_constants.php.dist to 1.0/default_constants.php and edit it as described below. If you have mutiple hostnames, you can put override constant files into {HOST_NAME}_constants.php


== Setting up Weave Authentication ==
== Setting up Weave Authentication ==
Line 32: Line 32:


<pre>
<pre>
define('WEAVE_AUTH_ENGINE', '[sqlite|mysql|ldap|none]');
define('WEAVE_AUTH_ENGINE', '[mysql|ldap|none]');
</pre>
</pre>


Line 42: Line 42:


For more information on the auth store, see the user setup
For more information on the auth store, see the user setup
=== Sqlite ===
<pre>
define('WEAVE_SQLITE_AUTH_DIRECTORY', '<path to stores directory>');
</pre>


=== Mysql ===
=== Mysql ===
Line 64: Line 57:


<pre>
<pre>
define('WEAVE_STORAGE_ENGINE', '[sqlite|mysql|none]');
define('WEAVE_STORAGE_ENGINE', 'mysql');
</pre>
 
=== Sqlite ===
 
Edit the following constant:
 
<pre>
define('WEAVE_SQLITE_STORE_DIRECTORY', '<path to stores directory>');
</pre>
</pre>
Easiest way to create a user is to go through the admin server process below.


=== Mysql ===
=== Mysql ===
Line 132: Line 115:
Caps the size (in bytes - watch out for large unicode characters!) of a payload.
Caps the size (in bytes - watch out for large unicode characters!) of a payload.


<pre>
define('WEAVE_SHARE_DBH', '1');
</pre>
If both the storage engine and authentication engine are using the same database, setting this makes both engines use the same database handler rather than opening different ones. Note that SQLite cannot use the same db for authentication and storage.


== Sample virtual host config ==
== Sample virtual host config ==
Sample Virtual host config for a server having SSL. For debian placed in /etc/apache2/sites-enabled/, weave server directory located at /var/www/weaveserver/server/.
Sample Virtual host config for a server having SSL. For debian placed in /etc/apache2/sites-enabled/, weave server directory located at /var/www/weaveserver-sync.
<pre>
<pre>
<VirtualHost weave.my.domain:443>
<VirtualHost weave.my.domain:443>


ServerName weave.my.domain
ServerName weave.my.domain
DocumentRoot /var/www/weaveserver/server/
DocumentRoot /var/www/weaveserver-sync/


ErrorLog /var/log/apache2/weaveserver-error.log
ErrorLog /var/log/apache2/weaveserver-error.log
Line 153: Line 131:
SSLCertificateFile /path/to/server.cert.crt
SSLCertificateFile /path/to/server.cert.crt


<Directory "/var/www/weaveserver/server/">
<Directory "/var/www/weaveserver-sync/">


Options Indexes FollowSymLinks
Options Indexes FollowSymLinks
Line 161: Line 139:
</Directory>
</Directory>


Alias /1.0 /var/www/weaveserver/server/sync/1.0/index.php
Alias /1.0 /var/www/weaveserver-sync/1.0/index.php


</VirtualHost>
</VirtualHost>
canmove, Confirmed users
1,173

edits

Navigation menu