Revision 8265,
1.1 KB
checked in by angelo, 10 years ago
(diff) |
Ticket #0000 - sincronizacao das alteracoes do trunk com este sandbox
|
Rev | Line | |
---|
[5797] | 1 | |
---|
| 2 | # Servico SMTP (Postfix) |
---|
| 3 | |
---|
| 4 | # Parametro 1: Diretorio onde estao os arquivos de configuracao (modelo) |
---|
| 5 | smtp () { |
---|
| 6 | get_org |
---|
| 7 | |
---|
| 8 | DIR_POSTFIX="$1" |
---|
| 9 | sed -e "s/LDAP_DN/$LDAP_DN/g" -e "s/DOMAIN/$DOMAIN/g" $DIR_POSTFIX/main.cf > /etc/postfix/main.cf |
---|
| 10 | sed -e "s/DOMAIN/$DOMAIN/g" $DIR_POSTFIX/expresso-dominios > /etc/postfix/expresso-dominios |
---|
| 11 | sed -e "s/DOMAIN/$DOMAIN/g" $DIR_POSTFIX/transport > /etc/postfix/transport |
---|
[5871] | 12 | cp $DIR_POSTFIX/master.cf /etc/postfix/ |
---|
[8265] | 13 | sed -e "s/LDAP_DN/$LDAP_DN/g" $ARQS/scl.pl > /etc/postfix/scl.pl |
---|
| 14 | chmod a+x /etc/postfix/scl.pl |
---|
[5797] | 15 | |
---|
| 16 | postmap /etc/postfix/expresso-dominios |
---|
| 17 | postmap /etc/postfix/transport |
---|
[6173] | 18 | # Adiciona o grupo mail ao usuarios postfix |
---|
| 19 | usermod -a -G mail postfix |
---|
[5797] | 20 | } |
---|
| 21 | |
---|
| 22 | smtp_rhel () |
---|
| 23 | { |
---|
[8265] | 24 | yum -y install postfix perl-LDAP |
---|
[5797] | 25 | |
---|
| 26 | smtp $1 |
---|
| 27 | |
---|
| 28 | service postfix restart |
---|
| 29 | chkconfig postfix on |
---|
| 30 | } |
---|
| 31 | |
---|
[6261] | 32 | smtp_rhel_6 () |
---|
[5797] | 33 | { |
---|
| 34 | RHEL6="rhel/6/etc/postfix" |
---|
| 35 | smtp_rhel $RHEL6 |
---|
| 36 | } |
---|
| 37 | |
---|
| 38 | smtp_debian () |
---|
| 39 | { |
---|
[8265] | 40 | apt-get -y install postfix postfix-ldap libnet-ldap-perl |
---|
[5797] | 41 | |
---|
| 42 | smtp $1 |
---|
| 43 | |
---|
| 44 | /etc/init.d/postfix restart |
---|
| 45 | } |
---|
| 46 | |
---|
[6261] | 47 | smtp_debian_6 () |
---|
[5797] | 48 | { |
---|
| 49 | SQUEEZE="debian/squeeze/etc/postfix" |
---|
| 50 | smtp_debian $SQUEEZE |
---|
| 51 | } |
---|
[5836] | 52 | |
---|
[7503] | 53 | smtp_ubuntu_1204 () |
---|
[5836] | 54 | { |
---|
[6261] | 55 | smtp_debian_6 |
---|
[5836] | 56 | } |
---|
| 57 | |
---|
Note: See
TracBrowser
for help on using the repository browser.