70 lines
3.4 KiB
Plaintext
70 lines
3.4 KiB
Plaintext
This Helm chart is deprecated
|
|
|
|
Given the `stable` deprecation timeline (https://github.com/helm/charts#deprecation-timeline), the Bitnami maintained Helm chart is now located at bitnami/charts (https://github.com/bitnami/charts/).
|
|
|
|
The Bitnami repository is already included in the Hubs and we will continue providing the same cadence of updates, support, etc that we've been keeping here these years. Installation instructions are very similar, just adding the _bitnami_ repo and using it during the installation (`bitnami/<chart>` instead of `stable/<chart>`)
|
|
|
|
```bash
|
|
$ helm repo add bitnami https://charts.bitnami.com/bitnami
|
|
$ helm install my-release bitnami/<chart> # Helm 3
|
|
$ helm install --name my-release bitnami/<chart> # Helm 2
|
|
```
|
|
|
|
To update an exisiting _stable_ deployment with a chart hosted in the bitnami repository you can execute
|
|
|
|
```bash
|
|
$ helm repo add bitnami https://charts.bitnami.com/bitnami
|
|
$ helm upgrade my-release bitnami/<chart>
|
|
```
|
|
|
|
Issues and PRs related to the chart itself will be redirected to `bitnami/charts` GitHub repository. In the same way, we'll be happy to answer questions related to this migration process in this issue (https://github.com/helm/charts/issues/20969) created as a common place for discussion.
|
|
|
|
Please be patient while the chart is being deployed
|
|
|
|
Tip:
|
|
|
|
Watch the deployment status using the command: kubectl get pods -w --namespace {{ .Release.Namespace }} -l release={{ .Release.Name }}
|
|
|
|
Services:
|
|
|
|
echo Master: {{ template "mariadb.fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local:{{ .Values.service.port }}
|
|
{{- if .Values.replication.enabled }}
|
|
echo Slave: {{ template "slave.fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local:{{ .Values.service.port }}
|
|
{{- end }}
|
|
|
|
Administrator credentials:
|
|
|
|
Username: root
|
|
Password : $(kubectl get secret --namespace {{ .Release.Namespace }} {{ template "mariadb.secretName" . }} -o jsonpath="{.data.mariadb-root-password}" | base64 --decode)
|
|
|
|
To connect to your database:
|
|
|
|
1. Run a pod that you can use as a client:
|
|
|
|
kubectl run {{ template "mariadb.fullname" . }}-client --rm --tty -i --restart='Never' --image {{ template "mariadb.image" . }} --namespace {{ .Release.Namespace }} --command -- bash
|
|
|
|
2. To connect to master service (read/write):
|
|
|
|
mysql -h {{ template "mariadb.fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local -uroot -p {{ .Values.db.name }}
|
|
|
|
{{- if .Values.replication.enabled }}
|
|
|
|
3. To connect to slave service (read-only):
|
|
|
|
mysql -h {{ template "slave.fullname" . }}.{{ .Release.Namespace }}.svc.cluster.local -uroot -p {{ .Values.db.name }}
|
|
{{- end }}
|
|
|
|
To upgrade this helm chart:
|
|
|
|
1. Obtain the password as described on the 'Administrator credentials' section and set the 'rootUser.password' parameter as shown below:
|
|
|
|
ROOT_PASSWORD=$(kubectl get secret --namespace {{ .Release.Namespace }} {{ template "mariadb.secretName" . }} -o jsonpath="{.data.mariadb-root-password}" | base64 --decode)
|
|
helm upgrade {{ .Release.Name }} stable/mariadb --set rootUser.password=$ROOT_PASSWORD
|
|
|
|
{{- if and (contains "bitnami/" .Values.image.repository) (not (.Values.image.tag | toString | regexFind "-r\\d+$|sha256:")) }}
|
|
|
|
WARNING: Rolling tag detected ({{ .Values.image.repository }}:{{ .Values.image.tag }}), please note that it is strongly recommended to avoid using rolling tags in a production environment.
|
|
+info https://docs.bitnami.com/containers/how-to/understand-rolling-tags-containers/
|
|
|
|
{{- end }}
|