inprove view of code example of nginx proxy

indent all code in example, only some was before
remove double code end
This commit is contained in:
Simon Heimberg
2020-03-27 11:04:32 +01:00
committed by GitHub
parent befe490e2c
commit a511885ac9
@@ -34,20 +34,20 @@ After installing NGINX, you need to update the NGINX configuration file, `nginx.
worker_rlimit_nofile 40000; worker_rlimit_nofile 40000;
events { events {
worker_connections 8192; worker_connections 8192;
} }
stream { stream {
upstream rancher_servers_http { upstream rancher_servers_http {
least_conn; least_conn;
server <IP_NODE_1>:80 max_fails=3 fail_timeout=5s; server <IP_NODE_1>:80 max_fails=3 fail_timeout=5s;
server <IP_NODE_2>:80 max_fails=3 fail_timeout=5s; server <IP_NODE_2>:80 max_fails=3 fail_timeout=5s;
server <IP_NODE_3>:80 max_fails=3 fail_timeout=5s; server <IP_NODE_3>:80 max_fails=3 fail_timeout=5s;
} }
server { server {
listen 80; listen 80;
proxy_pass rancher_servers_http; proxy_pass rancher_servers_http;
} }
upstream rancher_servers_https { upstream rancher_servers_https {
least_conn; least_conn;
@@ -61,10 +61,8 @@ After installing NGINX, you need to update the NGINX configuration file, `nginx.
} }
} }
``` ```
```
3. Save `nginx.conf` to your load balancer at the following path: `/etc/nginx/nginx.conf`. 3. Save `nginx.conf` to your load balancer at the following path: `/etc/nginx/nginx.conf`.