PDA

View Full Version : ispconfig3 and squirrel mail client


afandino
15th March 2010, 14:04
Guy's

I know this has been asked a dozen times before but i have not been able to find a clear answer.

Here is the scenario,

the mail client is accessed through the main domain of the webserver and all the clients need to be directed there for webmail access. this is how it is now.

What i need is for the client domain to have access to web mail at clientdomain.com/webmail and not the main server domain.

the other thing needed is for the address in the browser to show clientdomain/webmail, when i redirect the address bar shows the main domain/webmail

Is there a way to make this happen that is clearly described ?

thank you
tony

Toucan
18th March 2010, 12:20
Have you thought about making an HTML file in yourdom.com/webmail that consists of a frame set? You can then load maindom.com/webmail into the main body frame causing the original URL to be still displayed in the address bar?

afandino
18th March 2010, 15:11
I give that a try. Really had not considered that approach. I will let you know how it works out.

tony

tony_simcock
18th March 2010, 15:43
What I've done is have my webmail directory symlinked to all of my client domains... works for me...

afandino
18th March 2010, 16:16
What I've done is have my webmail directory symlinked to all of my client domains... works for me...


Are you using ispconfig 3.02 ?

tony_simcock
18th March 2010, 16:24
As of an hour ago - yes.
Previously I was on 3.0.1.6.

if your webmail/ directory is in /var/www/ and your client's root web directory is in /var/www/clients/client1/client1web/
then just type:

ln -s /var/www/webmail/ /var/www/clients/client1/client1web/webmail


Then when your client goes to www.client1web.com/webmail they'll get the squirrel mail login screen

Toucan
18th March 2010, 22:10
As of an hour ago - yes.
Previously I was on 3.0.1.6.

if your webmail/ directory is in /var/www/ and your client's root web directory is in /var/www/clients/client1/client1web/
then just type:

ln -s /var/www/webmail/ /var/www/clients/client1/client1web/webmail


Then when your client goes to www.client1web.com/webmail they'll get the squirrel mail login screen

Nice idea Tony, my idea of the frame really wasn't the most fancy solution. I don't have much understanding of symlinks so i might give it a try myself.


Is this why I have duplicate contents of directories?

.///www/clients/client1/web33
is the same as
.///www.snugglestore.com?

Are symlinks used for that?

Afandino, don't forget you can edit the way squirrel mail looks to make it more in keeping with your sites

afandino
19th March 2010, 02:23
As of an hour ago - yes.
Previously I was on 3.0.1.6.

if your webmail/ directory is in /var/www/ and your client's root web directory is in /var/www/clients/client1/client1web/
then just type:

ln -s /var/www/webmail/ /var/www/clients/client1/client1web/webmail


Then when your client goes to www.client1web.com/webmail they'll get the squirrel mail login screen


I tried that and i get a page that says "No input file specified. "
after i created the sym link. any ideas i have seen this before when i tried previously

tony_simcock
19th March 2010, 10:03
I tried that and i get a page that says "No input file specified. "
after i created the sym link. any ideas i have seen this before when i tried previously

Hi Afandino,
What OS are you running on? if you do a ls -al in the directory you symlinked your webmail directory to, is webmail in a red block? can you access the content of the directory by following the symlink?
eg. If you go from my example above, can you view the contents of /var/www/clients/client1/client1web/webmail ?
if not, its possible the symlink hasn't worked. In which case if you do a pwd on the dir where your webmail dir is and tell me where you want it, I'll send you the command.

Tony

afandino
19th March 2010, 14:53
i'm running on debian 5.0, I had read else ware that symbolic links to web mail
in ispconfig3.02 did not work correctly. I hope till or Falko could chime in here.

tony i have not tried ls -al.

the symbolic link i created did work in ftp i can view all the webmail files(not a good thing) I don't want my user to be able to see the contents of that directory for security reasons.

thanks for your help

tony_simcock
19th March 2010, 15:10
Ah right... Symbolic links shouldnt be an issue with ISPConfig 3, as they work fine on Centos 5.4.
Ah, the security issue can be resolved by chmod'ing the webmail dir to root, then the user who ftp's in shouldn't be able to see the files (unless its root or has root privileges?)

If the directory exists in what apache thinks is the document root for the request, then appending /webmail on the end should view its contents. Does apache have access to view the dir?

afandino
19th March 2010, 15:34
tony,

sorry for sounding stupid but where can i find the apache settings for that website.

tony_simcock
19th March 2010, 16:47
tony,

sorry for sounding stupid but where can i find the apache settings for that website.

Hi Afandino,
On mine there are individual vhost files in /etc/httpd/conf/sites-available/ (if you using ISPConfig to administer your apache setup
Failing that, the default conf file for apache is /etc/httpd/conf/httpd.conf then all the vhosts are defined at the bottom of the conf file.

afandino
19th March 2010, 18:10
I am trying to administrate through ispconfig3 . I have experienced in the past that if i try to alter settings outside of ispconfig things get all hosed up.

tony_simcock
19th March 2010, 18:50
In that case just type:

grep "DocumentRoot" /etc/httpd/conf/sites-enabled/yourwebsite.vhost


Where yourwebsite is your website. :)
That'll tell you where the webmail symlink needs to be.

Meph
26th May 2010, 17:54
Not sure if afandino was able to resolve this issue or not, but I'm having the same problem under Debian 5.0 with ISPConfig 3.

I only have one SSL certificate that I use with my primary domain, so I want webmail to work by using https://www.domain.tld/webmail.

Created the symlink as follows:

ln -s /var/www/webmail/ /var/www/domain.tld/web/webmail

When I run 'grep "DocumentRoot" /etc/apache2/conf.d/sites-enabled/domain.tld.vhost' I get:

DocumentRoot /var/www/domain.tld/web
DocumentRoot /var/www/domain.tld/web

I have been looking around the web for a solution. One of them said to turn off cgi.force_redirect, but that didn't work. It was also suggested that I set a value for doc_root, but for obvious reasons that messes up my configuration. I'm under the impression that you are supposed to leave that blank when you are running virtual hosts, or maybe I just did it wrong.

Unlike afandino I am not afraid to change settings outside of ISPConfig3. I've already disabled ClamAV. For some reason the built-in SSL certificate generator doesn't work through the ISPConfig3 control panel so I had to general my private key and CSR manually.

Any suggestions?

astewart
27th May 2010, 18:19
After following the perfect Setup ispconfig 3 for your Linux distro, manually create an .vhost for your webmail.

Eg, I am running ubuntu and my squirrelmail.vhost looks like this:
Alias /webmail /usr/share/squirrelmail

<Directory /usr/share/squirrelmail>
Options Indexes FollowSymLinks
<IfModule mod_php4.c>
php_flag register_globals off
</IfModule>
<IfModule mod_php5.c>
php_flag register_globals off
</IfModule>
<IfModule mod_dir.c>
DirectoryIndex index.php
</IfModule>

# access to configtest is limited by default to prevent information leak
<Files configtest.php>
order deny,allow
deny from all
allow from 127.0.0.1
</Files>
</Directory>


This file resides in:
/etc/apache2/sites-available

But you will have to create a symlink to have it added to:
/etc/apache2/sites-enabled

(This is Ubuntu's Apache setup, unsure about other distros).

Then just restart apache.

All domains you host should be able to access webmail now:
domain1.com/webmail
domain2.com/webmail
etc.

Meph
27th May 2010, 20:31
Thank you, that worked. The file did not exist in sites-available though so I just created a new file in sites-enabled, and copied and pasted the example you posted.