comparison smtp.conf @ 4:6c41dbb2954f

Tests: run nginx with appropriate config from test itself.
author Maxim Dounin <mdounin@mdounin.ru>
date Wed, 03 Sep 2008 23:26:29 +0400
parents
children f6bb0ffdb9b4
comparison
equal deleted inserted replaced
3:ce002b2323d3 4:6c41dbb2954f
1 # Config for smtp.t tests.
2
3 worker_processes 1;
4
5 master_process off;
6 daemon off;
7
8 events {
9 worker_connections 1024;
10 }
11
12 mail {
13 proxy_pass_error_message on;
14 auth_http http://localhost:8080/mail/auth;
15 xclient off;
16
17 server {
18 listen 10025;
19 protocol smtp;
20 smtp_auth login plain none;
21 }
22
23 server {
24 listen 10026;
25 protocol smtp;
26 smtp_greeting_delay 100ms;
27 }
28 }
29
30 http {
31 access_log off;
32
33 server {
34 listen 8080;
35 server_name localhost;
36
37 location = /mail/auth {
38 set $reply ERROR;
39
40 if ($http_auth_smtp_to ~ example.com) {
41 set $reply OK;
42 }
43 if ($http_auth_pass ~ secret) {
44 set $reply OK;
45 }
46
47 add_header Auth-Status $reply;
48 add_header Auth-Server 127.0.0.1;
49 add_header Auth-Port 25;
50 add_header Auth-Wait 1;
51 return 204;
52 }
53 }
54 }