configmap-nginx.yaml 928 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. {{- if .Values.balancer.enabled -}}
  2. apiVersion: v1
  3. kind: ConfigMap
  4. metadata:
  5. name: nginx-config
  6. data:
  7. hue: |
  8. server {
  9. server_name hue;
  10. charset utf-8;
  11. listen 80;
  12. # Or if running hue on https://
  13. ## listen 8001 ssl;
  14. ## ssl_certificate /path/to/ssl/cert;
  15. ## ssl_certificate_key /path/to/ssl/key;
  16. location / {
  17. proxy_pass http://127.0.0.1:8888;
  18. # Or if the upstream Hue instances are running behind https://
  19. ## proxy_pass https://hue;
  20. }
  21. location /static/ {
  22. alias /usr/share/nginx/html/hue/static/;
  23. expires 30d;
  24. add_header Cache-Control public;
  25. }
  26. }
  27. upstream hue {
  28. ip_hash;
  29. # List all the Hue instances here for high availability.
  30. server 127.0.0.1:8888 max_fails=3;
  31. #server HUE_HOST2:8888 max_fails=3;
  32. }
  33. {{- end -}}