Spaces:
Paused
Paused
fix
Browse files- README.md +1 -1
- nginx.conf +21 -19
README.md
CHANGED
|
@@ -5,7 +5,7 @@ colorFrom: purple
|
|
| 5 |
colorTo: purple
|
| 6 |
sdk: docker
|
| 7 |
pinned: false
|
| 8 |
-
app_port:
|
| 9 |
---
|
| 10 |
|
| 11 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
| 5 |
colorTo: purple
|
| 6 |
sdk: docker
|
| 7 |
pinned: false
|
| 8 |
+
app_port: 44444
|
| 9 |
---
|
| 10 |
|
| 11 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
nginx.conf
CHANGED
|
@@ -1,20 +1,7 @@
|
|
| 1 |
server {
|
| 2 |
listen 4444 default_server;
|
| 3 |
server_name _;
|
| 4 |
-
location / {
|
| 5 |
-
root /usr/share/nginx/html;
|
| 6 |
-
index index.html index.htm;
|
| 7 |
-
try_files $uri $uri/ /index.html;
|
| 8 |
-
add_header Cross-Origin-Opener-Policy same-origin;
|
| 9 |
-
add_header Cross-Origin-Embedder-Policy require-corp;
|
| 10 |
-
add_header Cross-Origin-Resource-Policy cross-origin;
|
| 11 |
-
proxy_set_header Host $host;
|
| 12 |
-
proxy_set_header X-Real-IP $remote_addr;
|
| 13 |
-
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
| 14 |
-
proxy_set_header X-Forwarded-Proto $http_x_forwarded_proto;
|
| 15 |
-
}
|
| 16 |
|
| 17 |
-
|
| 18 |
# location / {
|
| 19 |
# # Proxy pass to the app at /ohif
|
| 20 |
# proxy_pass http://0.0.0.0:8000/ohif/;
|
|
@@ -31,9 +18,10 @@ server {
|
|
| 31 |
# # Handling URI
|
| 32 |
# proxy_set_header X-Forwarded-Prefix "/";
|
| 33 |
# }
|
| 34 |
-
location /
|
| 35 |
-
# Proxy pass to the app at /
|
| 36 |
-
|
|
|
|
| 37 |
proxy_http_version 1.1;
|
| 38 |
proxy_set_header Upgrade $http_upgrade;
|
| 39 |
proxy_set_header Connection 'upgrade';
|
|
@@ -43,11 +31,13 @@ server {
|
|
| 43 |
proxy_cache_bypass $http_upgrade;
|
| 44 |
proxy_read_timeout 86400;
|
| 45 |
proxy_redirect off;
|
|
|
|
|
|
|
|
|
|
| 46 |
}
|
| 47 |
location /orthanc {
|
| 48 |
-
#
|
| 49 |
-
proxy_pass http://0.0.0.0:8042
|
| 50 |
-
rewrite /orthanc(.*) $1 break;
|
| 51 |
proxy_http_version 1.1;
|
| 52 |
proxy_set_header Upgrade $http_upgrade;
|
| 53 |
proxy_set_header Connection 'upgrade';
|
|
@@ -61,4 +51,16 @@ server {
|
|
| 61 |
proxy_max_temp_file_size 0;
|
| 62 |
client_max_body_size 0;
|
| 63 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 64 |
}
|
|
|
|
| 1 |
server {
|
| 2 |
listen 4444 default_server;
|
| 3 |
server_name _;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 4 |
|
|
|
|
| 5 |
# location / {
|
| 6 |
# # Proxy pass to the app at /ohif
|
| 7 |
# proxy_pass http://0.0.0.0:8000/ohif/;
|
|
|
|
| 18 |
# # Handling URI
|
| 19 |
# proxy_set_header X-Forwarded-Prefix "/";
|
| 20 |
# }
|
| 21 |
+
location /ms {
|
| 22 |
+
# Proxy pass to the app at /
|
| 23 |
+
rewrite ^/ms/(.*)$ /$1 break;
|
| 24 |
+
proxy_pass http://0.0.0.0:8000/;
|
| 25 |
proxy_http_version 1.1;
|
| 26 |
proxy_set_header Upgrade $http_upgrade;
|
| 27 |
proxy_set_header Connection 'upgrade';
|
|
|
|
| 31 |
proxy_cache_bypass $http_upgrade;
|
| 32 |
proxy_read_timeout 86400;
|
| 33 |
proxy_redirect off;
|
| 34 |
+
proxy_request_buffering off;
|
| 35 |
+
proxy_max_temp_file_size 0;
|
| 36 |
+
client_max_body_size 0;
|
| 37 |
}
|
| 38 |
location /orthanc {
|
| 39 |
+
# Proxy pass to the backend at http://0.0.0.0:8042
|
| 40 |
+
proxy_pass http://0.0.0.0:8042/;
|
|
|
|
| 41 |
proxy_http_version 1.1;
|
| 42 |
proxy_set_header Upgrade $http_upgrade;
|
| 43 |
proxy_set_header Connection 'upgrade';
|
|
|
|
| 51 |
proxy_max_temp_file_size 0;
|
| 52 |
client_max_body_size 0;
|
| 53 |
}
|
| 54 |
+
location / {
|
| 55 |
+
root /usr/share/nginx/html;
|
| 56 |
+
index index.html index.htm;
|
| 57 |
+
try_files $uri $uri/ /index.html;
|
| 58 |
+
add_header Cross-Origin-Opener-Policy same-origin;
|
| 59 |
+
add_header Cross-Origin-Embedder-Policy require-corp;
|
| 60 |
+
add_header Cross-Origin-Resource-Policy cross-origin;
|
| 61 |
+
proxy_set_header Host $host;
|
| 62 |
+
proxy_set_header X-Real-IP $remote_addr;
|
| 63 |
+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
| 64 |
+
proxy_set_header X-Forwarded-Proto $http_x_forwarded_proto;
|
| 65 |
+
}
|
| 66 |
}
|