Skip to content
Closed
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
4 changes: 4 additions & 0 deletions templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,7 @@ Create chart name and version as used by the chart label.
{{- define "trino.worker" -}}
{{ template "trino.fullname" . }}-worker
{{- end -}}

{{- define "trino.catalog" -}}
{{ template "trino.fullname" . }}-catalog
{{- end -}}
16 changes: 16 additions & 0 deletions templates/configmap-catalog.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{{- if .Values.server.catalogs.enabled }}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ template "trino.catalog" . }}
labels:
app: {{ template "trino.name" . }}
chart: {{ template "trino.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
component: catalog
data:
{{- range $key, $val := .Values.server.catalogs.configs }}
{{ $key }}: | {{ $val | nindent 4 }}
{{- end }}
{{- end }}
3 changes: 3 additions & 0 deletions templates/configmap-coordinator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ data:
query.max-memory-per-node={{ .Values.server.config.query.maxMemoryPerNode }}
discovery-server.enabled=true
discovery.uri=http://localhost:{{ .Values.service.port }}
{{- if .Values.oauth.enabled }}
{{- .Values.oauth.config | nindent 4 }}
{{- end }}

log.properties: |
io.trinosql={{ .Values.server.log.trino.level }}
Expand Down
5 changes: 5 additions & 0 deletions templates/deployment-coordinator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,18 @@ spec:
- name: config-volume
configMap:
name: {{ template "trino.coordinator" . }}
- name: catalog-volume
configMap:
name: {{ template "trino.catalog" . }}
containers:
- name: {{ .Chart.Name }}-coordinator
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
volumeMounts:
- mountPath: {{ .Values.server.config.path }}
name: config-volume
- mountPath: {{ .Values.server.config.path }}/catalog
name: catalog-volume
ports:
- name: http
containerPort: {{ .Values.service.port }}
Expand Down
5 changes: 5 additions & 0 deletions templates/deployment-worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,18 @@ spec:
- name: config-volume
configMap:
name: {{ template "trino.worker" . }}
- name: catalog-volume
configMap:
name: {{ template "trino.catalog" . }}
containers:
- name: {{ .Chart.Name }}-worker
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
volumeMounts:
- mountPath: {{ .Values.server.config.path }}
name: config-volume
- mountPath: {{ .Values.server.config.path }}/catalog
name: catalog-volume
ports:
- name: http
containerPort: {{ .Values.service.port }}
Expand Down
32 changes: 32 additions & 0 deletions templates/ingress.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{{- if .Values.ingress.enabled }}
{{- $serviceName := printf "%s" ( include "trino.name" .) }}
{{- $servicePort := .Values.service.port }}
{{- $ingressPath := .Values.ingress.path }}
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: {{ template "trino.fullname" . }}
labels:
app: {{ template "trino.name" . }}
chart: {{ template "trino.chart" . }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
{{- with .Values.ingress.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
rules:
{{- range .Values.ingress.hosts }}
- host: {{ . | quote }}
http:
paths:
- path: {{ $ingressPath }}
backend:
serviceName: {{ $serviceName }}
servicePort: {{ $servicePort }}
{{- end }}
{{- if .Values.ingress.tls }}
tls: {{ toYaml .Values.ingress.tls | nindent 4 }}
{{- end }}
{{- end }}
49 changes: 46 additions & 3 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,57 @@ server:
g1:
heapRegionSize: "32M"

securityContext:
runAsUser: 1000
runAsGroup: 1000
catalogs:
enabled: false
configs:
datalake.properties: |
connector.name=hive-hadoop2
hive.metastore=file
hive.s3-file-system-type=TRINO
hive.metastore.catalog.dir=s3:///
hive.s3.aws-access-key=
hive.s3.aws-secret-key=secretKey
hive.s3.endpoint=
hive.s3.path-style-access=true
hive.s3select-pushdown.enabled=true
hive.s3.ssl.enabled=false

oauth:
enabled: false
config: |
http-server.authentication.type=oauth2
http-server.authentication.oauth2.auth-url=
http-server.authentication.oauth2.token-url=
http-server.authentication.oauth2.jwks-url=
http-server.authentication.oauth2.client-id=
http-server.authentication.oauth2.client-secret=
http-server.authentication.oauth2.scopes=
web-ui.authentication.type=oauth2

ingress:
## Set to true to enable ingress record generation
enabled: false
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
labels: {}
path: /
pathType: Prefix
hosts:
- chart-example.local
tls: []
# - secretName: chart-example-tls
# hosts:
# - chart-example.local

service:
type: ClusterIP
port: 8080

securityContext:
runAsUser: 1000
runAsGroup: 1000

resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious
# choice for the user. This also increases chances charts run on environments with little
Expand Down