_netboot.tpl 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. {{- define "netboot.workload" -}}
  2. workload:
  3. netboot:
  4. enabled: true
  5. primary: true
  6. type: Deployment
  7. podSpec:
  8. hostNetwork: {{ .Values.netbootNetwork.hostNetwork }}
  9. containers:
  10. netboot:
  11. enabled: true
  12. primary: true
  13. imageSelector: image
  14. securityContext:
  15. runAsNonRoot: false
  16. runAsUser: 0
  17. runAsGroup: 0
  18. readOnlyRootFilesystem: false
  19. capabilities:
  20. add:
  21. - CHOWN
  22. - DAC_OVERRIDE
  23. - FOWNER
  24. - SETGID
  25. - SETUID
  26. - SYS_CHROOT
  27. - NET_BIND_SERVICE
  28. - KILL
  29. env:
  30. NGINX_PORT: {{ .Values.netbootNetwork.webAssetsPort }}
  31. TFTPD_OPTS: {{ join " " .Values.netbootConfig.tftpdOpts }}
  32. {{ with .Values.netbootConfig.additionalEnvs }}
  33. envList:
  34. {{ range $env := . }}
  35. - name: {{ $env.name }}
  36. value: {{ $env.value }}
  37. {{ end }}
  38. {{ end }}
  39. probes:
  40. liveness:
  41. enabled: true
  42. type: exec
  43. command:
  44. - /bin/sh
  45. - -c
  46. - |
  47. pgrep in.tftpd
  48. readiness:
  49. enabled: true
  50. type: exec
  51. command:
  52. - /bin/sh
  53. - -c
  54. - |
  55. pgrep in.tftpd
  56. startup:
  57. enabled: true
  58. type: exec
  59. command:
  60. - /bin/sh
  61. - -c
  62. - |
  63. pgrep in.tftpd
  64. {{- end -}}