_nginx.tpl 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. {{- define "nginx.workload" -}}
  2. {{- $fullname := (include "ix.v1.common.lib.chart.names.fullname" $) -}}
  3. workload:
  4. nginx:
  5. enabled: true
  6. type: Deployment
  7. podSpec:
  8. hostNetwork: false
  9. containers:
  10. nginx:
  11. enabled: true
  12. primary: true
  13. imageSelector: nginxImage
  14. securityContext:
  15. runAsUser: 0
  16. runAsGroup: 0
  17. runAsNonRoot: false
  18. readOnlyRootFilesystem: false
  19. capabilities:
  20. add:
  21. - CHOWN
  22. - SETGID
  23. - SETUID
  24. probes:
  25. liveness:
  26. enabled: true
  27. type: https
  28. path: /robots.txt
  29. port: {{ .Values.collaboraNetwork.webPort }}
  30. readiness:
  31. enabled: true
  32. type: https
  33. path: /robots.txt
  34. port: {{ .Values.collaboraNetwork.webPort }}
  35. startup:
  36. enabled: true
  37. type: https
  38. path: /robots.txt
  39. port: {{ .Values.collaboraNetwork.webPort }}
  40. initContainers:
  41. wait-collabora:
  42. enabled: true
  43. type: init
  44. imageSelector: bashImage
  45. command:
  46. - bash
  47. args:
  48. - -c
  49. - |
  50. echo "Waiting for collabora to be ready at [{{ $fullname }}:9980]"
  51. until nc -vz -w 5 "{{ $fullname }}" 9980; do
  52. echo "Waiting for collabora to be ready at [{{ $fullname }}:9980]"
  53. sleep 1
  54. done
  55. {{- end -}}