mirror of
https://github.com/pezkuwichain/pezkuwi-telemetry.git
synced 2026-06-14 11:51:01 +00:00
Make frontend nginx conf suitable for k8s or local deployment (no need for 'old' deployment bits)
This commit is contained in:
@@ -1,48 +0,0 @@
|
||||
|
||||
##
|
||||
# You should look at the following URL's in order to grasp a solid understanding
|
||||
# of Nginx configuration files in order to fully unleash the power of Nginx.
|
||||
# http://wiki.nginx.org/Pitfalls
|
||||
# http://wiki.nginx.org/QuickStart
|
||||
# http://wiki.nginx.org/Configuration
|
||||
#
|
||||
# Generally, you will want to move this file somewhere, and start with a clean
|
||||
# file but keep this around for reference. Or just disable in sites-enabled.
|
||||
#
|
||||
# Please see /usr/share/doc/nginx-doc/examples/ for more detailed examples.
|
||||
##
|
||||
|
||||
server {
|
||||
root /usr/share/nginx/html;
|
||||
|
||||
index index.html;
|
||||
|
||||
listen 3000;
|
||||
listen [::]:3000;
|
||||
server_name telemetry.polkadot.io localhost;
|
||||
|
||||
location /feed/ {
|
||||
proxy_pass http://127.0.0.1:8000;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
limit_req zone=zone burst=5;
|
||||
}
|
||||
|
||||
location /submit/ {
|
||||
proxy_pass http://127.0.0.1:8000;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection "Upgrade";
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
limit_req zone=zone burst=5;
|
||||
}
|
||||
|
||||
location /health/ {
|
||||
proxy_pass http://127.0.0.1:8000;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
limit_req zone=zone burst=5;
|
||||
}
|
||||
}
|
||||
@@ -10,19 +10,25 @@ events {
|
||||
}
|
||||
|
||||
http {
|
||||
include /etc/nginx/mime.types;
|
||||
default_type application/octet-stream;
|
||||
include /etc/nginx/mime.types;
|
||||
|
||||
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
||||
'$status $body_bytes_sent "$http_referer" '
|
||||
'"$http_user_agent" "$http_x_forwarded_for"';
|
||||
|
||||
access_log /var/log/nginx/access.log main;
|
||||
|
||||
sendfile on;
|
||||
#tcp_nopush on;
|
||||
|
||||
keepalive_timeout 65;
|
||||
gzip on;
|
||||
include /etc/nginx/conf.d/*.conf;
|
||||
|
||||
server {
|
||||
root /usr/share/nginx/html;
|
||||
index index.html;
|
||||
listen 8000;
|
||||
listen [::]:8000;
|
||||
server_name telemetry.polkadot.io localhost;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user