Skip to content

Commit c6db4c2

Browse files
committed
refactored openmcp template
1 parent a9a34ff commit c6db4c2

File tree

5 files changed

+5
-49
lines changed

5 files changed

+5
-49
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +0,0 @@
1-
**/config/*

docs/Templating.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,8 @@ gitRepoEnvBranch: ""
6969
### OpenMCP
7070

7171
```yaml
72-
openMCPResourcesPath: "" # The path were the fluxcd resources are lying relative to the overlays
72+
openMCPResourcesPath: "" # The path were the fluxcd resources are lying relative to the overlays (e.g. ../../../resources/openmcp)
7373
openMCPOperator:
7474
image: "" # the image of the openmcp operator to use
7575
tag: "" # the tag of the image of the openmcp operator you want to use for deployment
76-
77-
onboardingClusterKubeconfigSecretName: "" # the secret name for the onboarding cluster; must be located in the openmcp-system namespace
78-
platformClusterKubeconfigSecretName: "" # the secret name for the platform cluster; must be located in the openmcp-system namespace
7976
```
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# please fill this out

templates/openmcp/templates/overlays/kustomization.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ images:
66
- name: <openmcp/openmcp-operator>
77
newName: {{.Values.openmcpOperator.image }}
88
newTag: {{.Values.openmcpOperator.tag | default "latest"}}
9+
{{- if .Values.openmcpOperator.digest }}
10+
digest: {{ .Values.openmcpOperator.digest }}
11+
{{- end }}
912
secretGenerator:
1013
- name: openmcp-operator-config
1114
namespace: openmcp-system

templates/openmcp/templates/resources/deployment.yaml

Lines changed: 0 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -21,54 +21,22 @@ spec:
2121
args:
2222
- init
2323
- --environment=default
24-
{{- if .Values.onboardingClusterKubeconfigSecretName }}
25-
- --onboarding-cluster=/etc/secret/onboarding-cluster-kubeconfig/kubeconfig
26-
{{- end }}
27-
{{- if .Values.platformClusterKubeconfigSecretName }}
28-
- --platform-cluster=/etc/secret/platform-cluster-kubeconfig/kubeconfig
29-
{{- end }}
3024
- --config=/etc/secret/openmcp-operator-config/config
3125
volumeMounts:
3226
- mountPath: /etc/secret/openmcp-operator-config
3327
name: openmcp-operator-config
3428
readOnly: true
35-
{{- if .Values.onboardingClusterKubeconfigSecretName }}
36-
- mountPath: /etc/secret/onboarding-cluster-kubeconfig
37-
name: onboarding-cluster-kubeconfig
38-
readOnly: true
39-
{{- end }}
40-
{{- if .Values.platformClusterKubeconfigSecretName }}
41-
- mountPath: /etc/secret/platform-cluster-kubeconfig
42-
name: platform-cluster-kubeconfig
43-
readOnly: true
44-
{{- end }}
4529
containers:
4630
- name: openmcp-operator
4731
image: <openmcp/openmcp-operator>:latest
4832
args:
4933
- run
5034
- --environment=default
51-
{{- if .Values.onboardingClusterKubeconfigSecretName }}
52-
- --onboarding-cluster=/etc/secret/onboarding-cluster-kubeconfig/kubeconfig
53-
{{- end }}
54-
{{- if .Values.platformClusterKubeconfigSecretName }}
55-
- --platform-cluster=/etc/secret/platform-cluster-kubeconfig/kubeconfig
56-
{{- end }}
5735
- --config=/etc/secret/openmcp-operator-config/config
5836
volumeMounts:
5937
- mountPath: /etc/secret/openmcp-operator-config
6038
name: openmcp-operator-config
6139
readOnly: true
62-
{{- if .Values.onboardingClusterKubeconfigSecretName }}
63-
- mountPath: /etc/secret/onboarding-cluster-kubeconfig
64-
name: onboarding-cluster-kubeconfig
65-
readOnly: true
66-
{{- end }}
67-
{{- if .Values.platformClusterKubeconfigSecretName }}
68-
- mountPath: /etc/secret/platform-cluster-kubeconfig
69-
name: platform-cluster-kubeconfig
70-
readOnly: true
71-
{{- end }}
7240
resources:
7341
requests:
7442
cpu: 100m
@@ -81,15 +49,3 @@ spec:
8149
secret:
8250
defaultMode: 420
8351
secretName: openmcp-operator-config
84-
{{- if .Values.onboardingClusterKubeconfigSecretName }}
85-
- name: onboarding-cluster-kubeconfig
86-
secret:
87-
defaultMode: 420
88-
secretName: {{.Values.onboardingClusterKubeconfigSecretName}}
89-
{{- end }}
90-
{{- if .Values.platformClusterKubeconfigSecretName }}
91-
- name: platform-cluster-kubeconfig
92-
secret:
93-
defaultMode: 420
94-
secretName: {{.Values.platformClusterKubeconfigSecretName}}
95-
{{- end }}

0 commit comments

Comments
 (0)