Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/workflows/integration-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ jobs:
- v1.36.1
- v1.35.5
- v1.34.8
- v1.33.12
chart:
- db-operator
- db-instances
Expand Down
2 changes: 1 addition & 1 deletion charts/db-instances/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ apiVersion: v1
appVersion: "1.0"
description: Database Instances for db operator
name: db-instances
version: 2.7.1
version: 3.0.0
2 changes: 1 addition & 1 deletion charts/db-instances/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# db-instances

![Version: 2.7.1](https://img.shields.io/badge/Version-2.7.1-informational?style=flat-square) ![AppVersion: 1.0](https://img.shields.io/badge/AppVersion-1.0-informational?style=flat-square)
![Version: 3.0.0](https://img.shields.io/badge/Version-3.0.0-informational?style=flat-square) ![AppVersion: 1.0](https://img.shields.io/badge/AppVersion-1.0-informational?style=flat-square)

Database Instances for db operator

Expand Down
6 changes: 6 additions & 0 deletions charts/db-instances/ci/ci-1-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,16 @@ dbinstances:
adminPassword: IamAdmin
instanceVars:
TEST: TEST
generic:
host: postgres-instance.databases.svc.cluster.local
port: 5432
instance2:
engine: mysql
monitoring:
enabled: true
secrets:
adminUser: adminUser
adminPassword: adminAdmin
generic:
host: mariadb-instance.databases.svc.cluster.local
port: 3306
19 changes: 19 additions & 0 deletions charts/db-instances/ci/ci-2-values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
dbinstances:
instance1:
serviceMonitor:
enabled: true
podMonitor:
enabled: true
engine: postgres
monitoring:
enabled: true
secrets:
adminUser: admin
adminPassword: IamAdmin
instanceVars:
TEST: TEST
allowedPrivileges:
- test
- test2
namespaceFilters:
- "test-*"
103 changes: 48 additions & 55 deletions charts/db-instances/templates/dbinstance.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{{- if .Values.dbinstances }}
{{- range $name, $value := .Values.dbinstances }}
---
apiVersion: "kinda.rocks/v1beta1"
apiVersion: "kinda.rocks/v1"
kind: "DbInstance"
metadata:
name: {{ $name }}
Expand All @@ -23,63 +23,56 @@ spec:
{{- end }}
engine: {{ $value.engine }}
{{- if $value.existingAdminSecret }}
adminSecretRef:
Namespace: {{ $value.existingAdminSecret.namespace }}
Name: {{ $value.existingAdminSecret.name }}
auth:
username:
valueFrom:
secret:
namespace: {{ $value.existingAdminSecret.namespace }}
name: {{ $value.existingAdminSecret.name }}
key: user
password:
valueFrom:
secret:
namespace: {{ $value.existingAdminSecret.namespace }}
name: {{ $value.existingAdminSecret.name }}
key: password
{{- else }}
adminSecretRef:
Namespace: {{ $operatorNs }}
Name: {{ $name }}-admin-secret
auth:
username:
valueFrom:
secret:
namespace: {{ $operatorNs }}
name: {{ $name }}-admin-secret
key: user
password:
valueFrom:
secret:
namespace: {{ $operatorNs }}
name: {{ $name }}-admin-secret
key: password
{{- end }}
{{- if $value.backup }}
backup:
{{ toYaml $value.backup | nindent 4 }}
{{- end }}
monitoring:
enabled: {{ $value.monitoring.enabled }}
{{- if $value.sslConnection }}
sslConnection:
enabled: {{ $value.sslConnection.enabled }}
skip-verify: {{ $value.sslConnection.skipVerify }}
{{- end }}
{{- with $value.allowExtraGrants }}
allowExtraGrants: {{ . }}
{{- end }}
{{- if $value.google }}
google:
instance: {{ $value.google.instanceName }}
configmapRef:
Namespace: {{ $operatorNs }}
Name: {{ $name }}-config
{{- if $value.google.clientSecret }}
clientSecretRef:
Namespace: {{ $operatorNs }}
Name: {{ $name }}-client-secret
{{- end }}
{{- end }}
{{- if $value.generic }}
generic:
hostFrom:
kind: ConfigMap
name: {{ $name }}-config
namespace: {{ $.Release.Namespace }}
key: host
portFrom:
kind: ConfigMap
name: {{ $name }}-config
namespace: {{ $.Release.Namespace }}
key: port
{{- if $value.generic.publicIp }}
publicIpFrom:
kind: ConfigMap
name: {{ $name }}-config
namespace: {{ $.Release.Namespace }}
key: publicIp
{{- end }}

{{- if $value.generic.backupHost }}
backupHost: {{ $value.generic.backupHost }}
endpoint:
host:
valueFrom:
configMap:
name: {{ $name }}-config
namespace: {{ $operatorNs }}
key: host
port:
valueFrom:
configMap:
name: {{ $name }}-config
namespace: {{ $operatorNs }}
key: port
{{- with $value.namespaceFilters }}
namespaceFilters:
{{- . | toYaml | nindent 4 }}
{{- end }}
{{- with $value.allowedPrivileges }}
allowedPrivileges:
- namespace: '*'
roles:
{{- . | toYaml | nindent 8 }}
{{- end }}
{{- if not $value.existingAdminSecret }}
---
Expand Down
10 changes: 5 additions & 5 deletions charts/db-operator/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
apiVersion: v2
type: application
name: db-operator
version: 3.17.0
version: 4.0.0
description: This operator lets you manage databases in a Kubernetes native way, even if they are not deployed to Kubernetes
# All supported k8s versions are in the test:
# https://github.com/db-operator/charts/blob/main/.github/workflows/integration-test.yaml
kubeVersion: ">= 1.32-prerelease"
appVersion: "2.44.0"
# https://github.com/db-operator/charts/blob/main/.github/workflows/integration-tests.yaml
kubeVersion: ">= 1.34-prerelease"
appVersion: "2.45.2"
home: https://github.com/db-operator
maintainers:
- name: Nikolai Rodionov
email: allanger@posteo.com
url: https://badhouseplants.net
url: https://allanger.xyz
sources:
- https://github.com/db-operator/db-operator
keywords:
Expand Down
6 changes: 3 additions & 3 deletions charts/db-operator/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# db-operator

![Version: 3.17.0](https://img.shields.io/badge/Version-3.17.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.44.0](https://img.shields.io/badge/AppVersion-2.44.0-informational?style=flat-square)
![Version: 4.0.0](https://img.shields.io/badge/Version-4.0.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.45.2](https://img.shields.io/badge/AppVersion-2.45.2-informational?style=flat-square)

This operator lets you manage databases in a Kubernetes native way, even if they are not deployed to Kubernetes

Expand All @@ -10,15 +10,15 @@ This operator lets you manage databases in a Kubernetes native way, even if they

| Name | Email | Url |
| ---- | ------ | --- |
| Nikolai Rodionov | <allanger@posteo.com> | <https://badhouseplants.net> |
| Nikolai Rodionov | <allanger@posteo.com> | <https://allanger.xyz> |

## Source Code

* <https://github.com/db-operator/db-operator>

## Requirements

Kubernetes: `>= 1.32-prerelease`
Kubernetes: `>= 1.34-prerelease`

## Values

Expand Down
Loading
Loading