Skip to content

Commit 40f9be9

Browse files
committed
Remove extra blank lines, witout overchomping
1 parent b21c000 commit 40f9be9

File tree

5 files changed

+7
-5
lines changed

5 files changed

+7
-5
lines changed

charts/sourcegraph/templates/_helpers.tpl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,9 @@ and defining the REDIS_CACHE_ENDPOINT and REDIS_STORE_ENDPOINT env vars on front
278278
{{- if .Values.redisCache.connection.endpoint -}}
279279
- name: REDIS_CACHE_ENDPOINT
280280
value: {{ .Values.redisCache.connection.endpoint }}
281+
{{- if .Values.redisStore.connection.endpoint }} {{/*Add whitespace only if both are defined*/}}
281282
{{ end -}}
283+
{{- end -}}
282284
{{- if .Values.redisStore.connection.endpoint -}}
283285
- name: REDIS_STORE_ENDPOINT
284286
value: {{ .Values.redisStore.connection.endpoint }}

charts/sourcegraph/templates/_worker.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ spec:
6666
containers:
6767
- name: worker
6868
env:
69-
{{- include "sourcegraph.redisConnection" $top | nindent 8 }}
69+
{{- with include "sourcegraph.redisConnection" $top | trim }}{{ . | nindent 8 }}{{- end }}
7070
{{- if $allowlist }}
7171
- name: WORKER_JOB_ALLOWLIST
7272
value: {{ $allowlist }}

charts/sourcegraph/templates/frontend/sourcegraph-frontend.Deployment.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ spec:
6565
{{- range $name, $item := .Values.migrator.env }}
6666
- name: {{ $name }}
6767
{{- $item | toYaml | nindent 10 }}
68-
{{- end }}
68+
{{- end }}
6969
{{- if not .Values.sourcegraph.localDevMode}}
7070
resources:
7171
{{- toYaml .Values.migrator.resources | nindent 10 }}
@@ -95,7 +95,7 @@ spec:
9595
- name: {{ $name }}
9696
{{- $item | toYaml | nindent 10 }}
9797
{{- end }}
98-
{{- include "sourcegraph.redisConnection" .| nindent 8 }}
98+
{{- with include "sourcegraph.redisConnection" . | trim }}{{ . | nindent 8 }}{{- end }}
9999
{{- include "sourcegraph.openTelemetryEnv" . | nindent 8 }}
100100
{{- if .Values.blobstore.enabled }}
101101
- name: PRECISE_CODE_INTEL_UPLOAD_BACKEND

charts/sourcegraph/templates/gitserver/gitserver.StatefulSet.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ spec:
4949
image: {{ include "sourcegraph.image" (list . "gitserver") }}
5050
imagePullPolicy: {{ .Values.sourcegraph.image.pullPolicy }}
5151
env:
52-
{{- include "sourcegraph.redisConnection" .| nindent 8 }}
52+
{{- with include "sourcegraph.redisConnection" . | trim }}{{ . | nindent 8 }}{{- end }}
5353
{{- range $name, $item := .Values.gitserver.env}}
5454
- name: {{ $name }}
5555
{{- $item | toYaml | nindent 10 }}

charts/sourcegraph/templates/searcher/searcher.StatefulSet.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ spec:
5050
{{- toYaml . | nindent 8 }}
5151
{{- end }}
5252
env:
53-
{{- include "sourcegraph.redisConnection" . | nindent 8 }}
53+
{{- with include "sourcegraph.redisConnection" . | trim }}{{ . | nindent 8 }}{{- end }}
5454
{{- range $name, $item := .Values.searcher.env }}
5555
- name: {{ $name }}
5656
{{- $item | toYaml | nindent 10 }}

0 commit comments

Comments
 (0)