Skip to content

Commit

Permalink
feat: Add more greptimedb-cluster helm chart values configuration (#1501
Browse files Browse the repository at this point in the history
)
  • Loading branch information
daviderli614 authored Feb 7, 2025
1 parent bb59d9d commit 3e5c715
Show file tree
Hide file tree
Showing 4 changed files with 496 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ image:
# -- The image repository
repository: greptime/greptimedb
# -- The image tag
tag: "v0.11.0"
tag: "v0.11.3"
# -- The image pull secrets
pullSecrets: []
```
Expand All @@ -40,7 +40,7 @@ image:
# -- The image repository
repository: greptime/greptimedb
# -- The image tag
tag: "v0.11.0"
tag: "v0.11.3"
# -- The image pull secrets
pullSecrets: []
Expand Down Expand Up @@ -78,7 +78,7 @@ datanode:
dataHome: "/data/greptimedb"
```

- `storageClassName`: Configures the StorageClass, defaults to Kubernetes' current default StorageClass
- `storageClassName`: Configures the StorageClass, defaults to Kubernetes current default StorageClass
- `storageSize`: Configures the storage size, default `10Gi`. You can use common capacity units, such as `10Gi`, `10GB`, etc.
- `storageRetainPolicy`: Configures the storage retention policy, default `Retain`. If set to `Delete`, the storage will be deleted when the cluster is deleted
- `dataHome`: Configures the data directory, default `/data/greptimedb/`
Expand Down Expand Up @@ -201,7 +201,7 @@ The Helm Chart does not enable User Provider mode authentication by default. You
auth:
enabled: true
users:
- name: admin
- name: "admin"
password: "admin"
```

Expand Down Expand Up @@ -298,7 +298,7 @@ Other fields of `flownode` are configured similarly to other Roles, for example:

```yaml
flownode:
enabled: false
enabled: true
replicas: 1
podTemplate:
main:
Expand All @@ -310,3 +310,123 @@ flownode:
memory: "2Gi"
cpu: "2"
```

### Object Storage Configuration

The `objectStorage` field is used to configure cloud object storage (such as AWS S3 and Azure Blob Storage, etc.) as the GreptimeDB storage layer.

#### AWS S3

```yaml
objectStorage:
credentials:
# AWS access key ID
accessKeyId: ""
# AWS secret access key
secretAccessKey: ""
s3:
# AWS S3 bucket name
bucket: ""
# AWS S3 region
region: ""
# The root path in bucket is 's3://<bucket>/<root>/data/...'
root: ""
# The AWS S3 endpoint, see more detail: https://docs.aws.amazon.com/general/latest/gr/s3.html
endpoint: ""
```

#### Google Cloud Storage

```yaml
objectStorage:
credentials:
# GCP serviceAccountKey JSON-formatted base64 value
serviceAccountKey: ""
gcs:
# Google Cloud Storage bucket name
bucket: ""
# Google Cloud OAuth 2.0 Scopes, example: "https://www.googleapis.com/auth/devstorage.read_write"
scope: ""
# The root path in bucket is 'gcs://<bucket>/<root>/data/...'
root: ""
# Google Cloud Storage endpoint, example: "https://storage.googleapis.com"
endpoint: ""
```

#### Azure Blob

```yaml
objectStorage:
credentials:
# Azure account name
accountName: ""
# Azure account key
accountKey: ""
azblob:
# Azure Blob container name
container: ""
# The root path in container is 'blob://<bucket>/<root>/data/...'
root: ""
# Azure Blob endpoint, see: "https://learn.microsoft.com/en-us/azure/storage/blobs/storage-blob-query-endpoint-srp?tabs=dotnet#query-for-the-blob-storage-endpoint"
endpoint: ""
```

#### AliCloud OSS

```yaml
objectStorage:
credentials:
# AliCloud access key ID
accessKeyId: ""
# AliCloud access key secret
secretAccessKey: ""
oss:
# AliCloud OSS bucket name
bucket: ""
# AliCloud OSS region
region: ""
# The root path in bucket is 'oss://<bucket>/<root>/data/...'
root: ""
# The AliCloud OSS endpoint
endpoint: ""
```

### Prometheus Monitor Configuration

If you have [prometheus-operator](https://github.com/prometheus-operator/prometheus-operator) installed, you can create Prometheus PodMonitor to monitor GreptimeDB through the `prometheusMonitor.enabled` field as follows:

```yaml
prometheusMonitor:
# -- Create PodMonitor resource for scraping metrics using PrometheusOperator
enabled: false
# -- Interval at which metrics should be scraped
interval: "30s"
# -- Add labels to the PodMonitor
labels:
release: prometheus
```

### Debug Pod Configuration

The debug pod has various tools installed (such as mysql-client, psql-client, etc.). You can exec into the debug pod for debugging. Create it with the `debugPod.enabled` field as follows:

```yaml
debugPod:
# -- Enable debug pod
enabled: false
# -- The debug pod image
image:
registry: docker.io
repository: greptime/greptime-tool
tag: "20241107-9c210d18"
# -- The debug pod resource
resources:
requests:
memory: 64Mi
cpu: 50m
limits:
memory: 256Mi
cpu: 200m
```
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ image:
# -- The image repository
repository: greptime/greptimedb
# -- The image tag
tag: "v0.11.0"
tag: "v0.11.3"
# -- The image pull secrets
pullSecrets: []
```
Expand All @@ -40,7 +40,7 @@ image:
# -- The image repository
repository: greptime/greptimedb
# -- The image tag
tag: "v0.11.0"
tag: "v0.11.3"
# -- The image pull secrets
pullSecrets: []
Expand Down Expand Up @@ -201,7 +201,7 @@ Helm Chart 默认不启用 User Provider 模式的鉴权,你可以通过 `auth
auth:
enabled: true
users:
- name: admin
- name: "admin"
password: "admin"
```

Expand Down Expand Up @@ -298,7 +298,7 @@ flownode:

```yaml
flownode:
enabled: false
enabled: true
replicas: 1
podTemplate:
main:
Expand All @@ -311,3 +311,122 @@ flownode:
cpu: "2"
```

### 对象存储配置

`objectStorage` 字段用于配置云对象存储(例如 AWS S3 和 Azure Blob Storage 等)作为 GreptimeDB 存储层。

#### AWS S3

```yaml
objectStorage:
credentials:
# AWS access key ID
accessKeyId: ""
# AWS secret access key
secretAccessKey: ""
s3:
# AWS S3 bucket name
bucket: ""
# AWS S3 region
region: ""
# The root path in bucket is 's3://<bucket>/<root>/data/...'
root: ""
# The AWS S3 endpoint, see more detail: https://docs.aws.amazon.com/general/latest/gr/s3.html
endpoint: ""
```

#### Google Cloud Storage

```yaml
objectStorage:
credentials:
# GCP serviceAccountKey JSON-formatted base64 value
serviceAccountKey: ""
gcs:
# Google Cloud Storage bucket name
bucket: ""
# Google Cloud OAuth 2.0 Scopes, example: "https://www.googleapis.com/auth/devstorage.read_write"
scope: ""
# The root path in bucket is 'gcs://<bucket>/<root>/data/...'
root: ""
# Google Cloud Storage endpoint, example: "https://storage.googleapis.com"
endpoint: ""
```

#### Azure Blob

```yaml
objectStorage:
credentials:
# Azure account name
accountName: ""
# Azure account key
accountKey: ""
azblob:
# Azure Blob container name
container: ""
# The root path in container is 'blob://<bucket>/<root>/data/...'
root: ""
# Azure Blob endpoint, see: "https://learn.microsoft.com/en-us/azure/storage/blobs/storage-blob-query-endpoint-srp?tabs=dotnet#query-for-the-blob-storage-endpoint"
endpoint: ""
```

#### AliCloud OSS

```yaml
objectStorage:
credentials:
# AliCloud access key ID
accessKeyId: ""
# AliCloud access key secret
secretAccessKey: ""
oss:
# AliCloud OSS bucket name
bucket: ""
# AliCloud OSS region
region: ""
# The root path in bucket is 'oss://<bucket>/<root>/data/...'
root: ""
# The AliCloud OSS endpoint
endpoint: ""
```

### Prometheus 监控配置

如果你已经安装了 [prometheus-operator](https://github.com/prometheus-operator/prometheus-operator),你可以通过 `prometheusMonitor.enabled` 字段创建 Prometheus PodMonitor 来监控 GreptimeDB,如下所示:

```yaml
prometheusMonitor:
# -- Create PodMonitor resource for scraping metrics using PrometheusOperator
enabled: false
# -- Interval at which metrics should be scraped
interval: "30s"
# -- Add labels to the PodMonitor
labels:
release: prometheus
```

### Debug Pod 配置

debug pod 中安装了各种工具(例如 mysql-client、psql-client 等)。你可以 exec 进入调试 debug pod 进行调试。使用 `debugPod.enabled` 字段创建它,如下所示:

```yaml
debugPod:
# -- Enable debug pod
enabled: false
# -- The debug pod image
image:
registry: docker.io
repository: greptime/greptime-tool
tag: "20241107-9c210d18"
# -- The debug pod resource
resources:
requests:
memory: 64Mi
cpu: 50m
limits:
memory: 256Mi
cpu: 200m
```
Loading

0 comments on commit 3e5c715

Please sign in to comment.