Merge "Use env varialbes to replace image urls & tags"
[nonrtric.git] / test / cr / app / nginx.conf
1 user www-data;
2 worker_processes auto;
3 pid /run/nginx.pid;
4 include /etc/nginx/modules-enabled/*.conf;
5
6 events {
7     worker_connections 768;
8     # multi_accept on;
9 }
10
11 http {
12
13     ##
14     # Basic Settings
15     ##
16
17     sendfile on;
18     tcp_nopush on;
19     tcp_nodelay on;
20     keepalive_timeout 65;
21     types_hash_max_size 2048;
22     # server_tokens off;
23
24     # server_names_hash_bucket_size 64;
25     # server_name_in_redirect off;
26
27     include /etc/nginx/mime.types;
28     default_type application/octet-stream;
29
30     server { # simple reverse-proxy
31         listen      8090;
32         listen      [::]:8090;
33         listen      8091 ssl;
34         listen      [::]:8091 ssl;
35         server_name  localhost;
36         ssl_certificate     /usr/src/app/cert/cert.crt;
37         ssl_certificate_key /usr/src/app/cert/key.crt;
38         ssl_password_file   /usr/src/app/cert/pass;
39
40         # serve dynamic requests
41         location / {
42            proxy_set_header   Host                 $host;
43            proxy_set_header   X-Real-IP            $remote_addr;
44            proxy_set_header   X-Forwarded-For      $proxy_add_x_forwarded_for;
45            proxy_pass      http://localhost:2222;
46         }
47     }
48     ##
49     # SSL Settings
50     ##
51
52     ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE
53     ssl_prefer_server_ciphers on;
54
55     ##
56     # Logging Settings
57     ##
58
59     access_log /var/log/nginx/access.log;
60     error_log /var/log/nginx/error.log;
61
62     ##
63     # Gzip Settings
64     ##
65
66     gzip on;
67
68     # gzip_vary on;
69     # gzip_proxied any;
70     # gzip_comp_level 6;
71     # gzip_buffers 16 8k;
72     # gzip_http_version 1.1;
73     # gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
74
75     ##
76     # Virtual Host Configs
77     ##
78
79     include /etc/nginx/conf.d/*.conf;
80     include /etc/nginx/sites-enabled/*;
81 }
82
83
84 #mail {
85 #       # See sample authentication script at:
86 #       # http://wiki.nginx.org/ImapAuthenticateWithApachePhpScript
87 #
88 #       # auth_http localhost/auth.php;
89 #       # pop3_capabilities "TOP" "USER";
90 #       # imap_capabilities "IMAP4rev1" "UIDPLUS";
91 #
92 #       server {
93 #               listen     localhost:110;
94 #               protocol   pop3;
95 #               proxy      on;
96 #       }
97 #
98 #       server {
99 #               listen     localhost:143;
100 #               protocol   imap;
101 #               proxy      on;
102 #       }
103 #}