From 885e9906bdc9202e62a804cc33b765c2cdc891aa Mon Sep 17 00:00:00 2001 From: mwaz Date: Wed, 23 May 2018 12:01:50 +0300 Subject: [PATCH] OCLOMRS-27 Adding Nginx Configuration --- nginx.conf | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 nginx.conf diff --git a/nginx.conf b/nginx.conf new file mode 100644 index 000000000..199dfbc5d --- /dev/null +++ b/nginx.conf @@ -0,0 +1,18 @@ + - listen: "80" + server_name: "qa.oclclient.openmrs.org" + extra_parameters: | + return 301 https://$host$request_uri; + - listen: "443 ssl" + server_name: "qa.oclclient.openmrs.org" + extra_parameters: | + access_log /var/log/nginx/oclclient_access.log; + error_log /var/log/nginx/oclclient_error.log; + ssl_certificate /etc/letsencrypt/live/narok.openmrs.org/fullchain.pem; + ssl_certificate_key /etc/letsencrypt/live/narok.openmrs.org/privkey.pem; + location ^~ /.well-known/acme-challenge/ { + root /usr/share/nginx/html; + } + location / { + proxy_pass http://127.0.0.1:8081/; + try_files $uri $uri/ /index.html; + }