-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
✨ Add deployment overrides to templates #525
base: main
Are you sure you want to change the base?
Changes from 3 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,5 +27,7 @@ spec: | |
{{- end }} | ||
{{- end }} | ||
{{- end }} | ||
{{- if hasKey (default (dict) $.Values.deploymentOverride ) "coreCondition" }} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you add a test case for this manifest? Also, isn’t this a duplicate of There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what do you mean by duplicate? templates/core.yaml has the following: and I think we should avoid this default by just adding a default values to the values.yaml file. |
||
{{ .Values.deploymentOverride.coreCondition| toYaml | nindent 2 }} | ||
{{- end }} | ||
|
||
{{- end }} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,123 @@ | ||
--- | ||
# Source: cluster-api-operator/templates/addon.yaml | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "1" | ||
"argocd.argoproj.io/sync-wave": "1" | ||
name: helm-addon-system | ||
--- | ||
# Source: cluster-api-operator/templates/core-conditions.yaml | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "1" | ||
name: capi-system | ||
--- | ||
# Source: cluster-api-operator/templates/infra-conditions.yaml | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "1" | ||
"argocd.argoproj.io/sync-wave": "1" | ||
name: capi-kubeadm-bootstrap-system | ||
--- | ||
# Source: cluster-api-operator/templates/infra-conditions.yaml | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "1" | ||
"argocd.argoproj.io/sync-wave": "1" | ||
name: capi-kubeadm-control-plane-system | ||
--- | ||
# Source: cluster-api-operator/templates/infra.yaml | ||
apiVersion: v1 | ||
kind: Namespace | ||
metadata: | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "1" | ||
"argocd.argoproj.io/sync-wave": "1" | ||
name: docker-infrastructure-system | ||
--- | ||
# Source: cluster-api-operator/templates/addon.yaml | ||
apiVersion: operator.cluster.x-k8s.io/v1alpha2 | ||
kind: AddonProvider | ||
metadata: | ||
name: helm | ||
namespace: helm-addon-system | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "2" | ||
"argocd.argoproj.io/sync-wave": "2" | ||
--- | ||
# Source: cluster-api-operator/templates/infra-conditions.yaml | ||
apiVersion: operator.cluster.x-k8s.io/v1alpha2 | ||
kind: BootstrapProvider | ||
metadata: | ||
name: kubeadm | ||
namespace: capi-kubeadm-bootstrap-system | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "2" | ||
"argocd.argoproj.io/sync-wave": "2" | ||
spec: | ||
configSecret: | ||
name: test-secret-name | ||
namespace: test-secret-namespace | ||
--- | ||
# Source: cluster-api-operator/templates/infra-conditions.yaml | ||
apiVersion: operator.cluster.x-k8s.io/v1alpha2 | ||
kind: ControlPlaneProvider | ||
metadata: | ||
name: kubeadm | ||
namespace: capi-kubeadm-control-plane-system | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "2" | ||
"argocd.argoproj.io/sync-wave": "2" | ||
spec: | ||
configSecret: | ||
name: test-secret-name | ||
namespace: test-secret-namespace | ||
--- | ||
# Source: cluster-api-operator/templates/core-conditions.yaml | ||
apiVersion: operator.cluster.x-k8s.io/v1alpha2 | ||
kind: CoreProvider | ||
metadata: | ||
name: cluster-api | ||
namespace: capi-system | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "2" | ||
spec: | ||
configSecret: | ||
name: test-secret-name | ||
namespace: test-secret-namespace | ||
--- | ||
# Source: cluster-api-operator/templates/infra.yaml | ||
apiVersion: operator.cluster.x-k8s.io/v1alpha2 | ||
kind: InfrastructureProvider | ||
metadata: | ||
name: docker | ||
namespace: docker-infrastructure-system | ||
annotations: | ||
"helm.sh/hook": "post-install" | ||
"helm.sh/hook-weight": "2" | ||
"argocd.argoproj.io/sync-wave": "2" | ||
spec: | ||
configSecret: | ||
name: test-secret-name | ||
namespace: test-secret-namespace | ||
deployment: | ||
containers: | ||
- imageUrl: test.org/cluster-api-vsphere/cluster-api-vsphere-controller:v1.10.0 | ||
name: manager |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't necessarily a deployment override, or? It allows to add custom stuff to the provider CR, which could be anything? Maybe the word 'deployment' is confusing here.
(I came here when looking for a way to add a
manifestPatches
key to the provider to set resource requests for the provider's deployment resource).