Advertisement
Guest User

Untitled

a guest
Dec 5th, 2016
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.08 KB | None | 0 0
  1. upstream xaggetweb {
  2. server localhost:30010;
  3. }
  4.  
  5. upstream kibana {
  6. server localhost:5601;
  7. }
  8.  
  9. upstream rabbitmq {
  10. server localhost:15672;
  11. }
  12.  
  13. server {
  14. listen 80;
  15.  
  16. location / {
  17. proxy_set_header Upgrade $http_upgrade;
  18. proxy_set_header Connection "upgrade";
  19. proxy_http_version 1.1;
  20. proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
  21. proxy_set_header Host $host;
  22. proxy_pass http://xaggetweb;
  23. }
  24.  
  25. location /rabbitmq/ {
  26. proxy_set_header X-Real-IP $remote_addr;
  27. proxy_set_header X-Forwarded-For $remote_addr;
  28. proxy_set_header Host $host;
  29. rewrite ^/rabbitmq/(.*) /$1 break;
  30. proxy_pass http://rabbitmq;
  31. }
  32.  
  33. location /portainer/ {
  34. rewrite ^/portainer/(.*) /$1 break;
  35. proxy_pass http://localhost:9000;
  36. }
  37.  
  38. location /kibana/ {
  39. proxy_set_header X-Real-IP $remote_addr;
  40. proxy_set_header X-Forwarded-For $remote_addr;
  41. proxy_set_header Host $host;
  42. rewrite ^/kibana/(.*) /$1 break;
  43. proxy_pass http://kibana;
  44. }
  45.  
  46.  
  47. location ~ (/app/*|/api/*|/bundles/|/status|/plugins|/elasticsearch) {
  48. proxy_http_version 1.1;
  49. proxy_set_header Upgrade $http_upgrade;
  50. proxy_set_header Connection "upgrade";
  51. proxy_set_header Host $host;
  52. proxy_pass http://kibana;
  53. rewrite ^/kibana/(.*) /$1 break;
  54. }
  55.  
  56. location /assets {
  57. alias /data/kibanaImages;
  58. }
  59.  
  60. # redirect server error pages to the static page /50x.html
  61. #
  62. error_page 500 502 503 504 /50x.html;
  63. location = /50x.html {
  64. root /usr/share/nginx/html;
  65. }
  66. }
  67.  
  68. server {
  69. listen 213.224.176.108:9200;
  70. listen 192.168.186.10:9200;
  71. #listen 0.0.0.0:9200;
  72. server_name localhost-elastic;
  73.  
  74. location / {
  75. proxy_pass http://localhost:9200;
  76. }
  77.  
  78. # redirect server error pages to the static page /50x.html
  79. #
  80. error_page 500 502 503 504 /50x.html;
  81. location = /50x.html {
  82. root /usr/share/nginx/html;
  83. }
  84. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement