use image only for one host
This commit is contained in:
parent
f117ecbfe5
commit
0566e85e1b
@ -29,3 +29,4 @@ non_smtpd_milters = $smtpd_milters
|
|||||||
milter_default_action = accept
|
milter_default_action = accept
|
||||||
milter_connect_macros = "i j {daemon_name} v {if_name} _"
|
milter_connect_macros = "i j {daemon_name} v {if_name} _"
|
||||||
message_size_limit = {{getenv "MESSAGESIZELIMIT"}}
|
message_size_limit = {{getenv "MESSAGESIZELIMIT"}}
|
||||||
|
sender_dependent_default_transport_maps = hash:/etc/postfix/sender-transport
|
||||||
|
@ -1,24 +1,19 @@
|
|||||||
{{range $mailhosts := split (getenv "MAILHOSTS") ";"}}
|
smtp inet n - - - - smtpd
|
||||||
{{$values := split ($mailhosts) ":"}}
|
-o myhostname={{getenv "MYDOMAIN"}}
|
||||||
{{index $values 0}}:smtp inet n - - - - smtpd
|
-o smtpd_tls_key_file=/etc/ssl/mail/privkey.pem
|
||||||
-o myhostname={{index $values 1}}
|
-o smtpd_tls_cert_file=/etc/ssl/mail/fullchain.pem
|
||||||
-o smtpd_tls_key_file=/etc/ssl/mail/{{index $values 1}}/privkey.pem
|
|
||||||
-o smtpd_tls_cert_file=/etc/ssl/mail/{{index $values 1}}//fullchain.pem
|
|
||||||
|
|
||||||
{{index $values 1}}-out unix - - - - - smtp
|
{{getenv "MYDOMAIN"}}-out unix - - - - - smtp
|
||||||
-o smtp_bind_address={{index $values 0}}
|
-o smtp_helo_name={{getenv "MYHOSTNAME"}}
|
||||||
-o smtp_helo_name={{index $values 2}}
|
|
||||||
-o syslog_name=postfix-{{index $values 2}}
|
|
||||||
|
|
||||||
{{index $values 0}}:submission inet n - - - - smtpd
|
submission inet n - - - - smtpd
|
||||||
-o syslog_name=postfix/submission
|
-o syslog_name=postfix/submission
|
||||||
-o smtpd_tls_security_level=encrypt
|
-o smtpd_tls_security_level=encrypt
|
||||||
-o smtpd_sasl_auth_enable=yes
|
-o smtpd_sasl_auth_enable=yes
|
||||||
-o smtpd_relay_restrictions=permit_mynetworks,permit_sasl_authenticated,defer_unauth_destination
|
-o smtpd_relay_restrictions=permit_mynetworks,permit_sasl_authenticated,defer_unauth_destination
|
||||||
-o milter_macro_daemon_name=ORIGINATING
|
-o milter_macro_daemon_name=ORIGINATING
|
||||||
-o smtpd_tls_key_file=/etc/ssl/mail/{{index $values 1}}/privkey.pem
|
-o smtpd_tls_key_file=/etc/ssl/mail/privkey.pem
|
||||||
-o smtpd_tls_cert_file=/etc/ssl/mail/{{index $values 1}}//fullchain.pem
|
-o smtpd_tls_cert_file=/etc/ssl/mail/fullchain.pem
|
||||||
{{end}}
|
|
||||||
|
|
||||||
smtp inet n - n - - smtpd
|
smtp inet n - n - - smtpd
|
||||||
pickup unix n - n 60 1 pickup
|
pickup unix n - n 60 1 pickup
|
||||||
|
1
rootfs/etc/confd/templates/sender-transport.tmpl
Normal file
1
rootfs/etc/confd/templates/sender-transport.tmpl
Normal file
@ -0,0 +1 @@
|
|||||||
|
@{{getenv "MYDOMAIN"}} {{getenv "MYDOMAIN"}}-out
|
3
rootfs/etc/cont-init.d/02-sender-transport
Normal file
3
rootfs/etc/cont-init.d/02-sender-transport
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
#!/usr/bin/with-contenv sh
|
||||||
|
|
||||||
|
postmap /etc/postfix/sender-transport
|
21
tmp
21
tmp
@ -1,21 +0,0 @@
|
|||||||
{{range $mailhosts := split (getenv "MAILHOSTS") ";"}}
|
|
||||||
{{$values := split ($mailhosts) ":"}}
|
|
||||||
{{index $values 0}}:smtp inet n - - - - smtpd
|
|
||||||
-o myhostname={{index $values 1}}
|
|
||||||
-o smtpd_tls_key_file=/etc/ssl/mail/{{index $values 1}}/privkey.pem
|
|
||||||
-o smtpd_tls_cert_file=/etc/ssl/mail/{{index $values 1}}//fullchain.pem
|
|
||||||
|
|
||||||
{{index $values 1}}-out unix - - - - - smtp
|
|
||||||
-o smtp_bind_address={{index $values 0}}
|
|
||||||
-o smtp_helo_name={{index $values 2}}
|
|
||||||
-o syslog_name=postfix-{{index $values 2}}
|
|
||||||
|
|
||||||
{{index $values 0}}:submission inet n - - - - smtpd
|
|
||||||
-o syslog_name=postfix/submission
|
|
||||||
-o smtpd_tls_security_level=encrypt
|
|
||||||
-o smtpd_sasl_auth_enable=yes
|
|
||||||
-o smtpd_relay_restrictions=permit_mynetworks,permit_sasl_authenticated,defer_unauth_destination
|
|
||||||
-o milter_macro_daemon_name=ORIGINATING
|
|
||||||
-o smtpd_tls_key_file=/etc/ssl/mail/{{index $values 1}}/privkey.pem
|
|
||||||
-o smtpd_tls_cert_file=/etc/ssl/mail/{{index $values 1}}//fullchain.pem
|
|
||||||
{{end}}
|
|
Loading…
Reference in New Issue
Block a user