April 26, 2010

 Creating Public Folders for Atmail

This is a document for users who want to create publicly accessible folders via Atmail. This applies for the Atmail Server version.

- first, open up /usr/local/atmail/mailserver/etc/dovecot.conf
- find this line:

info_log_path = /usr/local/atmail/mailserver/spool/log/dovecot_info_log

- below this, add:

namespace public {
  separator = .
  prefix = shared.
  location = maildir:/usr/local/atmail/users/shared/:INDEX=~/public
  subscriptions = no
}

- create the shared directory:

% mkdir /usr/local/atmail/users/shared

- apply the right permissions:

% chown atmail:atmail /usr/local/atmail/users/shared

- save changes. restart Dovecot afterwards:

% /etc/init.d/atmailserver restart

A "shared" container should then be created inside of the user's webmail interface. To create folders inside this container, create the directory manually:

% mkdir /usr/local/atmail/users/shared/.Foldername

Where ".Foldername" is the folder name prefixed by a full stop (".") . For example, a shared folder called "Gouda" would be created this way:

% mkdir /usr/local/atmail/users/shared/.Gouda

Set the permissions correctly afterwards:

% chown atmail:atmail /usr/local/atmail/users/shared/.Gouda

This will then have the folder publicly accessible by all users in your system.


Filed under: Customization, Atmail 6 — John Contad @ 6:04 pm

 

April 22, 2010

 Restrict Atmail 6 WebAdmin To Specific IP Address

If you want to restrict WebAdmin access to specified IP addresses, you can do the following. This will redirect back to the login page if the IP does not match.

Open and edit your http.conf file. Add the following code.

RewriteEngine On
RewriteCond %{REMOTE_ADDR} ![IP-Address]
RewriteRule ^/(.*)index.php/admin(.*) /$1index.php [R]

Where [IP-Address] is the desired IP address.

Save, exit and restart Apache.

/etc/init.d/httpd restart

If you wish to be able to access the WebAdmin from multiple IP's do the following.

RewriteEngine On
RewriteCond %{REMOTE_ADDR} ![IP-Address]
RewriteCond %{REMOTE_ADDR} ![IP-Address]
RewriteCond %{REMOTE_ADDR} ![IP-Address]
RewriteRule ^/(.*)index.php/admin(.*) /$1index.php [R]


Filed under: Uncategorized — Stewart Bazley @ 6:01 pm