Skip to content

Commit 136fdcf

Browse files
committed
Fix formatting of resource names
1 parent b7aed28 commit 136fdcf

20 files changed

+49
-47
lines changed

charts/sourcegraph/templates/cadvisor/cadvisor.ClusterRoleBinding.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ roleRef:
1313
kind: ClusterRole
1414
name: {{ .Values.cadvisor.name }}
1515
subjects:
16-
- kind: ServiceAccount
17-
name: {{ include "sourcegraph.serviceAccountName" (list . "cadvisor") }}
16+
- name: {{ include "sourcegraph.serviceAccountName" (list . "cadvisor") }}
17+
kind: ServiceAccount
1818
namespace: {{ .Release.Namespace }}
1919
{{- end }}

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

Lines changed: 3 additions & 3 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 }}
@@ -151,8 +151,8 @@ spec:
151151
{{- end }}
152152
{{- include "sourcegraph.renderServiceAccountName" (list . "frontend") | trim | nindent 6 }}
153153
volumes:
154-
- emptyDir: {}
155-
name: home-dir
154+
- name: home-dir
155+
emptyDir: {}
156156
{{- if .Values.frontend.extraVolumes }}
157157
{{- toYaml .Values.frontend.extraVolumes | nindent 6 }}
158158
{{- end }}

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ roleRef:
1919
name: view
2020
{{- end }}
2121
subjects:
22-
- kind: ServiceAccount
23-
name: {{ include "sourcegraph.serviceAccountName" (list . "frontend") }}
22+
- name: {{ include "sourcegraph.serviceAccountName" (list . "frontend") }}
23+
kind: ServiceAccount
2424
namespace: {{ .Release.Namespace }}
2525
{{- end }}

charts/sourcegraph/templates/grafana/grafana.pgsql.Secret.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
apiVersion: v1
33
kind: Secret
44
metadata:
5-
name: {{ .Values.grafana.name }}-auth
65
labels:
76
app: grafana
87
deploy: sourcegraph
98
app.kubernetes.io/component: grafana
9+
name: {{ .Values.grafana.name }}-auth
1010
type: Opaque
1111
data:
1212
database: {{ .Values.grafana.auth.database | toString | b64enc | quote }}

charts/sourcegraph/templates/jaeger/jaeger.Deployment.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
apiVersion: apps/v1
66
kind: Deployment
77
metadata:
8-
name: {{ .Values.jaeger.name }}
98
labels:
109
{{- include "sourcegraph.jaeger.labels" . | nindent 4 }}
1110
{{- if .Values.jaeger.labels }}
@@ -14,6 +13,7 @@ metadata:
1413
deploy: sourcegraph
1514
app.kubernetes.io/component: all-in-one
1615
app: jaeger
16+
name: {{ .Values.jaeger.name }}
1717
spec:
1818
replicas: {{ .Values.jaeger.replicaCount }}
1919
revisionHistoryLimit: {{ .Values.sourcegraph.revisionHistoryLimit }}

charts/sourcegraph/templates/node-exporter/node-exporter.ClusterRoleBinding.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ roleRef:
1313
kind: ClusterRole
1414
name: {{ .Values.nodeExporter.name }}
1515
subjects:
16-
- kind: ServiceAccount
17-
name: {{ include "sourcegraph.serviceAccountName" (list . "nodeExporter") }}
16+
- name: {{ include "sourcegraph.serviceAccountName" (list . "nodeExporter") }}
17+
kind: ServiceAccount
1818
namespace: {{ .Release.Namespace }}
1919
{{- end }}

charts/sourcegraph/templates/otel-collector/otel-agent.ConfigMap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# Config for the agent pods running as a DaemonSet, which forward data to the gateway pod
21
{{ if .Values.openTelemetry.enabled -}}
2+
# Config for the agent pods running as a DaemonSet, which forward data to the gateway pod
33
apiVersion: v1
44
kind: ConfigMap
55
metadata:

charts/sourcegraph/templates/otel-collector/otel-collector.Service.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
apiVersion: v1
33
kind: Service
44
metadata:
5-
name: otel-collector
65
annotations:
76
prometheus.io/port: "8888"
87
sourcegraph.prometheus/scrape: "true"
@@ -16,6 +15,7 @@ metadata:
1615
{{- end }}
1716
deploy: sourcegraph
1817
app.kubernetes.io/component: otel-collector
18+
name: otel-collector
1919
spec:
2020
ports:
2121
- name: grpc-otlp

charts/sourcegraph/templates/pgsql/pgsql.Secret.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
apiVersion: v1
33
kind: Secret
44
metadata:
5-
name: {{ .Values.pgsql.name }}-auth
65
labels:
76
app: pgsql
87
deploy: sourcegraph
98
app.kubernetes.io/component: pgsql
9+
name: {{ .Values.pgsql.name }}-auth
1010
type: Opaque
1111
data:
1212
database: {{ .Values.pgsql.auth.database | toString | b64enc | quote }}

charts/sourcegraph/templates/pgsql/pgsql.StatefulSet.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,8 @@ spec:
5858
{{- toYaml .Values.alpine.resources | nindent 10 }}
5959
{{- end }}
6060
containers:
61-
- image: {{ include "sourcegraph.image" (list . "pgsql") }}
61+
- name: pgsql
62+
image: {{ include "sourcegraph.image" (list . "pgsql") }}
6263
imagePullPolicy: {{ .Values.sourcegraph.image.pullPolicy }}
6364
{{- with .Values.pgsql.args }}
6465
args:
@@ -80,7 +81,6 @@ spec:
8081
- /liveness.sh
8182
failureThreshold: 360
8283
periodSeconds: 10
83-
name: pgsql
8484
env:
8585
{{- include "sourcegraph.databaseAuth" (list . "pgsql" "POSTGRES_") | nindent 8 }}
8686
- name: POSTGRES_DB
@@ -110,9 +110,6 @@ spec:
110110
{{- if .Values.pgsql.extraVolumeMounts }}
111111
{{- toYaml .Values.pgsql.extraVolumeMounts | nindent 8 }}
112112
{{- end }}
113-
{{- if .Values.pgsql.extraContainers }}
114-
{{- toYaml .Values.pgsql.extraContainers | nindent 6 }}
115-
{{- end }}
116113
- name: pgsql-exporter
117114
env:
118115
{{- include "sourcegraph.dataSource" (list . "pgsql" ) | nindent 8 }}
@@ -133,6 +130,9 @@ spec:
133130
securityContext:
134131
{{- toYaml .Values.postgresExporter.containerSecurityContext | nindent 10 }}
135132
terminationMessagePolicy: FallbackToLogsOnError
133+
{{- if .Values.pgsql.extraContainers }}
134+
{{- toYaml .Values.pgsql.extraContainers | nindent 6 }}
135+
{{- end }}
136136
terminationGracePeriodSeconds: 120
137137
securityContext:
138138
{{- toYaml .Values.pgsql.podSecurityContext | nindent 8 }}

0 commit comments

Comments
 (0)