Merge "Remove sleep from DmaapMessageConsumer"
[nonrtric.git] / test / mrstub / nginx_wsgi_flask / app / nginx.conf
1 #  ============LICENSE_START===============================================
2 #  Copyright (C) 2020 Nordix Foundation. All rights reserved.
3 #  ========================================================================
4 #  Licensed under the Apache License, Version 2.0 (the "License");
5 #  you may not use this file except in compliance with the License.
6 #  You may obtain a copy of the License at
7 #
8 #       http://www.apache.org/licenses/LICENSE-2.0
9 #
10 #  Unless required by applicable law or agreed to in writing, software
11 #  distributed under the License is distributed on an "AS IS" BASIS,
12 #  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 #  See the License for the specific language governing permissions and
14 #  limitations under the License.
15 #  ============LICENSE_END=================================================
16 #
17
18 user  nginx;
19 worker_processes 1;
20 error_log  /var/log/nginx/error.log warn;
21 pid        /var/run/nginx.pid;
22 events {
23   worker_connections 1024;
24 }
25 http {
26   ssl_password_file /etc/ssl/private/pass;
27   include /etc/nginx/mime.types;
28   default_type  application/octet-stream;
29   log_format  main  '$remote_addr - $remote_user [$time_local] "$request" '
30   '$status $body_bytes_sent "$http_referer" '
31   '"$http_user_agent" "$http_x_forwarded_for"';
32   access_log  /var/log/nginx/access.log  main;
33   sendfile        on;
34   keepalive_timeout  65;
35   include /etc/nginx/conf.d/*.conf;
36
37   server {
38     listen 80 ;
39     listen [::]:80;
40     listen 443 ssl ;
41     listen [::]:443 ssl;
42     server_name  localhost;
43     ssl_certificate /etc/ssl/private/cert.crt;
44     ssl_certificate_key /etc/ssl/private/key.crt;
45
46     location / {
47       try_files $uri @app;
48     }
49     location @app {
50       include uwsgi_params;
51       uwsgi_pass unix:///tmp/uwsgi.sock;
52     }
53     location /static {
54       alias /app/static;
55     }
56   }
57 }
58 daemon off;