Ports

jasonyates

Verified User
Joined
Sep 24, 2003
Messages
79
Hello,

How can i setup the webmail so it can be accessed through a port like cPanels webmail?
 
I'm not familiar with cpanel (or da for that matter), but it shounds like what you want to do is create a apache virtualhost on a different port, and have the document root for that contain the webmail files.

I'd guess DA will overwrite any manual changes to the httpd.conf file you make, but I did notice they have a form where you can edit hosts.

My suggestion. Create a site in DA.
in the admin panel, click administrator serttings, at the bottom click Customize Httpd Configurations. Click on the site you just created. Where it says:

<VirtualHost YOURIP:80>
change the 80 to whatever port you want it on.

Click save.
Again i'm not familiar with DA, but you could change the document root in that file (DocumentRoot /location) to the location of the webmail pages... OR... install your own webmail software into the docroot for that site.

I havent tested this but it should work.
 
what do you mean?, you dont need a seperate install of webmail for every site.
 
Oh i think i see what you mean.
that would only work if you go to domaina.com:port
if you went to another domain, say domainb.com:port it would not work no. simple way to fix is in the config file replace the IP address before the port with _default_

also you're have to add "NameVirtualHost" to: /etc/httpd/conf/ips.conf
have a look, you're see how it works from looking at that file.
 
Last edited:
I'm pretty confient that any changes you make manually to these files will be removed on your next action to them via the control panel.

OK I just tested this...
edit: /etc/httpd/conf/httpd.conf

add at the bottom:
#testconf
Listen 9000
<VirtualHost _default_:9000>
ServerAdmin [email protected]
DocumentRoot /var/www/html
ServerName localhost
ScriptAlias /cgi-bin/ /var/www/cgi-bin/
</VirtualHost>
#endtest

change the document root to point to the directory that has the webmail scripts in. 9000 is the example port i used for the webmail port.

I'm not sure how DA handles custom apache configs, but here is the apache manual page on it:
http://httpd.apache.org/docs/vhosts/examples.html

edit: i've tested this, and it works, but DA will most likely overwrite it. You can try the above out, restart apache and it'll be fine. But i think if you add a new site or anything that will make DA touch the file it'll get rid of your custom additions.
 
Last edited:
I just tried doing this using DA (method spoke of above, admin settings, edit httpd.comf, click domain bla bla)...
It doesnt work by doing that becuase DA has the form contents parsed within the virtualhost tags for that domain (which is a good thing, just not for us in this case).

You'll need a DA person to tell you how to go about mnually editing the httpd.conf file without it being overwritten.
 
Hello,

DA will not overwrite the contents of the main /etc/httpd/conf/httpd.conf. But it will overwrite the contents of the user httpd.conf files. If you want to add webmail to it's own port, you'd do it through the main httpd.conf as a one time deal for all ips..

The method JoeInShed pasted above should work if it's manually entered into the *main* httpd.conf. It won't be overwritten.

John
 
Back
Top