Skip to content

Commit 5e743a8

Browse files
committed
Do not require moduleVersion, expect MD to contain it
1 parent a5484be commit 5e743a8

File tree

4 files changed

+4
-8
lines changed

4 files changed

+4
-8
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,17 @@ the subchart must be configured with the following minimal values:
2424
2525
```yaml filename=values.yaml
2626
moduleUrl: "http://mod-x:80"
27-
moduleVersion: 0.1.0-main #used to replace @version@ placeholder in MD
2827
moduleDescriptor: |
2928
{
30-
"id" : "mod-x-@version@",
29+
"id" : "mod-x-0.1.0",
3130
"name" : "X Okapi module"
3231
}
3332
tenants:
3433
- mytenant
3534

3635
```
36+
It's recommended that the module version in the ModuleDescriptor follows the parent chart version.
37+
3738
see [values.yaml](./chart/values.yaml) for a complete list of configuration options.
3839
3940
The parent chart is then build with:

chart/templates/_validate.tpl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@
1212
{{- if not .Values.moduleDescriptor -}}
1313
{{- fail "A valid .Values.moduleDescriptor is required!" -}}
1414
{{- end -}}
15-
{{- if not .Values.moduleVersion -}}
16-
{{- fail "A valid .Values.moduleVersion is required!" -}}
17-
{{- end -}}
1815
{{- if empty .Values.tenants -}}
1916
{{- fail "A valid .Values.tenants is required!" -}}
2017
{{- end -}}

chart/templates/moddesc-configmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ metadata:
66
{{- include "..labels" . | nindent 4 }}
77
data:
88
ModuleDescriptor: |
9-
{{ .Values.moduleDescriptor | default "" | replace "@version@" .Values.moduleVersion | nindent 4 }}
9+
{{ .Values.moduleDescriptor | nindent 4 }}

chart/values.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ tenants: []
1414

1515
#REQUIRED values with defaults in the subchart, may be overridden by parent chart:
1616

17-
#Used to replace @version@ in the module descriptor, must be specified only if @version@ placeholder is used
18-
moduleVersion: "0.1.0"
1917
#Okapi base URL with scheme and port
2018
okapiUrl: "http://okapi:9130"
2119
#Okapi secret name, the secret must include OKAPI_USER/OKAPI_PASS or OKAPI_TOKEN keys

0 commit comments

Comments
 (0)