default webmail

microz

Verified User
Joined
Jun 10, 2009
Messages
122
Location
Santiago, Chile
Hi,

Whats correct way to change default webmail to another? I'm trying modifing config httpd alias, works well, but after of apache updates is neccesary modify again.

I refer to url/webmail (not skin links)

Any suggestion?

Rgds,
Eduardo
pd. srry by my bad english :p
 
For the /webmail url you can use the custom directory.

Code:
mkdir -p /usr/local/directadmin/custombuild/custom
mkdir -p /usr/local/directadmin/custombuild/custom/ap2
mkdir -p /usr/local/directadmin/custombuild/custom/ap2/conf
mkdir -p /usr/local/directadmin/custombuild/custom/ap2/conf/extra

Now copy your httpd-alias.conf to /usr/local/directadmin/custombuild/custom/ap2/conf/extra and next time apache is compiled, you will have your customized httpd-alias.conf with the /webmail alias you set.
 
All what you need it to add

webmail_link=roundcube

into directadmin.conf and rewrite settings:

Code:
echo "webmail_link=roundcube" >> /usr/local/directadmin/conf/directadmin.conf
/etc/init.d/directadmin restart
cd /usr/local/directadmin/custombuild
./build update
./build rewrite_confs


with this you will get
/etc/httpd/conf/extra/httpd-alias.conf with the following content:

Code:
Alias /config /var/www/html/redirect.php
Alias /roundcube /var/www/html/roundcube
Alias /webmail /var/www/html/roundcube
Alias /phpMyAdmin /var/www/html/phpMyAdmin
Alias /phpmyadmin /var/www/html/phpMyAdmin
Alias /pma /var/www/html/phpMyAdmin

and /etc/nginx/webapps.hostname.conf (if nginx is used):


Code:
        location /phpmyadmin {
                rewrite ^/* /phpMyAdmin last;
        }       location /pma {
                rewrite ^/* /phpMyAdmin last;
        }       location /webmail {
                rewrite ^/* /roundcube last;
        }       if ($request_method !~ ^(GET|HEAD|POST)$ ) {
                return 444;
        }
        location ~ /(\.htaccess|\.htpasswd|\.user\.ini) {
                deny all;
        }


There is no need to customize those files any longer and put them into
/usr/local/directadmin/custombuild/custom/
 
Ah indeed thank you. That must be changed then, at first in 2.0 I had to do that manually.
Makes things easier.
 
Back
Top