Syntax for webmail

6 posts / 0 new
Last post
#1 Fri, 11/26/2010 - 17:38
yaminz66

Syntax for webmail

Hi

Whats the url syntax for webmail? The conventional www.domain.com/webmail does not work.

regards

Yamin

Fri, 11/26/2010 - 18:49
Locutus

In case you're talking about Usermin as set up by Virtualmin for virtual servers, the default URL is "webmail.domain.com" (forwarded to "domain.com:20000" via Apache mod_rewrite), configurable in the server template, section Apache Website.

Sat, 11/27/2010 - 04:09
yaminz66

Hi

I was able to access it using https://domain.com:20000 but not https://webmail.domain.com.

I have added a host record in the DNS webmail.domain.com for the website. Then I get the default page from Apache/Centos.

I have checked my settings in the Virtualmin/Webmin and its set to default.

Regards

Yamin

Sat, 11/27/2010 - 04:14
yaminz66

My DNS is handled by the name server on ISP not on my local server.

Sat, 11/27/2010 - 05:07
Locutus

Virtualmin should add the necessary entries to BIND and Apache automatically when setting up a new vserver, when the template is set up accordingly.

Adding the A record to BIND alone isn't sufficient, since with that you only say that "webmail.domain.com" resolves to your IP, but Apache does not know what to do with it. That's why it shows the default page.

To actually instruct Apache to forward that to "https://domain.com:20000", the following lines in the vserver's config file are used by default:

RewriteEngine on
RewriteCond %{HTTP_HOST} =webmail.domain.com
RewriteRule ^(.*) h-ttps://domain.com:20000/ [R]

Replace "h-ttps" with "https" when using those lines. Have to type it that weirdly, cause otherwise the forum software here will try to auto-create an "a href" link in the code block, messing it up really good.

Sat, 11/27/2010 - 13:12
yaminz66

Hi

The directives are already there. Its working now,. I was typing https://webmail.domain.com instead of

http://webmail.domain.com

Regards

Yamin

Topic locked