Merge "Adds config options for using capi-helm driver"
This commit is contained in:
commit
fda0bf7ada
@ -104,4 +104,7 @@ data:
|
||||
logging.conf: {{ include "helm-toolkit.utils.to_oslo_conf" .Values.conf.logging | b64enc }}
|
||||
api-paste.ini: {{ include "helm-toolkit.utils.to_ini" .Values.conf.paste | b64enc }}
|
||||
policy.yaml: {{ toYaml .Values.conf.policy | b64enc }}
|
||||
{{- if .Values.conf.capi.enabled }}
|
||||
kubeconfig.conf: {{ include "kubeconfig.tpl" . | b64enc }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
|
@ -111,6 +111,12 @@ spec:
|
||||
mountPath: /etc/magnum/policy.yaml
|
||||
subPath: policy.yaml
|
||||
readOnly: true
|
||||
{{- if .Values.conf.capi.enabled }}
|
||||
- name: magnum-etc
|
||||
mountPath: /etc/magnum/kubeconfig.conf
|
||||
subPath: kubeconfig.conf
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
- name: magnum-lock-path
|
||||
mountPath: {{ .Values.conf.magnum.oslo_concurrency.lock_path }}
|
||||
{{ if $mounts_magnum_api.volumeMounts }}{{ toYaml $mounts_magnum_api.volumeMounts | indent 12 }}{{ end }}
|
||||
|
20
magnum/templates/kubeconfig.tpl
Normal file
20
magnum/templates/kubeconfig.tpl
Normal file
@ -0,0 +1,20 @@
|
||||
{{- define "kubeconfig.tpl" }}
|
||||
apiVersion: v1
|
||||
kind: Config
|
||||
clusters:
|
||||
- name: {{ .Values.conf.capi.clusterName }}
|
||||
cluster:
|
||||
server: {{ .Values.conf.capi.apiServer }}
|
||||
certificate-authority-data: {{ .Values.conf.capi.certificateAuthorityData | quote }}
|
||||
contexts:
|
||||
- name: {{ .Values.conf.capi.contextName }}
|
||||
context:
|
||||
cluster: {{ .Values.conf.capi.clusterName }}
|
||||
user: {{ .Values.conf.capi.userName }}
|
||||
current-context: {{ .Values.conf.capi.contextName }}
|
||||
users:
|
||||
- name: {{ .Values.conf.capi.userName }}
|
||||
user:
|
||||
client-certificate-data: {{ .Values.conf.capi.clientCertificateData | quote }}
|
||||
client-key-data: {{ .Values.conf.capi.clientKeyData | quote }}
|
||||
{{- end }}
|
@ -100,6 +100,12 @@ spec:
|
||||
subPath: {{ base .Values.conf.magnum.DEFAULT.log_config_append }}
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- if .Values.conf.capi.enabled }}
|
||||
- name: magnum-etc
|
||||
mountPath: /etc/magnum/kubeconfig.conf
|
||||
subPath: kubeconfig.conf
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
- name: magnum-etc
|
||||
mountPath: /etc/magnum/policy.yaml
|
||||
subPath: policy.yaml
|
||||
|
@ -51,6 +51,15 @@ images:
|
||||
- image_repo_sync
|
||||
|
||||
conf:
|
||||
capi:
|
||||
enabled: false
|
||||
clusterName: cluster.local
|
||||
apiServer: https://localhost:6443
|
||||
certificateAuthorityData: null
|
||||
contextName: default
|
||||
userName: clusterUse
|
||||
clientCertificateData: null
|
||||
clientKeyData: null
|
||||
paste:
|
||||
pipeline:main:
|
||||
pipeline: cors healthcheck request_id authtoken api_v1
|
||||
@ -75,6 +84,8 @@ conf:
|
||||
transport_url: null
|
||||
cluster:
|
||||
temp_cache_dir: /var/lib/magnum/certificate-cache
|
||||
capi-helm:
|
||||
kubeconfig_file: /etc/magnum/kubeconfig.conf
|
||||
oslo_messaging_notifications:
|
||||
driver: messaging
|
||||
oslo_concurrency:
|
||||
|
Loading…
x
Reference in New Issue
Block a user