deason 1 rok temu
rodzic
commit
1ff8a7a421
1 zmienionych plików z 23 dodań i 23 usunięć
  1. 23 23
      install/nginx/exam_reserve.conf

+ 23 - 23
install/nginx/exam_reserve.conf

@@ -1,27 +1,27 @@
+server {
+    listen 8300;
+    charset utf-8;
 
-upstream exam-reserve {
-	server 127.0.0.1:8080;
-	keepalive 100;
-}
+    location ^~ / {
+        alias /home/admin/project/exam-reserve/static/admin/dist/;
+        try_files $uri $uri/ /index.html;
+    }
 
-server {
-        listen 8800;
- 
-		location / {
-            root   ../../exam-reserve/web;
-            try_files  $uri  $uri/  /index.html;
-        }
- 
-        location /file/ {
-                alias ../../exam-reserve/static/;
-                add_header Access-Control-Allow-Origin *;
-        }
- 
-        location ^~ /api/ {
-                proxy_pass http://exam-reserve;
-                proxy_set_header Host   $http_host;
-                proxy_set_header X-Real-IP $remote_addr;
-                proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
-        }
+    location ^~ /wap {
+        alias /home/admin/project/exam-reserve/static/wap/dist/;
+        try_files $uri $uri/ /wap/index.html;
+    }
+
+    location /file/ {
+        alias /home/admin/project/exam-reserve/static/file/;
+        add_header Access-Control-Allow-Origin *;
+    }
+
+    location ^~ /api/ {
+        proxy_pass http://localhost:8080;
+        proxy_set_header Host $host;
+        proxy_set_header X-Real-IP $remote_addr;
+        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+    }
 
 }