Commit | Line | Data |
---|---|---|
7e3ce68e | 1 | # Exim test configuration 0900 |
e027f545 | 2 | SERVER= |
48f1c853 | 3 | X= |
e7621e83 | 4 | Y= |
48f1c853 | 5 | OPT= |
7e3ce68e JH |
6 | |
7 | exim_path = EXIM_PATH | |
8 | keep_environment = | |
9 | host_lookup_order = bydns | |
10 | spool_directory = DIR/spool | |
11 | log_file_path = DIR/spool/log/SERVER%slog | |
12 | gecos_pattern = "" | |
13 | gecos_name = CALLER_NAME | |
14 | chunking_advertise_hosts = * | |
e7621e83 | 15 | tls_advertise_hosts = ${if eq {Y}{tls} {*}} |
7e3ce68e JH |
16 | |
17 | ||
18 | # ----- Main settings ----- | |
19 | ||
48f1c853 | 20 | domainlist local_domains = @ : test.ex |
7e3ce68e JH |
21 | |
22 | acl_smtp_rcpt = check_recipient | |
23 | acl_smtp_data = check_data | |
7e3ce68e JH |
24 | trusted_users = CALLER |
25 | queue_only | |
26 | smtp_receive_timeout = 2s | |
48f1c853 | 27 | log_selector = +received_recipients |
7e3ce68e | 28 | |
e7621e83 JH |
29 | tls_certificate = ${if eq {SERVER}{server}{DIR/aux-fixed/cert1}fail} |
30 | tls_privatekey = ${if eq {SERVER}{server}{DIR/aux-fixed/cert1}fail} | |
7e3ce68e JH |
31 | |
32 | # ----- ACL ----- | |
33 | ||
34 | begin acl | |
35 | ||
36 | check_recipient: | |
37 | accept hosts = : | |
38 | accept domains = +local_domains | |
39 | deny message = relay not permitted | |
40 | ||
41 | check_data: | |
42 | warn message = X-acl-message-linecount: $message_linecount | |
43 | accept | |
44 | ||
45 | ||
46 | # ----- Routers ----- | |
47 | ||
48 | begin routers | |
49 | ||
e027f545 JH |
50 | to_server: |
51 | driver = accept | |
52 | condition = ${if !eq {SERVER}{server}} | |
48f1c853 | 53 | transport = remote_smtp${if eq {X}{dkim} {_dkim}} |
e027f545 JH |
54 | errors_to = "" |
55 | ||
7e3ce68e JH |
56 | fail_remote_domains: |
57 | driver = redirect | |
58 | domains = ! +local_domains | |
59 | data = :fail: unrouteable mail domain "$domain" | |
60 | ||
61 | localuser: | |
62 | driver = accept | |
63 | check_local_user | |
64 | transport = local_delivery | |
65 | headers_add = X-local-user: uid=$local_user_uid gid=$local_user_gid | |
66 | ||
67 | ||
68 | # ----- Transports ----- | |
69 | ||
70 | begin transports | |
71 | ||
72 | local_delivery: | |
73 | driver = appendfile | |
74 | delivery_date_add | |
75 | envelope_to_add | |
76 | file = DIR/test-mail/$local_part | |
77 | headers_add = "X-body-linecount: $body_linecount\n\ | |
78 | X-message-linecount: $message_linecount\n\ | |
79 | X-received-count: $received_count" | |
80 | return_path_add | |
81 | ||
e027f545 JH |
82 | remote_smtp: |
83 | driver = smtp | |
84 | hosts = 127.0.0.1 | |
85 | port = PORT_S | |
86 | allow_localhost | |
87 | command_timeout = 2s | |
88 | final_timeout = 2s | |
89 | ||
48f1c853 JH |
90 | remote_smtp_dkim: |
91 | driver = smtp | |
92 | hosts = 127.0.0.1 | |
93 | port = PORT_S | |
94 | allow_localhost | |
95 | command_timeout = 2s | |
96 | final_timeout = 2s | |
97 | ||
98 | dkim_domain = test.ex | |
99 | dkim_selector = sel | |
100 | dkim_private_key = DIR/aux-fixed/dkim/dkim.private | |
101 | .ifndef HEADERS_MAXSIZE | |
102 | dkim_sign_headers = OPT | |
103 | .endif | |
104 | ||
e027f545 JH |
105 | # ----- Retry ----- |
106 | ||
107 | begin retry | |
108 | * * F,30m,5m; | |
7e3ce68e | 109 | # End |