Skip to content
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

Can't set externalClusters #424

Open
Ofirfr opened this issue Oct 25, 2024 · 1 comment
Open

Can't set externalClusters #424

Ofirfr opened this issue Oct 25, 2024 · 1 comment
Labels
chart( cluster ) Related to the cluster chart

Comments

@Ofirfr
Copy link

Ofirfr commented Oct 25, 2024

Just as title, the helm chart does not support setting externalClusters field, the field can be seen in docs:
https://cloudnative-pg.io/documentation/1.24/database_import/

@itay-grudev
Copy link
Collaborator

itay-grudev commented Oct 25, 2024

The chart is responsible for filling in the externalClusters section based on your recovery configuration. I don't want to expose it.

externalClusters:
- name: pgBaseBackupSource
connectionParameters:
host: {{ .Values.recovery.pgBaseBackup.source.host | quote }}
port: {{ .Values.recovery.pgBaseBackup.source.port | quote }}
user: {{ .Values.recovery.pgBaseBackup.source.username | quote }}
dbname: {{ .Values.recovery.pgBaseBackup.source.database | quote }}
sslmode: {{ .Values.recovery.pgBaseBackup.source.sslMode | quote }}
{{- if .Values.recovery.pgBaseBackup.source.passwordSecret.name }}
password:
name: {{ default (printf "%s-pg-basebackup-password" (include "cluster.fullname" .)) .Values.recovery.pgBaseBackup.source.passwordSecret.name }}
key: {{ .Values.recovery.pgBaseBackup.source.passwordSecret.key }}
{{- end }}
{{- if .Values.recovery.pgBaseBackup.source.sslKeySecret.name }}
sslKey:
name: {{ .Values.recovery.pgBaseBackup.source.sslKeySecret.name }}
key: {{ .Values.recovery.pgBaseBackup.source.sslKeySecret.key }}
{{- end }}
{{- if .Values.recovery.pgBaseBackup.source.sslCertSecret.name }}
sslCert:
name: {{ .Values.recovery.pgBaseBackup.source.sslCertSecret.name }}
key: {{ .Values.recovery.pgBaseBackup.source.sslCertSecret.key }}
{{- end }}
{{- if .Values.recovery.pgBaseBackup.source.sslRootCertSecret.name }}
sslRootCert:
name: {{ .Values.recovery.pgBaseBackup.source.sslRootCertSecret.name }}
key: {{ .Values.recovery.pgBaseBackup.source.sslRootCertSecret.key }}
{{- end }}
{{- else }}
recovery:
{{- with .Values.recovery.pitrTarget.time }}
recoveryTarget:
targetTime: {{ . }}
{{- end }}
{{- if eq .Values.recovery.method "backup" }}
backup:
name: {{ .Values.recovery.backupName }}
{{- else if eq .Values.recovery.method "object_store" }}
source: objectStoreRecoveryCluster
{{- end }}
externalClusters:
- name: objectStoreRecoveryCluster
barmanObjectStore:
serverName: {{ .Values.recovery.clusterName }}
{{- $d := dict "chartFullname" (include "cluster.fullname" .) "scope" .Values.recovery "secretPrefix" "recovery" -}}
{{- include "cluster.barmanObjectStoreConfig" $d | nindent 4 }}

Import is not yet supported. There is a PR that adds support for it, but I probably won't get around to merging that soon.

If you need import, for now, I would suggest you interact with the operator directly i.e. don't use the chart.

@NiccoloFei NiccoloFei added the chart( cluster ) Related to the cluster chart label Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chart( cluster ) Related to the cluster chart
Projects
None yet
Development

No branches or pull requests

3 participants