fixup! fixup! fixup! Ensure that jobs run with the controller service account if no service account is specified.

This commit is contained in:
2024-12-20 10:43:16 +00:00
parent 75ab889fa2
commit 0b12097f6f
6 changed files with 23 additions and 14 deletions
+10 -7
View File
@@ -224,13 +224,16 @@ release-chart:
rm -fr ../helm-charts/charts/${CHART_NAME} || true
mkdir -p ../helm-charts/charts/${CHART_NAME}
cp -R chart/* ../helm-charts/charts/${CHART_NAME}
cd ../helm-charts/charts/${CHART_NAME}; \
cr package --config ../../chart-releaser.yaml;
cd ../helm-charts/; git add -A charts/packages; git fix; git push;
cd ../helm-charts/charts/${CHART_NAME}; cr upload --config ../../chart-releaser.yaml --skip-existing;
cd ../helm-charts/charts/${CHART_NAME}; rm -fr .cr-index; mkdir .cr-index; cr index --config ../../chart-releaser.yaml; cp .cr-index/index.yaml ../../index.yaml;
echo "index.yaml updated"
cd ../helm-charts; git fix; git push
cd ../helm-charts/charts/${CHART_NAME} && \
cr package --config ../../chart-releaser.yaml
cd ../helm-charts && git add -A charts/packages && git commit -m "Add packaged charts" && git push
cd ../helm-charts/charts/${CHART_NAME} && cr upload --config ../../chart-releaser.yaml --skip-existing
cd ../helm-charts/charts/${CHART_NAME} && \
rm -fr .cr-index || true && \
mkdir .cr-index && \
cr index --config ../../chart-releaser.yaml && \
cp .cr-index/index.yaml ../../../helm-charts/index.yaml
cd ../helm-charts && git commit -m "Update index.yaml" && git push
# go-install-tool will 'go install' any package with custom target and name of binary, if it doesn't exist
# $1 - target path with name of binary
@@ -148,6 +148,11 @@ func (in *ClusterImageExportSpec) DeepCopyInto(out *ClusterImageExportSpec) {
*out = make([]corev1.LocalObjectReference, len(*in))
copy(*out, *in)
}
if in.AdditionalImages != nil {
in, out := &in.AdditionalImages, &out.AdditionalImages
*out = make([]string, len(*in))
copy(*out, *in)
}
}
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClusterImageExportSpec.
+2 -2
View File
@@ -10,9 +10,9 @@ description: |
type: application
version: 0.2.17
version: 0.2.20
appVersion: "0.2.17"
appVersion: "0.2.20"
home: https://github.com/lukaszraczylo/kubernetes-images-sync-operator
+1 -2
View File
@@ -48,7 +48,6 @@ spec:
resources: {{- toYaml .Values.sa.manager.resources | nindent 10 }}
securityContext: {{- toYaml .Values.sa.manager.containerSecurityContext | nindent
10 }}
securityContext:
runAsNonRoot: true
securityContext: {{- toYaml .Values.sa.podSecurityContext | nindent 8 }}
serviceAccountName: {{ include "chart.fullname" . }}-sa
terminationGracePeriodSeconds: 10
+2 -2
View File
@@ -9,6 +9,6 @@ spec:
type: {{ .Values.saMetricsService.type }}
selector:
control-plane: sa
{{- include "chart.selectorLabels" . | nindent 4 }}
{{- include "chart.selectorLabels" . | nindent 4 }}
ports:
{{- .Values.saMetricsService.ports | toYaml | nindent 2 }}
{{- .Values.saMetricsService.ports | toYaml | nindent 2 }}
+3 -1
View File
@@ -12,7 +12,7 @@ sa:
- ALL
image:
repository: ghcr.io/lukaszraczylo/kubernetes-images-sync-operator
tag: 0.2.17
tag: 0.2.20
resources:
limits:
cpu: 500m
@@ -20,6 +20,8 @@ sa:
requests:
cpu: 10m
memory: 64Mi
podSecurityContext:
runAsNonRoot: true
replicas: 1
serviceAccount:
annotations: {}