Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > ISPConfig 3 > Tips/Tricks/Mods

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 12th January 2012, 16:33
cbj4074 cbj4074 is offline
Senior Member
 
Join Date: Nov 2010
Posts: 386
Thanks: 28
Thanked 58 Times in 50 Posts
Default How to upgrade Roundcube 0.3 to 0.7 on Ubuntu 10.04 LTS

For those who wish to use the Roundcube webmail plug-in for ISPConfig3 ( http://bugs.web-wack.at/projects/isp3-roundcube ) on Ubuntu 10.04, you will have to upgrade Roundcube from 0.3.x (the latest stable version available via the Ubuntu repositories) to 0.7.x (the latest stable version available from the authors).

One method is to remove the Roundcube package altogether and install manually ( e.g., http://www.howtoforge.com/how-to-ins...debian-squeeze ).

However, for those who prefer to use packages whenever possible, here's the alternative.

1.)

Download the required packages for the new version of Roundcube from the Debian repositories.

Each file can be downloaded using the wget command:

Code:
# wget [URL of file]
The files will be stored in your current working directory.

Roundcube 0.7 requires:

libjs-jquery
libjs-jquery-ui
php-net-smtp (>= 1.4.2)
php-mail-mime (>= 1.8.0)
libjs-jquery (>= 1.6.4)
libjs-jquery-ui (>= 1.8)

2.)

Remove the currently-installed version of Roundcube. These steps can be combined into a single step, but each is presented separately for the sake of clarity.

Code:
# apt-get remove --purge roundcube
Code:
# apt-get remove --purge roundcube-core
You should be prompted to remove the underlying database; choose "Yes" and provide the appropriate MySQL password (usually the MySQL root user's password).

Code:
# apt-get remove --purge roundcube-mysql
Code:
# apt-get remove --purge roundcube-sqlite
The next two packages may not be installed, but it doesn't hurt to execute these commands, just in case.

Code:
# apt-get remove --purge libjs-jquery
Code:
# apt-get remove --purge libjs-jquery-ui
3.)

Install the new version of Roundcube from the packages that you downloaded. The order matters, due to package dependencies.

Use the dpkg application to install each package, e.g.:

Code:
# dpkg -i ./package-name.deb
in the following order:

libjs-jquery
libjs-jquery-ui
php-mail-mime
php-net-smtp
roundcube-sqlite
roundcube-mysql
roundcube-core

If at this point you receive dependency errors regarding the php5-intl and/or the libicu42 package, execute the following command:

Code:
# apt-get -f install
and the dependencies should be resolved automatically, and the roundcube-core package will be installed immediately thereafter.

You will be prompted to configure the database for Roundcube. Most likely, you will want to choose the "mysql" option. Again, enter the appropriate MySQL password (usually the root user's password).

On the next screen, enter a password for the Roundcube database, or leave the field blank to have the system generate a strong password for you.

roundcube

That's the last package! Now to configure Roundcube.

4.)

There are four Roundcube directories that are created:

Code:
/usr/share/roundcube (do not make changes here)
/var/lib/roundcube (DO make changes/customizations here)
/var/log/roundcube
/etc/roundcube (do not make changes here)
The /var/lib/roundcube directory contains symbolic links (symlinks) to various locations throughout the other three directories, so be sure to make your changes here and not in the target directories (otherwise, you may end-up with a botched installation in the future).

The Roundcube package for Debian has Arabic as the default language, so change that first:

Code:
# vi /var/lib/roundcube/config/main.inc.php
and change line 380 to suit your language preference, e.g.:

Code:
$rcmail_config['language'] = 'en_US';
If you wish to customize or "brand" the Roundcube interface, change line 292 accordingly, e.g.:

Code:
$rcmail_config['product_name'] = 'My Company\'s Webmail';
If you are not using multiple mail servers, and your only mail server is running on the same network interface (i.e., the same server) as the Web server, you can spare your users the trouble of having to enter a mail server at login by specifying the default value on line 72, e.g.:

Code:
$rcmail_config['default_host'] = 'localhost';
Assuming you have a functioning SMTP service (e.g., Postfix) on this server, you should direct Roundcube to send mail via SMTP on line 138 (otherwise Roundcube will use PHP's mail functions, which are much slower):

Code:
$rcmail_config['smtp_server'] = '%h';
If your Web server is SSL-enabled (you should enable SSL, even if with a self-signed certificate), modify line 189 to force Roundcube to take advantage of this (we'll configure Apache accordingly in a subsequent step):

Code:
$rcmail_config['force_https'] = true;
There are a few other worthwhile tips in the article cited at the top of this post:

Quote:
Code:
$rcmail_config['message_cache_lifetime'] = '30m';
[...]
$rcmail_config['session_lifetime'] = 30;
[...]
$rcmail_config['create_default_folders'] = TRUE;
The final configuration step is to create an alias in your Apache configuration. This can be done in any of several different places, but the most logical place to make the change is in /etc/apache2/conf.d/roundcube.conf, as this file is included in Apache's configuration automatically.

Code:
# Add this line at the top of the file.
Alias /webmail /var/lib/roundcube

# Add these lines just after the "allow from all" within
# the <Directory /var/lib/roundcube/> block.
# Lines below this (within this Directory block) are custom.
  <IfModule mod_rewrite.c>
    <IfModule mod_ssl.c>
      RewriteCond %{HTTPS} !=on
      RewriteRule ^.*$ https://%{SERVER_NAME}:%{SERVER_PORT}%{REQUEST_URI} [R,L]
    </IfModule>
  </IfModule>
  <IfModule suphp_module>
    suPHP_Engine Off
    AddHandler php5-script	.php
  </IfModule>
  php_admin_value open_basedir "/usr/share/php:/etc/roundcube/:/usr/share/roundcube:/var/log/roundcube:/var/lib/roundcube"
Note: The above configuration is slightly more dynamic than that used in the "official How To" in that the mod_rewrite rule does not require the server name, port, or webmail URI to be hard-coded. Better still, I have added directives to ensure that Roundcube works even if suPHP is enabled (e.g., when using Fast-CGI PHP mode with Apache's su_php module).

Reload the Apache configuration:

Code:
# service apache2 reload
5.)

Install the Roundcube webmail plug-in for ISPConfig3 by following the instructions on the plug-in's website:

http://bugs.web-wack.at/documents/1

The directory to be in before executing the SVN checkout command is /var/lib/roundcube/plugins:

Code:
# cd /var/lib/roundcube/plugins
Any questions or problems are most likely addressed in the official FAQ on the plug-in's website, which has a forum if not.

Good luck!

Last edited by cbj4074; 12th January 2012 at 16:50.
Reply With Quote
The Following 2 Users Say Thank You to cbj4074 For This Useful Post:
falko (13th January 2012), Horfic (20th January 2012)
Sponsored Links
  #2  
Old 19th January 2012, 19:50
cbj4074 cbj4074 is offline
Senior Member
 
Join Date: Nov 2010
Posts: 386
Thanks: 28
Thanked 58 Times in 50 Posts
 
Default

One small correction: the path to the Apache configuration file that is included with most Roundcube packages is

Code:
/etc/apache2/conf.d/roundcube
and not

Code:
/etc/apache2/conf.d/roundcube.conf
as stated in my initial post.
Reply With Quote
Reply

Bookmarks

Tags
apache, roundcube, ubuntu 10.04, webmail

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Change SquirrelMail to Roundcube (Perfect Ubuntu 10.04) Isterklister Server Operation 3 13th July 2010 17:02
Upgrade ispconfig3 from ubuntu 9.10 to ubuntu 10.04 Lucid Lynx u4david Installation/Configuration 2 21st May 2010 14:53
Connection timed out on intermail outgoing mails gouravgarg Server Operation 6 5th March 2010 20:31
Unbale to login to Postfix from webmail wasimriz HOWTO-Related Questions 5 6th April 2009 13:49
CENTOS 5 Ping Problem gAnDo Server Operation 11 28th March 2008 20:58


All times are GMT +2. The time now is 10:22.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.