Skip to content
This repository was archived by the owner on Oct 14, 2020. It is now read-only.

Commit 3478df6

Browse files
committed
Automatically use Chart Version to pull the correct operator version
1 parent 37c17c7 commit 3478df6

File tree

3 files changed

+10
-26
lines changed

3 files changed

+10
-26
lines changed

operator/Chart.yaml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,8 @@ description: secureCodeBox Operator to automate the execution of security scans
44

55
type: application
66

7-
# This is the chart version. This version number should be incremented each time you make changes
8-
# to the chart and its templates, including the app version.
9-
version: 0.2.0
10-
11-
# This is the version number of the application being deployed. This version number should be
12-
# incremented each time you make changes to the application.
13-
appVersion: 1.18.0
7+
# version - gets automatically set to the secureCodeBox release version when the helm charts gets published
8+
version: v2.0.0-alpha1
149

1510
dependencies:
1611
- name: minio

operator/templates/manager/manager.yaml

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,7 @@ spec:
2020
- /manager
2121
args:
2222
- --enable-leader-election
23-
{{- if .Values.image.digest }}
24-
image: "{{ .Values.image.registry }}/{{ .Values.image.repository }}@{{ .Values.image.digest }}"
25-
{{- else }}
26-
image: "{{ .Values.image.registry }}/{{ .Values.image.repository }}:{{ .Values.image.tag }}"
27-
{{- end }}
23+
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.Version }}"
2824
imagePullPolicy: {{ .Values.image.pullPolicy }}
2925
name: manager
3026
env:
@@ -74,14 +70,9 @@ spec:
7470
secretKeyRef:
7571
name: {{ .Values.s3.keySecret }}
7672
key: secretkey
77-
{{- end }}
78-
{{- if .Values.lurcher.image.digest }}
79-
- name: LURCHER_IMAGE
80-
value: "{{ .Values.lurcher.image.registry }}/{{ .Values.lurcher.image.repository }}@{{ .Values.lurcher.image.digest }}"
81-
{{- else }}
73+
{{- end }}
8274
- name: LURCHER_IMAGE
83-
value: "{{ .Values.lurcher.image.registry }}/{{ .Values.lurcher.image.repository }}:{{ .Values.lurcher.image.tag }}"
84-
{{- end }}
75+
value: "{{ .Values.lurcher.image.repository }}:{{ .Values.lurcher.image.tag | default .Chart.Version }}"
8576
- name: LURCHER_PULL_POLICY
8677
value: {{ .Values.lurcher.image.pullPolicy }}
8778
resources:

operator/values.yaml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,16 @@
66
telemetryEnabled: true
77

88
image:
9-
registry: docker.io
10-
repository: scbexperimental/operator
11-
tag: latest
12-
digest: null
9+
repository: docker.io/scbexperimental/operator
10+
# image.tag -- defaults to the charts version
11+
tag: null
1312
pullPolicy: Always
1413

1514
lurcher:
1615
image:
17-
registry: docker.io
18-
repository: scbexperimental/lurcher
16+
repository: docker.io/scbexperimental/lurcher
17+
# lurcher.image.tag -- defaults to the charts version
1918
tag: null
20-
digest: "sha256:0e9f18f85809fb8c042543657d340949db14e81fc727bf9fab4421befd317850"
2119
pullPolicy: IfNotPresent
2220

2321
minio:

0 commit comments

Comments
 (0)