Submitted by Anonymous on
## Get RoundCube
To get started, you need to download RoundCube. You can find a **Rouncube 0.8.1 with plugin obm addressbook** [Here](http://www.obm.org/roundcube-addressbook-plugin/obm-webmail.tar.gz "obm-webmail.tar.gz")
## Get it ready
Now that we've got our files, we can upload the whole directory to the web server (using your favorite scp or FTP program) in case you're not already working there.
RoundCube needs to save some temp files and it also writes logs. Therefore make sure that the following directories (and the files within) are writable by the web server user:
temp
logs
## Database Configuration
Next thing we need to do is decide what database backend we'll use. The most common is MySQL but others are PostgreSQL and SQLite. So once you decide, create a database with any name you want and grant privileges to a separate database user. It's recommended not to use an existing user or root.
With MySQL you can set up the database by issuing the following commands:
CREATE DATABASE roundcubemail;
GRANT ALL PRIVILEGES ON roundcubemail.* TO username@localhost IDENTIFIED BY 'password';
(of course you have to replace the database, username and password accordingly)
See the INSTALL file for information about setting up PostgreSQL or SQLite
If you are using MySQL, be sure to flush the users privileges when you add a new user or you will get a database connection error:
FLUSH PRIVILEGES;
Note that preconfigured database tables are included in the SQL folder. Import or restore your version or you may get a 500 Error.
Configuring RoundCube
After uploading the files point your browser to [http://url-to-roundcube/installer/](http://url-to-roundcube/installer/) to start the install wizard. The first page shows some requirements, and when you click "START INSTALLATION", the installer checks if everything is there. In case you see some red NOT OK messages, you need to install or enable something. Follow the links or find out more by searching your web site for your server's operating system or [http://www.php.net](http://www.php.net).
Once your web server is ready to run RoundCube you can start creating the config files on the next step. Click "NEXT" to get there. Get through the form and change the settings according to your needs. Don't forget to enter the database credentials within the "Database Setup" section. All the config parameter are described with a few words. If you don't know that a setting means, find out more on the Howto_Config page or just trust the defaults.
When finished the configuration hit the "CREATE CONFIG" button at the bottom of the page. You now get two text boxes on top of your browser window. Copy the contents and put them into two files within the config directory of your RoundCube installation. Name them main.inc.php and db.inc.php as stated above the text boxes. Warning: Pasting directly into an editor such as nano may not work due to word-wrapping. Please use vi or download the files directly instead.
Finally click "CONTINUE" and get to the last step of the install process. Now your configuration is being verified tested against your webserver. Click the "Initialize database" button in you're requested to in order to create the necessary tables in your database.
If there are no red NOT OK messages, you can also try to send a mail in order to test the SMTP settings.
Last but not least you have to remove the whole installer directory from the webserver. If this remains active it can expose the configuration including passwords.
Protect your installation
Access through your webserver to at least the following directories should be denied:
/config
/temp
/logs
Roundcube use .htaccess files to protect this directories, be sure to allow override of the Limit directives to get them taken into account.
## Configure the OBM Integration
### Install the plugin (optional)
__If you're using a Roundcube installation that bundles the plugin, you can skip this section.__
* Download the most recent build of the plugin from [here](http://obm.org/roundcube-addressbook-plugin/build/)
* Unzip the archive in _.../webmail/plugins/_
* Go to the plugin directory: `cd .../webmail/plugins/obm_addressbook`
### Configure the adress of the OBM-Sync server
By default the plugin file search OBM-sync in localhost ( "127.0.0.1" ).
" Ok, my case ":
rename config.inc.php.dist in **config.inc.php** :
mv config.inc.php.dist config.inc.php
"NOK, not my case":
rename config.inc.php.dist in **config.inc.php** :
mv config.inc.php.dist config.inc.php
vim config.inc.php
Change IP of OBM-sync in line 13:
// Ip to join obm-sync
$rcmail_config['obmSyncIp'] = "127.0.0.1";
### Disable the Users address book
Due to a known issue ([OBMFULL-4802](http://ci-obm.linagora.com/jira/browse/OBMFULL-4802)), the _Users_ address book cannot be used. You're advised to disable it by setting
$rcmail_config['OBMaddressbook_showUsersBook'] = false;
on line 44 in the configuration.
### Add an OBM LDAP address book
To get auto-completion as well as an adress book containing all OBM users, please follow these steps:
* Install the PHP/Ldap integration package `yum install php-ldap` on CentOS or on debian `apt-get install php5-ldap`
* Edit `.../webmail/config/main.inc.php` and modify the following properties:
$rcmail_config['address_book_type'] = array('sql', 'ldap'); $rcmail_config['autocomplete_addressbooks'] = array('sql', 'obm');
* Then add the following property:
$rcmail_config['ldap_public'] ['obm'] = array( 'name' => 'OBM', 'hosts' => array('127.0.0.1'), 'port' => 389, 'use_tls' => false, 'user_specific' => false, 'base_dn' => 'dc=local', 'bind_dn' => '', 'bind_pass' => '', 'search_base_dn' => '', 'search_filter' => '(&(objectClass=posixAccount)(uid=%u))', 'writable' => false, 'ldap_version' => 3, 'search_fields' => array('mail', 'cn'), 'name_field' => 'cn', 'hidden' => false, 'email_field' => 'mail', 'surname_field' => 'sn', 'firstname_field' => 'gn', 'sort' => 'cn', 'scope' => 'sub', 'filter' => '(&(mail=*)(|(objectClass=obmUser)(objectClass=obmGroup)(objectClass=obmMailShare)))', 'fuzzy_search' => true, 'sizelimit' => '0', 'timelimit' => '0' );
If your LDAP server isn't on the same machine, replace _127.0.0.1_ in the above property by the adress of your host.
### Activate the OBM Plugin
In order to have synchronization between Obm addressbook and plugin you have to activate the plugin in `.../webmail/config/main.inc.php`
Search plugin parameter ( line 373 - 380 for me :) ) and add 'obm_addressbook' in the empty array like this:
// ----------------------------------
// PLUGINS
// ----------------------------------
// List of active plugins (in plugins/ directory)
$rcmail_config['plugins'] = array('obm_addressbook');
## And It's Done !Compra Zapatillas de running para hombre