Global Roundcube and Webmail

6 posts / 0 new
Last post
#1 Tue, 02/21/2017 - 01:21
samrich

Global Roundcube and Webmail

So, I have the following: CentOS 7, Virtualmin 5.06, all installed and working with a single domain. I want to setup roundcube to be globally accessible for all of the domains that I need to add. I have read the following:

https://www.virtualmin.com/documentation/id%2Cwebmail_and_virtualmin

But am having trouble with the webmail.mydomain.net. If I try to create a new top level or virtual sub-server for webmail, it fails and I get the following error:

Failed to create virtual server : The domain webmail.mydomain.net is already hosted by your Apache webserver

What's the best way to overcome this Apache Alias for webmail? Do I need to edit the http.conf, or is there something simple that I am missing?

My goal is to have all domains be able to access roundcube from: https://webmail.mydomain.net . This will reduce the number of roundcube installs and required hard drive space and make updates ten times easier.

Thoughts?

Tue, 02/21/2017 - 04:21
Diabolico
Diabolico's picture

The error you have is because webmail.domain.tld is already dedicated to Usermin. If you go to /etc/httpd/conf/ and open httpd.conf you will have something like this:

<VirtualHost xxx.xxx.xxx.xxx:80>
. . .
ServerAlias webmail.domain.tld
. . .
RewriteCond %{HTTP_HOST} =webmail.domain.tld
RewriteRule ^(.*) https://domain.tld:Usermin_port/ [R]
. . .
</VirtualHost>


Same thing for <VirtualHost xxx.xxx.xxx.xxx:443>.

Easiest way would be to use something else than webmail.domain.tld or you could modify your Apache.

- I often come to the conclusion that my brain has too many tabs open. -
Failing at desktop publishing & graphic design since 1994.

Tue, 02/21/2017 - 14:21
samrich

Diabolico,

I found this discussion from 2014: https://www.virtualmin.com/node/21165#comment-771880

Where would user "aplima" have put the apache directives in the httpd.conf file? Any thoughts?

Tue, 02/21/2017 - 16:55
Diabolico
Diabolico's picture

Never used Roundcube so i dont know if that solution would help but you can always try and see if it works. Just make local backup of each file you want to modify.

But in that topic you have great advice from just_me to make "neutral" domain and use it for such things. If you check around most of hosting companies will have same solution, e.g. SuperUSAhost.com (just invented name) will have url to their control panel (like cPanel) usfastcontrolpanel.com:some_port or x023.usfastcontrolpanel.com:some_port. i could go on with clustering and other things but probably this isnt what you want...

If you need something fast and easy why dont you use different name for subdomain, like email.domain.tld and in this way you dont need to modify anything.

- I often come to the conclusion that my brain has too many tabs open. -
Failing at desktop publishing & graphic design since 1994.

Wed, 03/01/2017 - 10:48
samrich

So, ended up making a neutral sub-domain for all of the clients to access. Just installed Roundcube to the public_html directory of the subdomain. All works and clients haven't minded.

Thanks for the help.

Wed, 03/01/2017 - 11:57
Welshman
Welshman's picture

In the past anyone with access to the /home file system, like a dev / designer brought in etc etc could see the actual pwd of the main admin in a RC config file.

This may be the same through out VM install procedure for any software installed using the install script option. As I don't think you get to choose who has the permissions on install but it automatically assumed and assigned to top lvl domain owner.

Chaos Reigns Within, Reflect, Repent and Reboot, Order Shall Return.

Topic locked