bvplan/config/nginx/nginx.conf

74 lines
1.9 KiB
Nginx Configuration File
Raw Normal View History

2022-12-12 16:54:07 +00:00
events {
worker_connections 1024;
}
http {
2022-12-20 18:00:12 +00:00
include /etc/nginx/mime.types;
default_type application/octet-stream;
sendfile on;
tcp_nopush on;
2022-12-12 16:54:07 +00:00
server_tokens off;
more_clear_headers Server;
server {
2022-12-20 18:00:12 +00:00
listen 80;
2022-12-12 16:54:07 +00:00
2023-03-09 14:15:48 +00:00
location = /robots.txt {
add_header Content-Type text/plain;
return 200 "User-agent: *\nDisallow: /\n";
}
2023-02-27 10:09:16 +00:00
location / {
proxy_pass http://web;
2022-12-12 16:54:07 +00:00
proxy_buffering off;
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;
proxy_set_header X-Forwarded-Proto $scheme;
}
2023-02-22 17:02:10 +00:00
}
server {
listen 8080;
2022-12-12 16:54:07 +00:00
location /adminer {
proxy_pass http://adminer:8080/;
proxy_buffering off;
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;
proxy_set_header X-Forwarded-Proto $scheme;
}
2023-02-27 10:09:16 +00:00
location /redis {
proxy_pass http://redis-commander:8081;
proxy_buffering off;
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;
proxy_set_header X-Forwarded-Proto $scheme;
}
location ~* /rabbitmq/api/(.*?)/(.*) {
proxy_pass http://rabbitmq:15672/api/$1/%2F/$2?$query_string;
proxy_buffering off;
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;
proxy_set_header X-Forwarded-Proto $scheme;
}
location ~* /rabbitmq/(.*) {
rewrite ^/rabbitmq/(.*)$ /$1 break;
proxy_pass http://rabbitmq:15672;
proxy_buffering off;
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;
proxy_set_header X-Forwarded-Proto $scheme;
}
2022-12-12 16:54:07 +00:00
}
}