-
Notifications
You must be signed in to change notification settings - Fork 891
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
helm install karmada components in order
Signed-off-by: chaosi-zju <chaosi@zju.edu.cn>
- Loading branch information
1 parent
c181917
commit 01ec281
Showing
15 changed files
with
232 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
105 changes: 105 additions & 0 deletions
105
charts/karmada/templates/karmada-static-resource-job.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,105 @@ | ||
{{- $name := include "karmada.name" . -}} | ||
{{- $namespace := include "karmada.namespace" . -}} | ||
{{- if eq .Values.installMode "host" }} | ||
apiVersion: batch/v1 | ||
kind: Job | ||
metadata: | ||
name: "{{ $name }}-static-resource" | ||
namespace: {{ $namespace }} | ||
labels: | ||
{{- include "karmada.staticResourceJob.labels" . | nindent 4 }} | ||
spec: | ||
parallelism: 1 | ||
completions: 1 | ||
template: | ||
metadata: | ||
name: {{ $name }} | ||
labels: | ||
{{- include "karmada.staticResourceJob.labels" . | nindent 8 }} | ||
spec: | ||
{{- include "karmada.imagePullSecrets" . | nindent 6 }} | ||
{{- with .Values.staticResourceJob.tolerations}} | ||
tolerations: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
{{- with .Values.staticResourceJob.nodeSelector }} | ||
nodeSelector: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
serviceAccountName: {{ $name }}-hook-job | ||
restartPolicy: Never | ||
containers: | ||
- name: post-install | ||
image: {{ template "karmada.kubectl.image" . }} | ||
imagePullPolicy: {{ .Values.kubectl.image.pullPolicy }} | ||
command: | ||
- /bin/sh | ||
- -c | ||
- | | ||
bash <<'EOF' | ||
set -ex | ||
kubectl rollout status deployment {{ $name }}-apiserver -n {{ $namespace }} | ||
kubectl apply -k /crds --kubeconfig /etc/kubeconfig | ||
kubectl apply -f /static-resources/system-namespace.yaml --kubeconfig /etc/kubeconfig | ||
kubectl apply -f /static-resources/ --kubeconfig /etc/kubeconfig | ||
EOF | ||
volumeMounts: | ||
- name: {{ $name }}-crds-kustomization | ||
mountPath: /crds | ||
- name: {{ $name }}-crds-patches | ||
mountPath: /crds/patches | ||
- name: {{ $name }}-crds-autoscaling-bases | ||
mountPath: /crds/bases/autoscaling | ||
- name: {{ $name }}-crds-config-bases | ||
mountPath: /crds/bases/config | ||
- name: {{ $name }}-crds-multicluster-bases | ||
mountPath: /crds/bases/multicluster | ||
- name: {{ $name }}-crds-networking-bases | ||
mountPath: /crds/bases/networking | ||
- name: {{ $name }}-crds-policy-bases | ||
mountPath: /crds/bases/policy | ||
- name: {{ $name }}-crds-remedy-bases | ||
mountPath: /crds/bases/remedy | ||
- name: {{ $name }}-crds-work-bases | ||
mountPath: /crds/bases/work | ||
- name: {{ $name }}-crds-apps-bases | ||
mountPath: /crds/bases/apps | ||
- name: {{ $name }}-static-resources | ||
mountPath: /static-resources | ||
{{ include "karmada.kubeconfig.volumeMount" . | nindent 10 }} | ||
volumes: | ||
- name: {{ $name }}-crds-kustomization | ||
configMap: | ||
name: {{ $name }}-crds-kustomization | ||
- name: {{ $name }}-crds-patches | ||
configMap: | ||
name: {{ $name }}-crds-patches | ||
- name: {{ $name }}-crds-autoscaling-bases | ||
configMap: | ||
name: {{ $name }}-crds-autoscaling-bases | ||
- name: {{ $name }}-crds-config-bases | ||
configMap: | ||
name: {{ $name }}-crds-config-bases | ||
- name: {{ $name }}-crds-multicluster-bases | ||
configMap: | ||
name: {{ $name }}-crds-multicluster-bases | ||
- name: {{ $name }}-crds-networking-bases | ||
configMap: | ||
name: {{ $name }}-crds-networking-bases | ||
- name: {{ $name }}-crds-policy-bases | ||
configMap: | ||
name: {{ $name }}-crds-policy-bases | ||
- name: {{ $name }}-crds-remedy-bases | ||
configMap: | ||
name: {{ $name }}-crds-remedy-bases | ||
- name: {{ $name }}-crds-work-bases | ||
configMap: | ||
name: {{ $name }}-crds-work-bases | ||
- name: {{ $name }}-crds-apps-bases | ||
configMap: | ||
name: {{ $name }}-crds-apps-bases | ||
- name: {{ $name }}-static-resources | ||
configMap: | ||
name: {{ $name }}-static-resources | ||
{{ include "karmada.kubeconfig.volume" . | nindent 8 }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.