_netboot.tpl 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  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. WEB_APP_PORT: {{ .Values.netbootNetwork.webHttpPort }}
  33. {{ with .Values.netbootConfig.additionalEnvs }}
  34. envList:
  35. {{ range $env := . }}
  36. - name: {{ $env.name }}
  37. value: {{ $env.value }}
  38. {{ end }}
  39. {{ end }}
  40. probes:
  41. liveness:
  42. enabled: true
  43. type: exec
  44. command:
  45. - /bin/sh
  46. - -c
  47. - |
  48. pgrep in.tftpd
  49. readiness:
  50. enabled: true
  51. type: exec
  52. command:
  53. - /bin/sh
  54. - -c
  55. - |
  56. pgrep in.tftpd
  57. startup:
  58. enabled: true
  59. type: exec
  60. command:
  61. - /bin/sh
  62. - -c
  63. - |
  64. pgrep in.tftpd
  65. {{- end -}}