Mudanças entre as edições de "IRedMail com Nginx"

De MochilaWiki
Ir para navegaçãoIr para pesquisar
Linha 1: Linha 1:
Depois de instalar o [[Iredmail]] e o [[Nginx]] faça:
+
<source lang="bash">
 +
echo deb http://php53.dotdeb.org lenny all >> /etc/apt/sources.list
 +
gpg --keyserver keys.gnupg.net --recv-key 89DF5277
 +
gpg -a --export 89DF5277 | apt-key add -
 +
apt-get update
  
<source lang="bash">
+
apt-get install libpcre3-dev libssl-dev build-essential php5-fpm
update-rc.d -f apache2 remove
+
 
/etc/init.d/apache2 stop
+
sed -i 's/post_max_size\ =\ 8M/post_max_size\ =\ 10M/g' /etc/php5/fpm/php.ini
sed -i 's/post_max_size\ =\ 8M/post_max_size\ =\ 10M/g' /etc/php5/cgi/php.ini
+
sed -i 's/upload_max_filesize\ =\ 2M/upload_max_filesize\ =\ 10M/g' /etc/php5/fpm/php.ini
sed -i 's/upload_max_filesize\ =\ 2M/upload_max_filesize\ =\ 10M/g' /etc/php5/cgi/php.ini
+
echo cgi.fix_pathinfo = 1 >> /etc/php5/fpm/php.ini
ln -s /usr/share/apache2/roundcubemail-0.3.1/ /usr/share/apache2/webmail
+
echo suhosin.session.encrypt = Off >> /etc/php5/fpm/php.ini
ln -s /usr/share/apache2/phpldapadmin-1.2.0.5 /usr/share/apache2/ldap
+
echo 'date.timezone = "America/Sao_paulo"' > /etc/php5/conf.d/date.ini
  ln -s /usr/share/apache2/roundcubemail-0.3.1/ /usr/share/apache2/mail
+
rm /etc/php5/fpm/conf.d/mhash.ini
wget http://pub.nkosi.org/iredmail/nginx.conf-iredmail
+
 
wget http://pub.nkosi.org/praweb/cgi-bin.php.txt
+
cd /usr/src
mv cgi-bin.php.txt /usr/share/apache2/cgi-bin.php
+
wget -c http://nginx.org/download/nginx-0.8.54.tar.gz
mv nginx.conf-iredmail /etc/nginx/sites-enabled/iredmail
+
tar zxvf nginx-0.8.54.tar.gz
 +
cd nginx-0.8.54/
 +
./configure --prefix=/usr/local/nginx --user=www-data --group=www-data \
 +
--without-mail_pop3_module --without-mail_imap_module --with-sha1=/usr/lib \
 +
--without-mail_smtp_module --with-http_stub_status_module \
 +
--with-http_ssl_module --http-log-path=/var/log/nginx/access.log \
 +
--conf-path=/etc/nginx/nginx.conf --pid-path=/var/run/nginx.pid \
 +
--with-http_sub_module --with-http_ssl_module --with-http_gzip_static_module \
 +
--with-http_stub_status_module
 +
make
 +
make install
 +
 
 +
cd /usr/src
 +
mkdir /etc/nginx/sites-enabled
 +
wget http://pub.nkosi.org/nginx/iredmail/nginx-init
 +
wget http://pub.nkosi.org/iredmail/nginx.conf-iredmail
 +
wget http://pub.nkosi.org/iredmail/nginx.conf
 +
mv nginx-init /etc/init.d/nginx
 +
mv nginx.conf /etc/nginx/
 +
mv nginx.conf-iredmail /etc/nginx/sites-enabled
 +
chmod 755 /etc/init.d/nginx
 +
update-rc.d -f apache2 remove
 +
update-rc.d nginx defaults
 +
/etc/init.d/apache2 stop
 +
 
 +
wget -c http://sourceforge.net/projects/roundcubemail/files/roundcubemail/0.5.1/roundcubemail-0.5.1.tar.gz/download -O roundcubemail-0.5.1.tar.gz
 +
tar zxvf roundcubemail-0.5.1.tar.gz
 +
mv roundcubemail-0.5.1 /usr/share/apache2/
 +
cd /usr/share/apache2/
 +
cp roundcubemail/config/* roundcubemail-0.5.1/config/
 +
chown -R www-data\: roundcubemail-0.5.1
 +
sed -i 's/roundcubemail/roundcube/g' roundcubemail-0.5.1/config/db.inc.php
 +
 
 +
mysql -u root -p
 +
create database roundcube;
 +
use roundcube;
 +
source roundcubemail-0.5.1/SQL/mysql.initial.sql
 +
grant all on roundcube.* to roundcube@localhost;
 +
quit
 +
 
 +
ln -s /usr/share/apache2/roundcubemail-0.5.1/ /usr/share/apache2/webmail
 +
ln -s /usr/share/apache2/roundcubemail-0.5.1/ /usr/share/apache2/mail
 +
/etc/init.d/php5-fpm start
 +
/etc/init.d/nginx start
 
</source>
 
</source>
  
Linha 19: Linha 66:
 
* https://mail.elegbara.net/phpmyadmin
 
* https://mail.elegbara.net/phpmyadmin
 
* https://mail.elegbara.net/postfixadmin/
 
* https://mail.elegbara.net/postfixadmin/
* https://mail.elegbara.net/awstats/awstats.pl
 
* https://mail.elegbara.net/phpldapadmin/
 
* https://mail.elegbara.net/ldap
 
 
* https://mail.elegbara.net/mail/
 
* https://mail.elegbara.net/mail/
 
falta ainda
 
* nginx com mysql para o awstats com senha
 
* iredadmin https://mail.elegbara.net/iredadmin/ - python
 
  
  
 
IRedMail with Nginx
 
IRedMail with Nginx

Edição das 19h40min de 1 de março de 2011

echo deb http://php53.dotdeb.org lenny all >> /etc/apt/sources.list
gpg --keyserver keys.gnupg.net --recv-key 89DF5277
gpg -a --export 89DF5277 | apt-key add -
apt-get update

apt-get install libpcre3-dev libssl-dev build-essential php5-fpm 

sed -i 's/post_max_size\ =\ 8M/post_max_size\ =\ 10M/g' /etc/php5/fpm/php.ini
sed -i 's/upload_max_filesize\ =\ 2M/upload_max_filesize\ =\ 10M/g' /etc/php5/fpm/php.ini
echo cgi.fix_pathinfo = 1 >> /etc/php5/fpm/php.ini
echo suhosin.session.encrypt = Off >> /etc/php5/fpm/php.ini
echo 'date.timezone = "America/Sao_paulo"' > /etc/php5/conf.d/date.ini
rm /etc/php5/fpm/conf.d/mhash.ini

cd /usr/src
wget -c http://nginx.org/download/nginx-0.8.54.tar.gz
tar zxvf nginx-0.8.54.tar.gz
cd nginx-0.8.54/
./configure --prefix=/usr/local/nginx --user=www-data --group=www-data \
--without-mail_pop3_module --without-mail_imap_module --with-sha1=/usr/lib \
--without-mail_smtp_module --with-http_stub_status_module \
--with-http_ssl_module --http-log-path=/var/log/nginx/access.log \
--conf-path=/etc/nginx/nginx.conf  --pid-path=/var/run/nginx.pid \
--with-http_sub_module --with-http_ssl_module --with-http_gzip_static_module \
--with-http_stub_status_module
make
make install

cd /usr/src
mkdir /etc/nginx/sites-enabled
wget http://pub.nkosi.org/nginx/iredmail/nginx-init
wget http://pub.nkosi.org/iredmail/nginx.conf-iredmail
wget http://pub.nkosi.org/iredmail/nginx.conf
mv nginx-init /etc/init.d/nginx
mv nginx.conf /etc/nginx/
mv nginx.conf-iredmail /etc/nginx/sites-enabled
chmod 755 /etc/init.d/nginx
update-rc.d -f apache2 remove
update-rc.d nginx defaults
/etc/init.d/apache2 stop

wget -c http://sourceforge.net/projects/roundcubemail/files/roundcubemail/0.5.1/roundcubemail-0.5.1.tar.gz/download -O roundcubemail-0.5.1.tar.gz
tar zxvf roundcubemail-0.5.1.tar.gz
mv roundcubemail-0.5.1 /usr/share/apache2/
cd /usr/share/apache2/
cp roundcubemail/config/* roundcubemail-0.5.1/config/
chown -R www-data\: roundcubemail-0.5.1
sed -i 's/roundcubemail/roundcube/g' roundcubemail-0.5.1/config/db.inc.php

mysql -u root -p
create database roundcube;
use roundcube;
source roundcubemail-0.5.1/SQL/mysql.initial.sql
grant all on roundcube.* to roundcube@localhost;
quit

ln -s /usr/share/apache2/roundcubemail-0.5.1/ /usr/share/apache2/webmail
ln -s /usr/share/apache2/roundcubemail-0.5.1/ /usr/share/apache2/mail
/etc/init.d/php5-fpm start
/etc/init.d/nginx start

funciona


IRedMail with Nginx