budibase/hosting/proxy/nginx.conf

78 lines
1.8 KiB
Nginx Configuration File
Raw Normal View History

2022-01-14 14:44:40 +01:00
user nginx;
error_log /var/log/nginx/error.log debug;
pid /var/run/nginx.pid;
worker_processes auto;
worker_rlimit_nofile 33282;
2022-01-11 20:33:22 +01:00
events {
2022-01-14 14:44:40 +01:00
worker_connections 1024;
2022-01-11 20:33:22 +01:00
}
http {
include /etc/nginx/mime.types;
2022-01-14 14:44:40 +01:00
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
map $http_upgrade $connection_upgrade {
default "upgrade";
}
2022-01-11 20:33:22 +01:00
server {
listen 10000 default_server;
server_name _;
2022-01-14 14:44:40 +01:00
location = / {
proxy_pass http://app-service:4002;
2022-01-11 20:33:22 +01:00
}
location = /v1/update {
proxy_pass http://watchtower-service:8080;
}
2022-01-14 14:44:40 +01:00
location /builder/ {
proxy_pass http://app-service:4002;
2022-01-11 20:33:22 +01:00
}
location /builder {
2022-01-14 14:44:40 +01:00
proxy_pass http://app-service:4002;
2022-01-11 20:33:22 +01:00
}
2022-01-14 14:44:40 +01:00
location /app_ {
proxy_pass http://app-service:4002;
2022-01-11 20:33:22 +01:00
}
2022-01-14 14:44:40 +01:00
location ~ ^/api/(system|admin|global)/ {
proxy_pass http://worker-service:4003;
2022-01-11 20:33:22 +01:00
}
location /api/ {
proxy_read_timeout 120s;
proxy_connect_timeout 120s;
proxy_send_timeout 120s;
2022-01-14 14:44:40 +01:00
proxy_pass http://app-service:4002;
2022-01-11 20:33:22 +01:00
}
location /worker/ {
2022-01-14 14:44:40 +01:00
proxy_pass http://worker-service:4003;
rewrite ^/worker/(.*)$ /$1 break;
2022-01-11 20:33:22 +01:00
}
location /db/ {
proxy_pass http://couchdb-service:5984;
2022-01-14 14:44:40 +01:00
rewrite ^/db/(.*)$ /$1 break;
2022-01-11 20:33:22 +01:00
}
location / {
proxy_pass http://minio-service:9000;
}
2022-01-14 14:44:40 +01:00
client_header_timeout 60;
client_body_timeout 60;
keepalive_timeout 60;
gzip off;
gzip_comp_level 4;
2022-01-11 20:33:22 +01:00
}
}