Nettoyage et construction micro services
This commit is contained in:
+13
-2
@@ -1,14 +1,25 @@
|
||||
map $uri $caria_backend {
|
||||
default telemetry:8080;
|
||||
/api/weather weather:8080;
|
||||
/api/map-config navigation:8080;
|
||||
/api/search navigation:8080;
|
||||
/api/route navigation:8080;
|
||||
}
|
||||
server {
|
||||
listen 80;
|
||||
server_name _;
|
||||
root /usr/share/nginx/html;
|
||||
index index.html;
|
||||
add_header X-Content-Type-Options nosniff;
|
||||
gzip on;
|
||||
gzip_vary on;
|
||||
gzip_comp_level 4;
|
||||
gzip_min_length 1024;
|
||||
gzip_types text/css text/javascript application/javascript application/json image/svg+xml;
|
||||
location /api/ {
|
||||
access_log off;
|
||||
resolver 127.0.0.11 valid=10s ipv6=off;
|
||||
set $backend http://telemetry:8080;
|
||||
proxy_pass $backend;
|
||||
proxy_pass http://$caria_backend;
|
||||
proxy_connect_timeout 2s;
|
||||
proxy_read_timeout 12s;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user