From 7ef45cf0e925ae77e28057cd92aafee99c295c31 Mon Sep 17 00:00:00 2001 From: Ahree Hong Date: Thu, 30 May 2024 11:37:49 -0700 Subject: [PATCH] Allow stack.relay to be disbaled Signed-off-by: Ahree Hong --- tinkerbell/stack/templates/nginx.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tinkerbell/stack/templates/nginx.yaml b/tinkerbell/stack/templates/nginx.yaml index 9fcfa3f5..09ab4dc9 100644 --- a/tinkerbell/stack/templates/nginx.yaml +++ b/tinkerbell/stack/templates/nginx.yaml @@ -84,6 +84,7 @@ spec: - mountPath: /usr/share/nginx/html name: hook-artifacts {{- end }} + {{- if .Values.stack.relay.enabled }} - name: {{ .Values.stack.relay.name }} image: {{ .Values.stack.relay.image }} args: ["-m", "{{ .Values.stack.relay.presentGiaddrAction }}", "-c", "{{ .Values.stack.relay.maxHopCount }}", "-id", "{{ $dhcpInterfaceName }}", "-iu", "eth0", "-U", "eth0", "smee.{{ .Release.Namespace }}.svc.{{ .Values.stack.clusterDomain }}."] @@ -102,6 +103,7 @@ spec: capabilities: add: - NET_RAW + {{- end }} volumes: - name: nginx-conf configMap: @@ -115,7 +117,7 @@ spec: path: {{ .Values.stack.hook.downloadsDest }} type: DirectoryOrCreate {{- end }} - {{- if $listenBroadcast }} + {{- if and .Values.stack.relay.enabled $listenBroadcast }} initContainers: - name: relay-broadcast-interface command: