Ferramentas do usuário

Ferramentas do site


postfix

Diferenças

Aqui você vê as diferenças entre duas revisões dessa página.

Link para esta página de comparações

Ambos lados da revisão anteriorRevisão anterior
Próxima revisão
Revisão anterior
postfix [2024/11/01 21:07] – [Configurações] jdospostfix [2025/01/29 17:52] (atual) – [Configurações] jdos
Linha 18: Linha 18:
  
 <code> <code>
-#para habilitar o log+See /usr/share/postfix/main.cf.dist for a commented, more complete version 
 + 
 + 
 +# Debian specific:  Specifying a file name will cause the first 
 +# line of that file to be used as the name.  The Debian default 
 +# is /etc/mailname. 
 +#myorigin = /etc/mailname 
 + 
 +smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU) 
 +biff = no 
 + 
 +# appending .domain is the MUA's job. 
 +append_dot_mydomain = no 
 + 
 +# Uncomment the next line to generate "delayed mail" warnings 
 +#delay_warning_time = 4h 
 + 
 +readme_directory = no 
 + 
 +# See http://www.postfix.org/COMPATIBILITY_README.html -- default to 3.6 on 
 +# fresh installs. 
 +compatibility_level = 3.6 
 maillog_file = /var/log/postfix.log maillog_file = /var/log/postfix.log
-#essa opção dependera da versão que está instalada, alguns servidores podem não disparar por te-la ativada/desativada 
 smtputf8_enable = no smtputf8_enable = no
-#o seu email de disparo e configurações + 
-relayhost = [mail.itti.org.br]:587 +TLS parameters 
-#clientes de confiança +smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem 
-mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128, 200.236.20.128/25, 10.150.14.200 +smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key 
-#configuração para aceitar acesso+smtpd_tls_security_level=may 
 + 
 +smtp_tls_CApath=/etc/ssl/certs 
 +smtp_tls_security_level=may 
 +smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache 
 + 
 + 
 +smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination 
 +myhostname = debian 
 +alias_maps = hash:/etc/aliases 
 +alias_database = hash:/etc/aliases 
 +myorigin = /etc/mailname 
 +mydestination = debian, digi@itti.org.br, debian, localhost.localdomain, localhost 
 + 
 +#relayhost = [mail.jdos.com.br]:587 
 +relayhost = [smtp.gmail.com]:587 
 + 
 +mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128 
 + 
 +mailbox_size_limit = 0 
 +recipient_delimiter = +
 inet_interfaces = all inet_interfaces = all
 +inet_protocols = all
 +
 +
 # outbound relay configurations # outbound relay configurations
 smtp_sasl_auth_enable = yes smtp_sasl_auth_enable = yes
Linha 40: Linha 84:
  
 ''#clientes de confiança ''#clientes de confiança
-mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128, 200.236.20.128/25, 10.150.14.200''+mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128, x.x.x.128/25, 10.150.14.200''
  
 +Crie o arquivo com ''touch /etc/postfix/sasl_passwd''
 +
 +Adicione:
 +
 +<code>[smtp.gmail.com]:587 emailgoogle@gmail.com:xxxx xxxx xxxx xxxx</code>
 +
 +A senha ''xxxx xxxx xxxx xxxx'' deverá ser gerada na sua conta do gmail [[https://support.google.com/accounts/answer/185833?hl=pt-BR|VEJA AQUI COMO]], lembrando que para desbloquear essa função deve-se criar o acesso de dupla verificação
 +
 +Execute:
 +<code>
 +sudo postmap main.cf
 +sudo postmap sasl_passwd
 +service postfix restart
 +
 +</code>
 +==== CONFIGURAÇÂO ====
 +
 +Para utilizá-lo como servidor de e-mail utilize as seguintes configurações:
 +
 +<code>
 +Gateway SMTP primário: ip do seu servidor
 +PORTA: 25
 +</code>
  
 ==== TESTES ==== ==== TESTES ====
Linha 57: Linha 124:
 ''tcp        0      0 0.0.0.0:25              0.0.0.0:              LISTEN      28211/master'' ''tcp        0      0 0.0.0.0:25              0.0.0.0:              LISTEN      28211/master''
  
 +==== RECONFIGURAÇÕES ====
 +Para reconfigurar e/ou mudar algum parametro: 
 +<code>sudo dpkg-reconfigure postfix</code>
  
 +Reload:
 + <code>sudo systemctl reload postfix</code>
  
postfix.1730506030.txt.gz · Última modificação: 2024/11/01 21:07 por jdos

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki