-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* Updated SSL Certificate approach for #14 * Fixed and simplified NGinx config and added certificate management for #14
- Loading branch information
Showing
5 changed files
with
172 additions
and
155 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,117 @@ | ||
events { | ||
worker_connections 4096; | ||
} | ||
|
||
http { | ||
fastcgi_read_timeout 1d; | ||
client_max_body_size 1024M; | ||
proxy_read_timeout 1d; | ||
|
||
ssl_certificate /etc/letsencrypt/live/moh.org.bw/fullchain.pem; | ||
ssl_certificate_key /etc/letsencrypt/live/moh.org.bw/privkey.pem; | ||
|
||
ssl_protocols TLSv1 TLSv1.1 TLSv1.2; | ||
ssl_ciphers HIGH:!aNULL:!MD5; | ||
|
||
|
||
# Redirect to use https | ||
server { | ||
listen 80 default_server; | ||
|
||
server_name _; | ||
|
||
return 301 https://$host$request_uri; | ||
} | ||
|
||
server { | ||
listen 443 ssl; | ||
server_name moh.org.bw; | ||
|
||
location / { | ||
resolver 127.0.0.11 valid=30s; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header X-Forwarded-Proto $scheme; | ||
proxy_set_header Host $http_host; | ||
proxy_redirect off; | ||
proxy_pass http://openhim-console; | ||
} | ||
} | ||
|
||
server { | ||
listen 443 ssl; | ||
server_name core.moh.org.bw; | ||
|
||
location / { | ||
resolver 127.0.0.11 valid=30s; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header X-Forwarded-Proto $scheme; | ||
proxy_set_header Host $http_host; | ||
proxy_redirect off; | ||
proxy_pass https://openhim-core:8080; | ||
} | ||
} | ||
|
||
server { | ||
listen 443 ssl; | ||
server_name openhim.moh.org.bw; | ||
|
||
location / { | ||
resolver 127.0.0.11 valid=30s; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header X-Forwarded-Proto $scheme; | ||
proxy_set_header Host $http_host; | ||
proxy_redirect off; | ||
set $upstream shr; | ||
proxy_pass https://$upstream:5000; | ||
} | ||
} | ||
|
||
|
||
# Mediators: | ||
server { | ||
listen 443 ssl; | ||
server_name shr.moh.org.bw; | ||
|
||
location / { | ||
resolver 127.0.0.11 valid=30s; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header X-Forwarded-Proto $scheme; | ||
proxy_set_header Host $http_host; | ||
proxy_redirect off; | ||
set $upstream shr; | ||
proxy_pass http://$upstream:3000; | ||
} | ||
} | ||
|
||
|
||
server { | ||
listen 443 ssl; | ||
server_name opencr.moh.org.bw; | ||
|
||
location / { | ||
resolver 127.0.0.11 valid=30s; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header X-Forwarded-Proto $scheme; | ||
proxy_set_header Host $http_host; | ||
proxy_redirect off; | ||
set $upstream opencr; | ||
proxy_pass http://$upstream:3000; | ||
} | ||
} | ||
|
||
server { | ||
listen 443 ssl; | ||
server_name hl72fhir.moh.org.bw; | ||
|
||
location / { | ||
resolver 127.0.0.11 valid=30s; | ||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | ||
proxy_set_header X-Forwarded-Proto $scheme; | ||
proxy_set_header Host $http_host; | ||
proxy_redirect off; | ||
|
||
set $upstream fhir-converter; | ||
proxy_pass http://$upstream:2019; | ||
} | ||
} | ||
} |
Empty file.
Oops, something went wrong.