Skip to content

Commit 1a15eb9

Browse files
Renamed chart to paradedb-cluster (#22)
Co-authored-by: Philippe Noël <philippemnoel@gmail.com>
1 parent 06e9919 commit 1a15eb9

File tree

152 files changed

+235
-107
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

152 files changed

+235
-107
lines changed

.github/workflows/paradedb-publish-chart.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
4141
- name: Set Helm Chart Release Versions
4242
id: set_versions
43-
working-directory: charts/cluster/
43+
working-directory: charts/paradedb-cluster/
4444
env:
4545
GH_TOKEN: ${{ secrets.GHA_CREATE_RELEASE_PAT }}
4646
run: |

.github/workflows/paradedb-test-eks.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ on:
1010
pull_request:
1111
types: [opened, synchronize, reopened, ready_for_review]
1212
paths:
13-
- "charts/cluster/*"
13+
- "charts/paradedb-cluster/*"
1414
- ".github/workflows/paradedb-test-eks.yml"
1515
repository_dispatch:
1616
workflow_dispatch:
@@ -95,7 +95,7 @@ jobs:
9595
kubectl get svc -n cnpg-system cnpg-webhook-service
9696
9797
- name: Test Helm Dependency Update
98-
working-directory: charts/cluster/
98+
working-directory: charts/paradedb-cluster/
9999
run: helm dependency update . --debug
100100

101101
- name: Fetch the latest ParadeDB release tag
@@ -108,11 +108,11 @@ jobs:
108108
echo "version=$CLEANED_TAG" >> $GITHUB_OUTPUT
109109
110110
- name: Test Helm Install
111-
working-directory: charts/cluster/
111+
working-directory: charts/paradedb-cluster/
112112
run: helm install paradedb . --namespace paradedb --create-namespace --set version.paradedb=${{ steps.paradedb-version.outputs.version }} --debug
113113

114114
- name: Test Helm Upgrade
115-
working-directory: charts/cluster/
115+
working-directory: charts/paradedb-cluster/
116116
run: helm upgrade paradedb . --namespace paradedb --reuse-values --wait --debug
117117

118118
- name: Test PostgreSQL Connection

.github/workflows/tests-cluster-chainsaw.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
- 'gh-pages'
77

88
jobs:
9-
test-cluster-standalone:
9+
test-cluster-chainsaw:
1010
runs-on: ubuntu-22.04
1111
steps:
1212
- name: Checkout
@@ -15,7 +15,7 @@ jobs:
1515
fetch-depth: 0
1616

1717
- name: Set ParadeDB Version to Latest
18-
working-directory: charts/cluster/
18+
working-directory: charts/paradedb-cluster/
1919
env:
2020
GH_TOKEN: ${{ secrets.GHA_CREATE_RELEASE_PAT }}
2121
run: |

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ repos:
1616
- id: check-docstring-first
1717
- id: check-symlinks
1818
- id: check-yaml
19-
exclude: "charts/cluster/" # Exclude all files in the charts/cluster/ directory, which aren't standard YAML
19+
exclude: "charts/paradedb-cluster/" # Exclude all files in the charts/paradedb-cluster/ directory, which aren't standard YAML
2020
- id: check-json
2121
- id: check-xml
2222
- id: check-ast
@@ -41,4 +41,4 @@ repos:
4141
rev: v3.0.3
4242
hooks:
4343
- id: prettier
44-
exclude: "charts/cluster/" # Exclude all files in the charts/cluster/ directory, which aren't standard YAML
44+
exclude: "charts/paradedb-cluster/" # Exclude all files in the charts/paradedb-cluster/ directory, which aren't standard YAML

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,5 @@ docs: ## Generate charts' docs using helm-docs
1515
schema: cluster-schema ## Generate charts' schema using helm-schema-gen
1616

1717
cluster-schema:
18-
@helm schema-gen charts/cluster/values.yaml | cat > charts/cluster/values.schema.json || \
18+
@helm schema-gen charts/paradedb-cluster/values.yaml | cat > charts/paradedb-cluster/values.schema.json || \
1919
(echo "Please, run: helm plugin install https://github.com/karuppiah7890/helm-schema-gen.git" && exit 1)

README.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,20 @@ cnpg/cloudnative-pg
4848

4949
### Setting up a ParadeDB CNPG Cluster
5050

51+
Create a `values.yaml` and configure it to your requirements. Here is a basic example:
52+
53+
```yaml
54+
type: paradedb
55+
mode: standalone
56+
57+
cluster:
58+
instances: 2
59+
storage:
60+
size: 256Mi
61+
```
62+
63+
You can refer to the other examples in the [`charts/cluster/examples`](https://github.com/paradedb/charts/tree/main/charts/cluster/examples) directory.
64+
5165
```console
5266
helm repo add paradedb https://paradedb.github.io/charts
5367
helm upgrade --install paradedb \
@@ -57,7 +71,7 @@ helm upgrade --install paradedb \
5771
paradedb/cluster
5872
```
5973

60-
Refer to the [CloudNativePG Cluster Chart documentation](charts/cluster/README.md) for advanced configuration options.
74+
Refer to the [CloudNativePG Cluster Chart documentation](charts/paradedb-cluster/README.md) for advanced configuration options.
6175

6276
## License
6377

File renamed without changes.
File renamed without changes.

charts/cluster/Chart.yaml renamed to charts/paradedb-cluster/Chart.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
# limitations under the License.
1515
#
1616
apiVersion: v2
17-
name: cluster
17+
name: paradedb-cluster
1818
description: Deploys and manages a ParadeDB CloudNativePG cluster and its associated resources.
1919
icon: https://raw.githubusercontent.com/paradedb/paradedb/main/docs/logo/light.svg
2020
type: application
@@ -35,3 +35,4 @@ home: https://paradedb.com
3535
maintainers:
3636
- name: ParadeDB
3737
email: support@paradedb.com
38+
url: https://paradedb.com

charts/cluster/README.md renamed to charts/paradedb-cluster/README.md

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ cluster:
3434
3535
You can refer to the other examples in the [`charts/cluster/examples`](https://github.com/paradedb/charts/tree/main/charts/cluster/examples) directory.
3636

37-
```yaml
38-
3937
```console
4038
helm repo add paradedb https://paradedb.github.io/charts
4139
helm upgrade --install paradedb \
@@ -57,7 +55,6 @@ To use the ParadeDB Helm Chart, specify `paradedb` via the `type` parameter.
5755
### Modes of operation
5856

5957
The chart has three modes of operation. These are configured via the `mode` parameter:
60-
6158
* `standalone` - Creates new or updates an existing CNPG cluster. This is the default mode.
6259
* `replica` - Creates a replica cluster from an existing CNPG cluster. **_Note_ that this mode is not yet supported.**
6360
* `recovery` - Recovers a CNPG cluster from a backup, object store or via pg_basebackup.
@@ -74,10 +71,8 @@ providers are supported:
7471
* Google Cloud Storage
7572

7673
Additionally you can specify the following parameters:
77-
7874
* `backups.retentionPolicy` - The retention policy for backups. Defaults to `30d`.
7975
* `backups.scheduledBackups` - An array of scheduled backups containing a name and a crontab schedule. Example:
80-
8176
```yaml
8277
backups:
8378
scheduledBackups:
@@ -99,7 +94,7 @@ Examples
9994
--------
10095

10196
There are several configuration examples in the [examples](examples) directory. Refer to them for a basic setup and
102-
refer to the [CloudNativePG Documentation](https://cloudnative-pg.io/documentation/current/) for more advanced configurations.
97+
refer to the [CloudNativePG Documentation](https://cloudnative-pg.io/documentation/current/) for more advanced configurations.
10398

10499
## Values
105100

@@ -162,8 +157,8 @@ refer to the [CloudNativePG Documentation](https://cloudnative-pg.io/documentati
162157
| cluster.postgresUID | int | `-1` | The UID of the postgres user inside the image, defaults to 26 |
163158
| cluster.postgresql.parameters | object | `{}` | PostgreSQL configuration options (postgresql.conf) |
164159
| cluster.postgresql.pg_hba | list | `[]` | PostgreSQL Host Based Authentication rules (lines to be appended to the pg_hba.conf file) |
165-
| cluster.postgresql.pg_ident | list | `[]` | PostgreSQL User Name Maps rules (lines to be appended to the pg_ident.conf file) |
166-
| cluster.postgresql.shared_preload_libraries | list | `[]` | Lists of shared preload libraries to add to the default ones |
160+
| cluster.postgresql.pg_ident | list | `[]` | |
161+
| cluster.postgresql.shared_preload_libraries | list | `[]` | |
167162
| cluster.primaryUpdateMethod | string | `"switchover"` | Method to follow to upgrade the primary server during a rolling update procedure, after all replicas have been successfully updated. It can be switchover (default) or restart. |
168163
| cluster.primaryUpdateStrategy | string | `"unsupervised"` | Strategy to follow to upgrade the primary server during a rolling update procedure, after all replicas have been successfully updated: it can be automated (unsupervised - default) or manual (supervised) |
169164
| cluster.priorityClassName | string | `""` | |
@@ -234,12 +229,15 @@ refer to the [CloudNativePG Documentation](https://cloudnative-pg.io/documentati
234229
| recovery.s3.secretKey | string | `""` | |
235230
| recovery.secret.create | bool | `true` | Whether to create a secret for the backup credentials |
236231
| recovery.secret.name | string | `""` | Name of the backup credentials secret |
237-
| type | string | `"paradedb"` | Type of the CNPG database. Available types: `paradedb` |
238-
| version.paradedb | string | `"0.9.4"` | If using ParadeDB, specify the version |
232+
| type | string | `"paradedb"` | Type of the CNPG database. Available types: * `paradedb` |
233+
| version.paradedb | string | `"0.0.0"` | The ParadeDB version, set in the publish CI workflow from the latest paradedb/paradedb GitHub tag |
234+
| version.postgis | string | `"3.4"` | If using PostGIS, specify the version |
239235
| version.postgresql | string | `"16"` | PostgreSQL major version to use |
236+
| version.timescaledb | string | `"2.15"` | If using TimescaleDB, specify the version |
240237

241238
## Maintainers
242239

243240
| Name | Email | Url |
244241
| ---- | ------ | --- |
245-
| ParadeDB | <support@paradedb.com> | [paradedb.com](https://paradedb.com) |
242+
| ParadeDB | <support@paradedb.com> | <https://paradedb.com> |
243+
Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
# CloudNativePG Cluster
2+
3+
4+
{{ template "chart.deprecationWarning" . }}
5+
6+
7+
This README documents the Helm chart for deploying and managing [ParadeDB](https://github.com/paradedb/paradedb) on Kubernetes via [CloudNativePG](https://cloudnative-pg.io/), including advanced settings.
8+
9+
Kubernetes, and specifically the CloudNativePG operator, is the recommended approach for deploying ParadeDB in production. ParadeDB also provides a [Docker image](https://hub.docker.com/r/paradedb/paradedb) and [prebuilt binaries](https://github.com/paradedb/paradedb/releases) for Debian, Ubuntu and Red Hat Enterprise Linux.
10+
11+
## Getting Started
12+
13+
### Installing the Operator
14+
15+
Skip this step if the CNPG operator is already installed in your cluster.
16+
17+
```console
18+
helm repo add cnpg https://cloudnative-pg.github.io/charts
19+
helm upgrade --install cnpg \
20+
--namespace cnpg-system \
21+
--create-namespace \
22+
cnpg/cloudnative-pg
23+
```
24+
25+
### Setting up a ParadeDB CNPG Cluster
26+
27+
Create a `values.yaml` and configure it to your requirements. Here is a basic example:
28+
29+
```yaml
30+
type: paradedb
31+
mode: standalone
32+
33+
cluster:
34+
instances: 2
35+
storage:
36+
size: 256Mi
37+
```
38+
39+
You can refer to the other examples in the [`charts/cluster/examples`](https://github.com/paradedb/charts/tree/main/charts/cluster/examples) directory.
40+
41+
```console
42+
helm repo add paradedb https://paradedb.github.io/charts
43+
helm upgrade --install paradedb \
44+
--namespace paradedb-database \
45+
--create-namespace \
46+
--values values.yaml \
47+
paradedb/cluster
48+
```
49+
50+
A more detailed guide can be found in the [Getting Started docs](<./docs/Getting Started.md>).
51+
52+
Cluster Configuration
53+
---------------------
54+
55+
### Database types
56+
57+
To use the ParadeDB Helm Chart, specify `paradedb` via the `type` parameter.
58+
59+
### Modes of operation
60+
61+
The chart has three modes of operation. These are configured via the `mode` parameter:
62+
* `standalone` - Creates new or updates an existing CNPG cluster. This is the default mode.
63+
* `replica` - Creates a replica cluster from an existing CNPG cluster. **_Note_ that this mode is not yet supported.**
64+
* `recovery` - Recovers a CNPG cluster from a backup, object store or via pg_basebackup.
65+
66+
### Backup configuration
67+
68+
CNPG implements disaster recovery via [Barman](https://pgbarman.org/). The following section configures the barman object
69+
store where backups will be stored. Barman performs backups of the cluster filesystem base backup and WALs. Both are
70+
stored in the specified location. The backup provider is configured via the `backups.provider` parameter. The following
71+
providers are supported:
72+
73+
* S3 or S3-compatible stores, like MinIO
74+
* Microsoft Azure Blob Storage
75+
* Google Cloud Storage
76+
77+
Additionally you can specify the following parameters:
78+
* `backups.retentionPolicy` - The retention policy for backups. Defaults to `30d`.
79+
* `backups.scheduledBackups` - An array of scheduled backups containing a name and a crontab schedule. Example:
80+
```yaml
81+
backups:
82+
scheduledBackups:
83+
- name: daily-backup
84+
schedule: "0 0 0 * * *" # Daily at midnight
85+
backupOwnerReference: self
86+
```
87+
88+
Each backup adapter takes it's own set of parameters, listed in the [Configuration options](#Configuration-options) section
89+
below. Refer to the table for the full list of parameters and place the configuration under the appropriate key: `backup.s3`,
90+
`backup.azure`, or `backup.google`.
91+
92+
93+
Recovery
94+
--------
95+
96+
There is a separate document outlining the recovery procedure here: **[Recovery](docs/recovery.md)**
97+
98+
99+
Examples
100+
--------
101+
102+
There are several configuration examples in the [examples](examples) directory. Refer to them for a basic setup and
103+
refer to the [CloudNativePG Documentation](https://cloudnative-pg.io/documentation/current/) for more advanced configurations.
104+
105+
106+
{{ template "chart.requirementsSection" . }}
107+
108+
109+
{{ template "chart.valuesSection" . }}
110+
111+
112+
{{ template "chart.maintainersSection" . }}
113+
114+
115+
{{ template "helm-docs.versionFooter" . }}

charts/cluster/prometheus_rules/cluster-ha-critical.yaml renamed to charts/paradedb-cluster/prometheus_rules/cluster-ha-critical.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
{{- if not (has $alert .excludeRules) -}}
33
alert: {{ $alert }}
44
annotations:
5-
summary: CNPG Cluster has no standby replicas!
5+
summary: ParadeDB Cluster has no standby replicas!
66
description: |-
7-
CloudNativePG Cluster "{{ .labels.job }}" has no ready standby replicas. Your cluster at a severe
7+
ParadeDB Cluster "{{ .labels.job }}" has no ready standby replicas. Your cluster at a severe
88
risk of data loss and downtime if the primary instance fails.
99
1010
The primary instance is still online and able to serve queries, although connections to the `-ro` endpoint
@@ -15,7 +15,7 @@ annotations:
1515
1616
This alarm will be always trigger if your cluster is configured to run with only 1 instance. In this
1717
case you may want to silence it.
18-
runbook_url: https://github.com/cloudnative-pg/charts/blob/main/charts/cluster/docs/runbooks/CNPGClusterHACritical.md
18+
runbook_url: https://github.com/paradedb/charts/blob/main/charts/paradedb-cluster/docs/runbooks/CNPGClusterHACritical.md
1919
expr: |
2020
max by (job) (cnpg_pg_replication_streaming_replicas{namespace="{{ .namespace }}"} - cnpg_pg_replication_is_wal_receiver_up{namespace="{{ .namespace }}"}) < 1
2121
for: 5m

charts/cluster/prometheus_rules/cluster-ha-warning.yaml renamed to charts/paradedb-cluster/prometheus_rules/cluster-ha-warning.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
{{- if not (has $alert .excludeRules) -}}
33
alert: {{ $alert }}
44
annotations:
5-
summary: CNPG Cluster less than 2 standby replicas.
5+
summary: ParadeDB Cluster less than 2 standby replicas.
66
description: |-
7-
CloudNativePG Cluster "{{ .labels.job }}" has only {{ .value }} standby replicas, putting
7+
ParadeDB Cluster "{{ .labels.job }}" has only {{ .value }} standby replicas, putting
88
your cluster at risk if another instance fails. The cluster is still able to operate normally, although
99
the `-ro` and `-r` endpoints operate at reduced capacity.
1010
@@ -13,7 +13,7 @@ annotations:
1313
1414
This alarm will be constantly triggered if your cluster is configured to run with less than 3 instances.
1515
In this case you may want to silence it.
16-
runbook_url: https://github.com/cloudnative-pg/charts/blob/main/charts/cluster/docs/runbooks/CNPGClusterHAWarning.md
16+
runbook_url: https://github.com/paradedb/charts/blob/main/charts/paradedb-cluster/docs/runbooks/CNPGClusterHAWarning.md
1717
expr: |
1818
max by (job) (cnpg_pg_replication_streaming_replicas{namespace="{{ .namespace }}"} - cnpg_pg_replication_is_wal_receiver_up{namespace="{{ .namespace }}"}) < 2
1919
for: 5m

charts/cluster/prometheus_rules/cluster-high_connection-critical.yaml renamed to charts/paradedb-cluster/prometheus_rules/cluster-high_connection-critical.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
{{- if not (has $alert .excludeRules) -}}
33
alert: {{ $alert }}
44
annotations:
5-
summary: CNPG Instance maximum number of connections critical!
5+
summary: ParadeDB Instance maximum number of connections critical!
66
description: |-
7-
CloudNativePG Cluster "{{ .namespace }}/{{ .cluster }}" instance {{ .labels.pod }} is using {{ .value }}% of
7+
ParadeDB Cluster "{{ .namespace }}/{{ .cluster }}" instance {{ .labels.pod }} is using {{ .value }}% of
88
the maximum number of connections.
9-
runbook_url: https://github.com/cloudnative-pg/charts/blob/main/charts/cluster/docs/runbooks/CNPGClusterHighConnectionsCritical.md
9+
runbook_url: https://github.com/paradedb/charts/blob/main/charts/paradedb-cluster/docs/runbooks/CNPGClusterHighConnectionsCritical.md
1010
expr: |
1111
sum by (pod) (cnpg_backends_total{namespace="{{ .namespace }}", pod=~"{{ .podSelector }}"}) / max by (pod) (cnpg_pg_settings_setting{name="max_connections", namespace="{{ .namespace }}", pod=~"{{ .podSelector }}"}) * 100 > 95
1212
for: 5m

charts/cluster/prometheus_rules/cluster-high_connection-warning.yaml renamed to charts/paradedb-cluster/prometheus_rules/cluster-high_connection-warning.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
{{- if not (has $alert .excludeRules) -}}
33
alert: {{ $alert }}
44
annotations:
5-
summary: CNPG Instance is approaching the maximum number of connections.
5+
summary: ParadeDB Instance is approaching the maximum number of connections.
66
description: |-
7-
CloudNativePG Cluster "{{ .namespace }}/{{ .cluster }}" instance {{ .labels.pod }} is using {{ .value }}% of
7+
ParadeDB Cluster "{{ .namespace }}/{{ .cluster }}" instance {{ .labels.pod }} is using {{ .value }}% of
88
the maximum number of connections.
9-
runbook_url: https://github.com/cloudnative-pg/charts/blob/main/charts/cluster/docs/runbooks/CNPGClusterHighConnectionsWarning.md
9+
runbook_url: https://github.com/paradedb/charts/blob/main/charts/paradedb-cluster/docs/runbooks/CNPGClusterHighConnectionsWarning.md
1010
expr: |
1111
sum by (pod) (cnpg_backends_total{namespace="{{ .namespace }}", pod=~"{{ .podSelector }}"}) / max by (pod) (cnpg_pg_settings_setting{name="max_connections", namespace="{{ .namespace }}", pod=~"{{ .podSelector }}"}) * 100 > 80
1212
for: 5m

charts/cluster/prometheus_rules/cluster-high_replication_lag.yaml renamed to charts/paradedb-cluster/prometheus_rules/cluster-high_replication_lag.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
{{- if not (has $alert .excludeRules) -}}
33
alert: {{ $alert }}
44
annotations:
5-
summary: CNPG Cluster high replication lag
5+
summary: ParadeDB Cluster high replication lag
66
description: |-
7-
CloudNativePG Cluster "{{ .namespace }}/{{ .cluster }}" is experiencing a high replication lag of
7+
ParadeDB Cluster "{{ .namespace }}/{{ .cluster }}" is experiencing a high replication lag of
88
{{ .value }}ms.
99
1010
High replication lag indicates network issues, busy instances, slow queries or suboptimal configuration.
11-
runbook_url: https://github.com/cloudnative-pg/charts/blob/main/charts/cluster/docs/runbooks/CNPGClusterHighReplicationLag.md
11+
runbook_url: https://github.com/paradedb/charts/blob/main/charts/paradedb-cluster/docs/runbooks/CNPGClusterHighReplicationLag.md
1212
expr: |
1313
max(cnpg_pg_replication_lag{namespace="{{ .namespace }}",pod=~"{{ .podSelector }}"}) * 1000 > 1000
1414
for: 5m

0 commit comments

Comments
 (0)