Skip to content

Commit

Permalink
feat(greptimedb-standalone): add objectstorage cache_path configura…
Browse files Browse the repository at this point in the history
…tion (#188)

* feat(greptimedb-standalone): add objectstorage cache_path configuration

* chore: rename cache_path explanation

* chore: suggestion commit
  • Loading branch information
daviderli614 authored Oct 31, 2024
1 parent 8915bf0 commit bac4832
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/greptimedb-standalone/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: greptimedb-standalone
description: A Helm chart for deploying standalone greptimedb
type: application
version: 0.1.28
version: 0.1.29
appVersion: 0.9.5
home: https://github.com/GreptimeTeam/greptimedb
sources:
Expand Down
2 changes: 1 addition & 1 deletion charts/greptimedb-standalone/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

A Helm chart for deploying standalone greptimedb

![Version: 0.1.28](https://img.shields.io/badge/Version-0.1.28-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.9.5](https://img.shields.io/badge/AppVersion-0.9.5-informational?style=flat-square)
![Version: 0.1.29](https://img.shields.io/badge/Version-0.1.29-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.9.5](https://img.shields.io/badge/AppVersion-0.9.5-informational?style=flat-square)

## Source Code
- https://github.com/GreptimeTeam/greptimedb
Expand Down
9 changes: 9 additions & 0 deletions charts/greptimedb-standalone/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -66,19 +66,23 @@ Create the name of the service account to use
{{- $provider := "" }}
{{- $bucket := "" }}
{{- $root := "" }}
{{- $cache_path := "" }}

{{- if .Values.objectStorage.s3 }}
{{- $provider = "S3" }}
{{- $bucket = .Values.objectStorage.s3.bucket }}
{{- $root = .Values.objectStorage.s3.root }}
{{- $cache_path = .Values.objectStorage.s3.cache_path }}
{{- else if .Values.objectStorage.oss }}
{{- $provider = "Oss" }}
{{- $bucket = .Values.objectStorage.oss.bucket }}
{{- $root = .Values.objectStorage.oss.root }}
{{- $cache_path = .Values.objectStorage.oss.cache_path }}
{{- else if .Values.objectStorage.gcs }}
{{- $provider = "Gcs" }}
{{- $bucket = .Values.objectStorage.gcs.bucket }}
{{- $root = .Values.objectStorage.gcs.root }}
{{- $cache_path = .Values.objectStorage.gcs.cache_path }}
{{- end }}

{{- if and $provider $bucket }}
Expand All @@ -92,6 +96,11 @@ Create the name of the service account to use
# Root path within the bucket
root = "{{ $root }}"

# Cache path configuration
{{- if $cache_path }}
cache_path = "{{ $cache_path }}"
{{- end }}

{{- if .Values.objectStorage.s3 }}
endpoint = "{{ .Values.objectStorage.s3.endpoint }}"
region = "{{ .Values.objectStorage.s3.region }}"
Expand Down
9 changes: 9 additions & 0 deletions charts/greptimedb-standalone/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ objectStorage:
# root: "greptimedb-standalone"
# endpoint: "" # See more detail: https://docs.aws.amazon.com/general/latest/gr/s3.html

# # Cache path configuration
# cache_path: ""

# configure to use oss storage
oss: {}
# bucket: "bucket-name"
Expand All @@ -75,6 +78,9 @@ objectStorage:
# root: "greptimedb-standalone"
# endpoint: "oss-cn-hangzhou.aliyuncs.com"

# # Cache path configuration
# cache_path: ""

# configure to use gcs storage
gcs: {}
# bucket: "bucket-name"
Expand All @@ -84,6 +90,9 @@ objectStorage:
# root: "greptimedb-standalone"
# endpoint: "https://storage.googleapis.com"

# # Cache path configuration
# cache_path: ""

# -- Environment variables
env:
GREPTIMEDB_STANDALONE__HTTP__ADDR: "0.0.0.0:4000"
Expand Down

0 comments on commit bac4832

Please sign in to comment.