annotate Applications/Samples/nginx.local.conf @ 967:e3234630df9c toa2019082801

Removed pragma-no-cache header that seems to be useless (and even nefarious)
author Benjamin Golinvaux <bgo@osimis.io>
date Wed, 28 Aug 2019 10:54:15 +0200
parents 40bb5eb247a5
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
264
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
1 # Local config to serve the WASM samples static files and reverse proxy Orthanc.
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
2 # Uses port 9977 instead of 80.
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
3
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
4 # `events` section is mandatory
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
5 events {
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
6 worker_connections 1024; # Default: 1024
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
7 }
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
8
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
9 http {
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
10
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
11 # prevent nginx sync issues on OSX
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
12 proxy_buffering off;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
13
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
14 server {
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
15 listen 9977 default_server;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
16 client_max_body_size 4G;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
17
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
18 # location may have to be adjusted depending on your OS and nginx install
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
19 include /etc/nginx/mime.types;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
20 # if not in your system mime.types, add this line to support WASM:
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
21 # types {
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
22 # application/wasm wasm;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
23 # }
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
24
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
25 # serve WASM static files
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
26 root build-web/;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
27 location / {
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
28 }
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
29
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
30 # reverse proxy orthanc
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
31 location /orthanc/ {
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
32 rewrite /orthanc(.*) $1 break;
518
40bb5eb247a5 Reverted a couple of files to AM version (wrong changes on my end)
Benjamin Golinvaux <bgo@osimis.io>
parents: 445
diff changeset
33 proxy_pass http://127.0.0.1:8042;
264
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
34 proxy_set_header Host $http_host;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
35 proxy_set_header my-auth-header good-token;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
36 proxy_request_buffering off;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
37 proxy_max_temp_file_size 0;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
38 client_max_body_size 0;
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
39 }
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
40
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
41
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
42 }
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
43
6b98ac45aaee documented how to compile and execute WASM samples
am@osimis.io
parents:
diff changeset
44 }