From 6c83fe915c247f5d8d4293ab36166c5231a5c789 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20J=2E=20Salmer=C3=B3n-Garc=C3=ADa?= Date: Tue, 25 Jun 2024 12:15:10 +0200 Subject: [PATCH] [bitnami/dremio] feat: :tada: Add chart (#27453) Description of the change This PR adds the chart for Dremio OSS, based on the upstream dremio chart. Features: - BItnami standards - Full configuration using the upstream Dremio configuration - Use of indirect environment variables in configuration - Master coordinator, Coordinator and Executor (with multiple engines) - TLS for the web interface (the only one allowed in Dremio OSS) --------- Signed-off-by: Javier Salmeron Garcia Signed-off-by: Bitnami Containers Co-authored-by: Bitnami Containers --- .vib/dremio/cypress/cypress.config.js | 15 + .vib/dremio/cypress/cypress/e2e/dremio.cy.js | 32 + .../cypress/cypress/fixtures/database.json | 6 + .../cypress/cypress/support/commands.js | 46 + .vib/dremio/cypress/cypress/support/e2e.js | 25 + .vib/dremio/cypress/cypress/support/utils.js | 8 + .vib/dremio/goss/goss.yaml | 108 + .vib/dremio/runtime-parameters.yaml | 231 ++ .vib/dremio/vib-action.config | 1 + .vib/dremio/vib-publish.json | 38 + .vib/dremio/vib-verify.json | 61 + bitnami/dremio/.helmignore | 23 + bitnami/dremio/CHANGELOG.md | 5 + bitnami/dremio/Chart.lock | 12 + bitnami/dremio/Chart.yaml | 44 + bitnami/dremio/README.md | 1284 ++++++++ bitnami/dremio/templates/NOTES.txt | 69 + bitnami/dremio/templates/_helpers.tpl | 530 ++++ bitnami/dremio/templates/_init_containers.tpl | 494 ++++ .../dremio/templates/bootstrap-user/job.yaml | 136 + .../bootstrap-user/networkpolicy.yaml | 59 + bitnami/dremio/templates/ca-cert.yaml | 60 + bitnami/dremio/templates/cert.yaml | 45 + .../coordinator/configmap-dremio-conf.yaml | 50 + bitnami/dremio/templates/coordinator/hpa.yaml | 52 + .../templates/coordinator/networkpolicy.yaml | 122 + bitnami/dremio/templates/coordinator/pdb.yaml | 32 + .../coordinator/secret-dremio-conf.yaml | 42 + .../coordinator/service-account.yaml | 22 + .../templates/coordinator/statefulset.yaml | 394 +++ bitnami/dremio/templates/coordinator/vpa.yaml | 47 + .../executor/configmap-dremio-conf.yaml | 64 + bitnami/dremio/templates/executor/hpa.yaml | 64 + .../templates/executor/networkpolicy.yaml | 131 + bitnami/dremio/templates/executor/pdb.yaml | 45 + .../executor/secret-dremio-conf.yaml | 54 + .../templates/executor/service-account.yaml | 34 + .../templates/executor/statefulset.yaml | 396 +++ bitnami/dremio/templates/executor/vpa.yaml | 60 + .../dremio/templates/externals3-secret.yaml | 21 + bitnami/dremio/templates/extra-list.yaml | 9 + .../dremio/templates/headless-service.yaml | 51 + .../dremio/templates/ingress-tls-secret.yaml | 50 + bitnami/dremio/templates/ingress.yaml | 62 + .../configmap-dremio-conf.yaml | 50 + .../templates/master-coordinator/hpa.yaml | 52 + .../master-coordinator/networkpolicy.yaml | 124 + .../templates/master-coordinator/pdb.yaml | 32 + .../templates/master-coordinator/pvc.yaml | 39 + .../secret-dremio-conf.yaml | 42 + .../master-coordinator/service-account.yaml | 22 + .../master-coordinator/statefulset.yaml | 371 +++ .../templates/master-coordinator/vpa.yaml | 47 + .../templates/metrics/metrics-configmap.yaml | 51 + bitnami/dremio/templates/metrics/service.yaml | 32 + .../templates/metrics/servicemonitor.yaml | 52 + .../dremio/templates/secret-core-site.yaml | 82 + bitnami/dremio/templates/secrets.yaml | 42 + bitnami/dremio/templates/service.yaml | 69 + bitnami/dremio/templates/tls-secret.yaml | 52 + bitnami/dremio/values.yaml | 2585 +++++++++++++++++ 61 files changed, 8878 insertions(+) create mode 100644 .vib/dremio/cypress/cypress.config.js create mode 100644 .vib/dremio/cypress/cypress/e2e/dremio.cy.js create mode 100644 .vib/dremio/cypress/cypress/fixtures/database.json create mode 100644 .vib/dremio/cypress/cypress/support/commands.js create mode 100644 .vib/dremio/cypress/cypress/support/e2e.js create mode 100644 .vib/dremio/cypress/cypress/support/utils.js create mode 100644 .vib/dremio/goss/goss.yaml create mode 100644 .vib/dremio/runtime-parameters.yaml create mode 100644 .vib/dremio/vib-action.config create mode 100644 .vib/dremio/vib-publish.json create mode 100644 .vib/dremio/vib-verify.json create mode 100644 bitnami/dremio/.helmignore create mode 100644 bitnami/dremio/CHANGELOG.md create mode 100644 bitnami/dremio/Chart.lock create mode 100644 bitnami/dremio/Chart.yaml create mode 100644 bitnami/dremio/README.md create mode 100644 bitnami/dremio/templates/NOTES.txt create mode 100644 bitnami/dremio/templates/_helpers.tpl create mode 100644 bitnami/dremio/templates/_init_containers.tpl create mode 100644 bitnami/dremio/templates/bootstrap-user/job.yaml create mode 100644 bitnami/dremio/templates/bootstrap-user/networkpolicy.yaml create mode 100644 bitnami/dremio/templates/ca-cert.yaml create mode 100644 bitnami/dremio/templates/cert.yaml create mode 100644 bitnami/dremio/templates/coordinator/configmap-dremio-conf.yaml create mode 100644 bitnami/dremio/templates/coordinator/hpa.yaml create mode 100644 bitnami/dremio/templates/coordinator/networkpolicy.yaml create mode 100644 bitnami/dremio/templates/coordinator/pdb.yaml create mode 100644 bitnami/dremio/templates/coordinator/secret-dremio-conf.yaml create mode 100644 bitnami/dremio/templates/coordinator/service-account.yaml create mode 100644 bitnami/dremio/templates/coordinator/statefulset.yaml create mode 100644 bitnami/dremio/templates/coordinator/vpa.yaml create mode 100644 bitnami/dremio/templates/executor/configmap-dremio-conf.yaml create mode 100644 bitnami/dremio/templates/executor/hpa.yaml create mode 100644 bitnami/dremio/templates/executor/networkpolicy.yaml create mode 100644 bitnami/dremio/templates/executor/pdb.yaml create mode 100644 bitnami/dremio/templates/executor/secret-dremio-conf.yaml create mode 100644 bitnami/dremio/templates/executor/service-account.yaml create mode 100644 bitnami/dremio/templates/executor/statefulset.yaml create mode 100644 bitnami/dremio/templates/executor/vpa.yaml create mode 100644 bitnami/dremio/templates/externals3-secret.yaml create mode 100644 bitnami/dremio/templates/extra-list.yaml create mode 100644 bitnami/dremio/templates/headless-service.yaml create mode 100644 bitnami/dremio/templates/ingress-tls-secret.yaml create mode 100644 bitnami/dremio/templates/ingress.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/configmap-dremio-conf.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/hpa.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/networkpolicy.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/pdb.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/pvc.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/secret-dremio-conf.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/service-account.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/statefulset.yaml create mode 100644 bitnami/dremio/templates/master-coordinator/vpa.yaml create mode 100644 bitnami/dremio/templates/metrics/metrics-configmap.yaml create mode 100644 bitnami/dremio/templates/metrics/service.yaml create mode 100644 bitnami/dremio/templates/metrics/servicemonitor.yaml create mode 100644 bitnami/dremio/templates/secret-core-site.yaml create mode 100644 bitnami/dremio/templates/secrets.yaml create mode 100644 bitnami/dremio/templates/service.yaml create mode 100644 bitnami/dremio/templates/tls-secret.yaml create mode 100644 bitnami/dremio/values.yaml diff --git a/.vib/dremio/cypress/cypress.config.js b/.vib/dremio/cypress/cypress.config.js new file mode 100644 index 0000000000..a733ed6604 --- /dev/null +++ b/.vib/dremio/cypress/cypress.config.js @@ -0,0 +1,15 @@ +module.exports = { + env: { + username: 'vib_user', + password: 'ComplicatedPassword!1234', + postgresql_host: 'postgresql', + postgresql_user: 'postgres', + postgresql_db: 'vib_test', + postgresql_password: 'password123', + }, + defaultCommandTimeout: 30000, + e2e: { + setupNodeEvents(on, config) {}, + baseUrl: 'http://localhost', + }, +} diff --git a/.vib/dremio/cypress/cypress/e2e/dremio.cy.js b/.vib/dremio/cypress/cypress/e2e/dremio.cy.js new file mode 100644 index 0000000000..1819b22edd --- /dev/null +++ b/.vib/dremio/cypress/cypress/e2e/dremio.cy.js @@ -0,0 +1,32 @@ +/* + * Copyright Broadcom, Inc. All Rights Reserved. + * SPDX-License-Identifier: APACHE-2.0 + */ + +/// +import { + random, +} from '../support/utils'; + +it('Allows to import a PostgreSQL database and perform a query', () => { + cy.login(); + // Go to the collections page + cy.contains('Add Source').click(); + cy.contains('PostgreSQL').click(); + cy.fixture('database').then((d) => { + cy.get('#name').should('be.enabled').clear({force: true}).type(`${d.database.name}${random}`); + // Cannot use # because of the middle dot + cy.get('[id="config.hostname"]').should('be.enabled').clear({force: true}).type(Cypress.env('postgresql_host')); + cy.get('[id="config.databaseName"]').should('be.enabled').clear({force: true}).type(Cypress.env('postgresql_db')); + cy.get('[id="config.username"]').should('be.enabled').clear({force: true}).type(Cypress.env('postgresql_user')); + cy.get('[id="config.password"]').should('be.enabled').clear({force: true}).type(Cypress.env('postgresql_password')); + cy.contains('Save').click(); + cy.get(`[href*="source/${d.database.name}${random}"]`); + // Does not have text as it is an icon, so we need to use the href selector + cy.get('[href*="new_query"]').click(); + // Ensure the editor is fully loaded + cy.contains(`${d.database.name}${random}`).click(); + cy.contains('public').click(); + cy.contains(d.database.expectedRes); + }); +}); diff --git a/.vib/dremio/cypress/cypress/fixtures/database.json b/.vib/dremio/cypress/cypress/fixtures/database.json new file mode 100644 index 0000000000..202fc58b31 --- /dev/null +++ b/.vib/dremio/cypress/cypress/fixtures/database.json @@ -0,0 +1,6 @@ +{ + "database": { + "name": "vib_psql", + "expectedRes": "cars" + } +} diff --git a/.vib/dremio/cypress/cypress/support/commands.js b/.vib/dremio/cypress/cypress/support/commands.js new file mode 100644 index 0000000000..65ad0bd277 --- /dev/null +++ b/.vib/dremio/cypress/cypress/support/commands.js @@ -0,0 +1,46 @@ +/* + * Copyright Broadcom, Inc. All Rights Reserved. + * SPDX-License-Identifier: APACHE-2.0 + */ + +const COMMAND_DELAY = 2000; + +for (const command of ['click']) { + Cypress.Commands.overwrite(command, (originalFn, ...args) => { + const origVal = originalFn(...args); + + return new Promise((resolve) => { + setTimeout(() => { + resolve(origVal); + }, COMMAND_DELAY); + }); + }); +} + +Cypress.Commands.add( + 'login', + (username = Cypress.env('username'), password = Cypress.env('password')) => { + cy.visit('/login'); + cy.get('#userName').should('be.enabled').clear({force: true}).type(username); + cy.get('#password').should('be.enabled').clear({force: true}).type(password); + cy.contains('Log In').click(); + cy.contains('Datasets'); + } +); + +Cypress.on('uncaught:exception', (err) => { + if (err.message.includes('Cannot read properties of')) { + return false; + } + if (err.message.includes('Normalize accepts')) { + return false; + } + // We expect an error "Failed to execute 'observe' on 'IntersectionObserver'" + // during the installation of a template so we add an exception + if (err.message.includes("Failed to execute 'observe' on 'IntersectionObserver'")) { + return false; + } + + // we still want to ensure there are no other unexpected + // errors, so we let them fail the test +}) diff --git a/.vib/dremio/cypress/cypress/support/e2e.js b/.vib/dremio/cypress/cypress/support/e2e.js new file mode 100644 index 0000000000..56c00209c0 --- /dev/null +++ b/.vib/dremio/cypress/cypress/support/e2e.js @@ -0,0 +1,25 @@ +/* + * Copyright Broadcom, Inc. All Rights Reserved. + * SPDX-License-Identifier: APACHE-2.0 + */ + +// *********************************************************** +// This example support/index.js is processed and +// loaded automatically before your test files. +// +// This is a great place to put global configuration and +// behavior that modifies Cypress. +// +// You can change the location of this file or turn off +// automatically serving support files with the +// 'supportFile' configuration option. +// +// You can read more here: +// https://on.cypress.io/configuration +// *********************************************************** + +// Import commands.js using ES2015 syntax: +import './commands'; + +// Alternatively you can use CommonJS syntax: +// require('./commands') diff --git a/.vib/dremio/cypress/cypress/support/utils.js b/.vib/dremio/cypress/cypress/support/utils.js new file mode 100644 index 0000000000..8745899b97 --- /dev/null +++ b/.vib/dremio/cypress/cypress/support/utils.js @@ -0,0 +1,8 @@ +/* + * Copyright Broadcom, Inc. All Rights Reserved. + * SPDX-License-Identifier: APACHE-2.0 + */ + +/// + +export let random = (Math.random() + 1).toString(36).substring(7); diff --git a/.vib/dremio/goss/goss.yaml b/.vib/dremio/goss/goss.yaml new file mode 100644 index 0000000000..c848f2baef --- /dev/null +++ b/.vib/dremio/goss/goss.yaml @@ -0,0 +1,108 @@ +# Copyright Broadcom, Inc. All Rights Reserved. +# SPDX-License-Identifier: APACHE-2.0 + +http: + http://127.0.0.1:{{ .Vars.dremio.containerPorts.web }}: + status: 200 + body: + - /dremio/ + http://127.0.0.1:{{ .Vars.dremio.containerPorts.web }}/apiv2/login: + status: 200 + method: POST + request-headers: + - "Content-Type: application/json" + request-body: '{"userName": "{{ .Vars.dremio.auth.username }}", "password": "{{ .Vars.dremio.auth.password }}"}' + body: + - /{{ .Vars.dremio.auth.username }}/ + - /{{ .Vars.dremio.auth.email }}/ + - /{{ .Vars.dremio.auth.firstName }}/ + - /{{ .Vars.dremio.auth.lastName }}/ + http://dremio:{{ .Vars.service.ports.web }}: + status: 200 + body: + - /dremio/ + http://dremio:{{ .Vars.service.ports.web }}/apiv2/login: + status: 200 + method: POST + request-headers: + - "Content-Type: application/json" + request-body: '{"userName": "{{ .Vars.dremio.auth.username }}", "password": "{{ .Vars.dremio.auth.password }}"}' + body: + - /{{ .Vars.dremio.auth.username }}/ + - /{{ .Vars.dremio.auth.email }}/ + - /{{ .Vars.dremio.auth.firstName }}/ + - /{{ .Vars.dremio.auth.lastName }}/ + {{- if .Vars.metrics.enabled }} + http://127.0.0.1:{{ .Vars.metrics.containerPorts.metrics }}/metrics: + status: 200 + timeout: 30000 + body: + - /metrics_com_dremio/ + {{- /* Not testing the body output because it is causing a CancelTimeoutError from time to time (probably because of the resource preset we are using) */}} + http://dremio-metrics:{{ .Vars.metrics.service.ports.metrics }}/metrics: + status: 200 + timeout: 30000 + {{- end }} +addr: + tcp://dremio-master-coordinator-0.dremio-headless:{{ .Vars.dremio.containerPorts.liveness }}: + reachable: true + timeout: 10000 + tcp://127.0.0.1:{{ .Vars.dremio.containerPorts.conduit }}: + reachable: true + timeout: 10000 + {{- if .Vars.metrics.enabled }} + tcp://127.0.0.1:{{ .Vars.dremio.containerPorts.jmx }}: + reachable: true + timeout: 10000 + {{- end }} + tcp://dremio-coordinator-0.dremio-headless:{{ .Vars.dremio.containerPorts.client }}: + reachable: true + timeout: 10000 + tcp://dremio-coordinator-0.dremio-headless:{{ .Vars.dremio.containerPorts.fabric }}: + reachable: true + timeout: 10000 + tcp://dremio:{{ .Vars.service.ports.client }}: + reachable: true + timeout: 10000 + tcp://dremio:{{ .Vars.service.ports.flight }}: + reachable: true + timeout: 10000 +file: + {{ .Vars.masterCoordinator.persistence.mountPath }}: + exists: true + filetype: directory + mode: '2775' + owner: root + /opt/bitnami/dremio/conf/dremio.conf: + exists: true + contents: + - /services.coordinator.web.tokens.cache.size.*{{ .Vars.masterCoordinator.dremioConf.configOverrides.services.coordinator.web.tokens.cache.size }}/ + - /services.conduit.ssl.trustStorePassword.*{{ .Vars.masterCoordinator.dremioConf.secretConfigOverrides.services.conduit.ssl.trustStorePassword }}/ + - /services.fabric.memory.reservation.*{{ .Vars.dremio.dremioConf.configOverrides.services.fabric.memory.reservation }}/ + - /services.coordinator.web.ssl.trustStorePassword.*{{ .Vars.dremio.dremioConf.secretConfigOverrides.services.coordinator.web.ssl.trustStorePassword }}/ + - /services.web-admin.port.*{{ .Vars.dremio.containerPorts.liveness }}/ + - /services.coordinator.web.port.*{{ .Vars.dremio.containerPorts.web }}/ + - /services.conduit.port.*{{ .Vars.dremio.containerPorts.conduit }}/ + - /services.fabric.port.*{{ .Vars.dremio.containerPorts.fabric }}/ + - /services.flight.port.*{{ .Vars.dremio.containerPorts.flight }}/ + /opt/bitnami/dremio/conf/core-site.xml: + exists: true + contents: + - /fs.s3a.endpoint.region/ + - /us-east-1/ + /opt/bitnami/dremio/conf/vib.conf: + exists: true + contents: + - /IT WORKS/ + /opt/bitnami/dremio/conf/vib_secret.conf: + exists: true + contents: + - /IT SECRETLY WORKS/ +command: + {{- $uid := .Vars.masterCoordinator.containerSecurityContext.runAsUser }} + {{- $gid := .Vars.masterCoordinator.podSecurityContext.fsGroup }} + check-user-info: + # The UID and GID should always be either the one specified as vars (always a bigger number that the default) + # or the one randomly defined by openshift (larger values). Otherwise, the chart is still using the default value. + exec: if [ $(id -u) -lt {{ $uid }} ] || [ $(id -G | awk '{print $2}') -lt {{ $gid }} ]; then exit 1; fi + exit-status: 0 diff --git a/.vib/dremio/runtime-parameters.yaml b/.vib/dremio/runtime-parameters.yaml new file mode 100644 index 0000000000..8a3d184aa1 --- /dev/null +++ b/.vib/dremio/runtime-parameters.yaml @@ -0,0 +1,231 @@ +masterCoordinator: + podSecurityContext: + fsGroup: 1002 + containerSecurityContext: + runAsUser: 1002 + persistence: + enabled: true + mountPath: /bitnami/dremio/data + # Add specific overrides to dremio.conf + dremioConf: + configOverrides: + services: + coordinator: + web: + tokens: + cache: + size: 120 + secretConfigOverrides: + services: + conduit: + ssl: + trustStorePassword: "test" + # Add extra files to the configmap + extraFiles: + vib.conf: | + IT WORKS + extraSecretFiles: + vib_secret.conf: | + IT SECRETLY WORKS +dremio: + containerPorts: + web: 9048 + client: 31011 + flight: 32011 + fabric: 45678 + conduit: 45679 + jmx: 50001 + liveness: 44350 + # Add common overrides to dremio.conf + dremioConf: + configOverrides: + services: + fabric: + memory: + reservation: 150M + secretConfigOverrides: + services: + coordinator: + web: + ssl: + trustStorePassword: "password123" + # Add extra configuration to core-site.xml + coreSite: + appendConfiguration: | + + fs.s3a.endpoint.region + us-east-1 + + auth: + enabled: true + username: vib_user + password: "ComplicatedPassword!1234" + firstName: VIBFIRST + lastName: VIBNAME + email: vib_email@example.com +usePasswordFile: true +service: + type: LoadBalancer + ports: + web: 80 + client: 41010 + flight: 42010 +metrics: + enabled: true + service: + ports: + metrics: 41881 + containerPorts: + metrics: 41884 +# We deploy a PostgreSQL instance so we can use it in Dremio as a data source. We create a database +# that we can verify in the Cypress test +extraDeploy: + - | + apiVersion: v1 + kind: Secret + metadata: + name: postgresql + labels: + app.kubernetes.io/instance: postgresql + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: postgresql + app.kubernetes.io/version: 16.3.0 + helm.sh/chart: postgresql-15.5.6 + type: Opaque + stringData: + postgres-password: "password123" + - | + apiVersion: v1 + kind: Service + metadata: + name: postgresql + labels: + app.kubernetes.io/instance: postgresql + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: postgresql + app.kubernetes.io/version: 16.3.0 + helm.sh/chart: postgresql-15.5.6 + app.kubernetes.io/component: primary + spec: + type: ClusterIP + sessionAffinity: None + ports: + - name: tcp-postgresql + port: 5432 + targetPort: tcp-postgresql + nodePort: null + selector: + app.kubernetes.io/instance: postgresql + app.kubernetes.io/name: postgresql + app.kubernetes.io/component: primary + - | + apiVersion: apps/v1 + kind: StatefulSet + metadata: + name: postgresql + labels: + app.kubernetes.io/instance: postgresql + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: postgresql + app.kubernetes.io/version: 16.3.0 + helm.sh/chart: postgresql-15.5.6 + app.kubernetes.io/component: primary + spec: + replicas: 1 + updateStrategy: + rollingUpdate: {} + type: RollingUpdate + selector: + matchLabels: + app.kubernetes.io/instance: postgresql + app.kubernetes.io/name: postgresql + app.kubernetes.io/component: primary + template: + metadata: + name: postgresql + labels: + app.kubernetes.io/instance: postgresql + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: postgresql + app.kubernetes.io/version: 16.3.0 + helm.sh/chart: postgresql-15.5.6 + app.kubernetes.io/component: primary + spec: + # Using the same security context as the master-coordinator to avoid issues with Openshift + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.masterCoordinator.podSecurityContext "context" $) | nindent 8 }} + containers: + - name: postgresql + image: docker.io/bitnami/postgresql:16.3.0-debian-12-r14 + imagePullPolicy: "IfNotPresent" + # Using the same security context as the master-coordinator to avoid issues with Openshift + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.masterCoordinator.containerSecurityContext "context" $) | nindent 12 }} + env: + - name: POSTGRES_PASSWORD + valueFrom: + secretKeyRef: + name: postgresql + key: postgres-password + ports: + - name: tcp-postgresql + containerPort: 5432 + volumeMounts: + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/postgresql/conf + subPath: app-conf-dir + - name: empty-dir + mountPath: /opt/bitnami/postgresql/tmp + subPath: app-tmp-dir + - name: custom-init-scripts + mountPath: /docker-entrypoint-initdb.d/ + - name: dshm + mountPath: /dev/shm + - name: data + mountPath: /bitnami/postgresql + volumes: + - name: empty-dir + emptyDir: {} + - name: custom-init-scripts + configMap: + name: postgresql-init-scripts + - name: dshm + emptyDir: + medium: Memory + volumeClaimTemplates: + - apiVersion: v1 + kind: PersistentVolumeClaim + metadata: + name: data + spec: + accessModes: + - "ReadWriteOnce" + resources: + requests: + storage: "8Gi" + - | + apiVersion: v1 + kind: ConfigMap + metadata: + name: postgresql-init-scripts + labels: + app.kubernetes.io/instance: postgresql + app.kubernetes.io/managed-by: Helm + app.kubernetes.io/name: postgresql + app.kubernetes.io/version: 16.3.0 + helm.sh/chart: postgresql-15.5.6 + data: + add_data.sql: | + CREATE DATABASE vib_test; + \c vib_test; + CREATE TABLE cars ( + brand VARCHAR(255), + model VARCHAR(255), + year INT + ); + INSERT INTO cars (brand, model, year) + VALUES + ('Toyota', 'Camry', 2020), + ('Honda', 'Civic', 2019), + ('Ford', 'Mustang', 2018); diff --git a/.vib/dremio/vib-action.config b/.vib/dremio/vib-action.config new file mode 100644 index 0000000000..36a99dc6a3 --- /dev/null +++ b/.vib/dremio/vib-action.config @@ -0,0 +1 @@ +verification-mode=SERIAL diff --git a/.vib/dremio/vib-publish.json b/.vib/dremio/vib-publish.json new file mode 100644 index 0000000000..d291d783a0 --- /dev/null +++ b/.vib/dremio/vib-publish.json @@ -0,0 +1,38 @@ +{ + "phases": { + "package": { + "context": { + "resources": { + "url": "{SHA_ARCHIVE}", + "path": "/bitnami/dremio" + } + }, + "actions": [ + { + "action_id": "helm-package" + }, + { + "action_id": "helm-lint" + } + ] + }, + "publish": { + "actions": [ + { + "action_id": "helm-publish", + "params": { + "repository": { + "kind": "S3", + "url": "{VIB_ENV_S3_URL}", + "authn": { + "access_key_id": "{VIB_ENV_S3_ACCESS_KEY_ID}", + "secret_access_key": "{VIB_ENV_S3_SECRET_ACCESS_KEY}", + "role": "{VIB_ENV_S3_ROLE_ARN}" + } + } + } + } + ] + } + } +} diff --git a/.vib/dremio/vib-verify.json b/.vib/dremio/vib-verify.json new file mode 100644 index 0000000000..d411a18dee --- /dev/null +++ b/.vib/dremio/vib-verify.json @@ -0,0 +1,61 @@ +{ + "phases": { + "package": { + "context": { + "resources": { + "url": "{SHA_ARCHIVE}", + "path": "/bitnami/dremio" + } + }, + "actions": [ + { + "action_id": "helm-package" + }, + { + "action_id": "helm-lint" + } + ] + }, + "verify": { + "context": { + "resources": { + "url": "{SHA_ARCHIVE}", + "path": "/bitnami/dremio" + }, + "target_platform": { + "target_platform_id": "{VIB_ENV_TARGET_PLATFORM}", + "size": { + "name": "L4" + } + } + }, + "actions": [ + { + "action_id": "goss", + "params": { + "resources": { + "path": "/.vib" + }, + "tests_file": "dremio/goss/goss.yaml", + "vars_file": "dremio/runtime-parameters.yaml", + "remote": { + "pod": { + "workload": "sts-dremio-master-coordinator" + } + } + } + }, + { + "action_id": "cypress", + "params": { + "resources": { + "path": "/.vib/dremio/cypress" + }, + "endpoint": "lb-dremio-http-web", + "app_protocol": "HTTP" + } + } + ] + } + } +} diff --git a/bitnami/dremio/.helmignore b/bitnami/dremio/.helmignore new file mode 100644 index 0000000000..a0a332a53c --- /dev/null +++ b/bitnami/dremio/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*~ +# Various IDEs +.project +.idea/ +*.tmproj +# Changelog +CHANGELOG.md diff --git a/bitnami/dremio/CHANGELOG.md b/bitnami/dremio/CHANGELOG.md new file mode 100644 index 0000000000..68c7db701b --- /dev/null +++ b/bitnami/dremio/CHANGELOG.md @@ -0,0 +1,5 @@ +# Changelog + +## 0.1.0 (2024-06-25) + +* [bitnami/dremio] feat: :tada: Add chart ([#27453](https://github.com/bitnami/charts/pull/27453)) diff --git a/bitnami/dremio/Chart.lock b/bitnami/dremio/Chart.lock new file mode 100644 index 0000000000..67285d3cf5 --- /dev/null +++ b/bitnami/dremio/Chart.lock @@ -0,0 +1,12 @@ +dependencies: +- name: minio + repository: oci://registry-1.docker.io/bitnamicharts + version: 14.6.10 +- name: zookeeper + repository: oci://registry-1.docker.io/bitnamicharts + version: 13.4.4 +- name: common + repository: oci://registry-1.docker.io/bitnamicharts + version: 2.20.3 +digest: sha256:0cb0933033ce80abc90eb15e2404f15a6c5191b500295c9686493c12c8a7fa22 +generated: "2024-06-18T10:42:31.507881356+02:00" diff --git a/bitnami/dremio/Chart.yaml b/bitnami/dremio/Chart.yaml new file mode 100644 index 0000000000..1ae9289c31 --- /dev/null +++ b/bitnami/dremio/Chart.yaml @@ -0,0 +1,44 @@ +# Copyright Broadcom, Inc. All Rights Reserved. +# SPDX-License-Identifier: APACHE-2.0 + +annotations: + category: Analytics + licenses: Apache-2.0 + images: | + - name: dremio + image: docker.io/bitnami/dremio:25.0.0-debian-12-r0 + - name: os-shell + image: docker.io/bitnami/os-shell:12-debian-12-r22 + - name: jmx-exporter + image: docker.io/bitnami/jmx-exporter:1.0.1-debian-12-r1 +apiVersion: v2 +appVersion: 25.0.0 +dependencies: +- condition: minio.enabled + name: minio + repository: oci://registry-1.docker.io/bitnamicharts + version: 14.x.x +- condition: zookeeper.enabled + name: zookeeper + repository: oci://registry-1.docker.io/bitnamicharts + version: 13.x.x +- name: common + repository: oci://registry-1.docker.io/bitnamicharts + tags: + - bitnami-common + version: 2.x.x +description: Dremio is an open-source self-service data access tool that provides high-performance queries for interactive analytics on data lakes. +home: https://bitnami.com +icon: https://bitnami.com/assets/stacks/dremio/img/dremio-stack-220x234.png +keywords: +- dremio +- data-lake +maintainers: +- name: Broadcom, Inc. All Rights Reserved. + url: https://github.com/bitnami/charts +name: dremio +sources: +- https://github.com/bitnami/charts/tree/main/bitnami/dremio +- https://github.com/bitnami/containers/tree/main/bitnami/dremio +- https://github.com/dremio/dremio-oss +version: 0.1.0 diff --git a/bitnami/dremio/README.md b/bitnami/dremio/README.md new file mode 100644 index 0000000000..97ecc42d1f --- /dev/null +++ b/bitnami/dremio/README.md @@ -0,0 +1,1284 @@ + + +# Bitnami package for Dremio + +Dremio is an open-source self-service data access tool that provides high-performance queries for interactive analytics on data lakes. + +[Overview of Dremio](https://www.dremio.com/) + +## TL;DR + +```console +helm install my-release oci://registry-1.docker.io/bitnamicharts/dremio +``` + +Looking to use dremio in production? Try [VMware Tanzu Application Catalog](https://bitnami.com/enterprise), the enterprise edition of Bitnami Application Catalog. + +## Introduction + +This chart bootstraps a [Dremio](https://github.com/bitnami/containers/tree/main/bitnami/dremio) deployment on a [Kubernetes](https://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. + +Bitnami charts can be used with [Kubeapps](https://kubeapps.dev/) for deployment and management of Helm Charts in clusters. + +## Prerequisites + +- Kubernetes 1.23+ +- Helm 3.8.0+ +- PV provisioner support in the underlying infrastructure + +## Installing the Chart + +To install the chart with the release name `my-release`: + +```console +helm install my-release oci://REGISTRY_NAME/REPOSITORY_NAME/dremio +``` + +> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`. + +The command deploys dremio on the Kubernetes cluster in the default configuration. The [Parameters](#parameters) section lists the parameters that can be configured during installation. + +> **Tip**: List all releases using `helm list` + +## Configuration and installation details + +### [Rolling VS Immutable tags](https://docs.vmware.com/en/VMware-Tanzu-Application-Catalog/services/tutorials/GUID-understand-rolling-tags-containers-index.html) + +It is strongly recommended to use immutable tags in a production environment. This ensures your deployment does not change automatically if the same tag is updated with a different image. + +Bitnami will release a new chart updating its containers if a new version of the main container, significant changes, or critical vulnerabilities exist. + +### Customizing Dremio configuration files + +Dremio has two main configuration files: `dremio.conf` and `core-site.xml`. These are automatically generated by the chart using the information provided in the `values.yaml` file. + +It is possible to add custom information in both files + +#### Customizing the dremio.conf file + +The `dremio.conf` file gets overridden using the following parameters: + +- `dremio.dremioConf.configOverrides`: non-sensitive settings to be applied to *all Dremio nodes*. +- `dremio.dremioConf.secretConfigOverrides`: sensitive settings to be applied to *all Dremio nodes*. + +The parameters above are applied to all Dremio nodes. For more specific node settings, the chart uses the following parameters: + +-`masterCoordinator.dremioConf.configOverrides`: non-sensitive settings to be applied to *Dremio master coordinator nodes*. +-`masterCoordinator.dremioConf.secretConfigOverrides`: sensitive settings to be applied to *Dremio master coordinator nodes*. +-`coordinator.dremioConf.configOverrides`: non-sensitive settings to be applied to *Dremio coordinator nodes*. +-`coordinator.dremioConf.secretConfigOverrides`: sensitive settings to be applied to *Dremio coordinator nodes*. +-`executor.common.dremioConf.configOverrides`: non-sensitive settings to be applied to *Dremio executor nodes*. +-`executor.common.dremioConf.secretConfigOverrides`: sensitive settings to be applied to *Dremio executor nodes*. + +Using these parameters, the chart will generate ConfigMaps (with the non-sensitive settings) and Secrets (with the sensitive settings) for each Dremio component. Afterwards, an init-container will merge the information from the ConfigMap and the Secret generating the final `dremio.conf` file which gets mounted in `/opt/bitnami/dremio/conf`. + +> NOTE: The settings in the parameters above must be inserted in YAML format, which will get translated into HOCON-compatible flattened YAML. + +In the example below we override the upload path for all Dremio nodes and increase the token expiration time in master-coordinator nodes: + +```yaml +dremio: + dremioConf: + configOverrides: + paths.upload: /tmp/uploads + +masterCoordinator: + dremioConf: + configOverrides: + services.coordinator.web.tokens.cache.expiration_minutes: 20 +``` + +Check the [upstream Dremio documentation](https://docs.dremio.com/current/get-started/cluster-deployments/customizing-configuration/dremio-conf/) for the list of allowed settings. + +As an alternative, it is possible to provide existing ConfigMaps and Secrets with the `dremio.conf` configuration. This is done using the `*.dremioConf.existingSecret` and `*.dremioConf.existingConfigmap` parameters. + +#### Customizing the core-site.xml file + +The `core-site.xml` file can be customized with the follownig parameter: + +- `dremio.coreSite.appendConfiguration`: XML string that gets appended inside the `` section of the core-site.xml file. + +In the example below we disable SSL connection to the S3 backend: + +```yaml +dremio: + coreSite: + appendConfiguration: | + + fs.s3a.connection.ssl.enabled + Value can either be true or false, set to true to use SSL with a secure Minio server. + false + +``` + +As an alternative, it is possible to provide an existing Secret with the `core-site.xml` configuration. This is done using the `dremio.coreSite.existingSecret` parameter. + +Check the [upstream Dremio documentation](https://docs.dremio.com/current/get-started/cluster-deployments/customizing-configuration/dremio-conf/dist-store-config/) for the list of available settings in the `core-site.xml` file. + +#### Environment variables inside configuration files + +The chart allows adding Dremio configuration settings relative to environment vars. This is done by enclosing the environment variable inside `{{ }}`. An init container will render the environment variable using the [render-template](https://github.com/bitnami/render-template) tool. This is useful when having rotating secrets. + +For adding extra environment variables for rendering, set the `defaultInitContainers.generateConf.extraEnvVars` parameter. + +In the following example we add a property in the `core-site.xml` dependant to `AZURE_TOKEN` environment variable, which is part of a secret named `azure-secret` with key `token`. + +```yaml +dremio: + coreSite: + appendConfiguration: | + + dremio.azure.key + The shared access key for the storage account. + {{ AZURE_TOKEN }} + + +defaultInitContainers: + generateConf: + extraEnvVars: + - name: AZURE_TOKEN + valueFrom: + secretKeyRef: + name: azure-secret + key: token +``` + +#### Adding extra configuration files + +For advanced configurations such as editing files like `logback.xml`, it is possible to include extra configuration files in the `dremio.conf` ConfigMap or Secret using the following values: + +- `dremio.dremioConf.extraFiles`: Adds extra non-sensitive files. +- `dremio.dremioConf.extraSecretFiles`: Add extra sensitive files. + +In the following example we include a modified version of the `logback.xml` file: + +```yaml +dremio: + dremioConf: + extraFiles: + logback.xml: | + + + + + + %date{ISO8601} [%thread] %-5level %logger{36} - %msg%n + + + +``` + +> NOTE: Adding `dremio.conf` in `extraFiles` or `extraSecretFiles` fully overwrites the default dremio.conf file generated by the chart + +### Distributed Storage configuration + +The Bitnami Dremio chart natively supports `s3` as backend, either using AWS or MinIO(TM). This is configured using `dremio.distStorageType`, possible values are: `aws`, `minio` or `other`. E.g.: + +- `dremio.distStorageType`: `aws` + +It is possible to configure other distributed storage backends when setting `dremio.distStorageType` to `other`, but these require add extra configuration settings using the `*.dremioConf` and `*.coreSite`. In the sections below we detail some example distributed storage backends. Check the [upstream Dremio documentation](https://docs.dremio.com/current/get-started/cluster-deployments/customizing-configuration/dremio-conf/dist-store-config/) for the required settings in the `dremio.conf` and `core-site.xml` files. + +#### MinIO(TM) subchart as storage backend (default) + +Set the following parameters for using the embedded subchart: + +```yaml +dremio: + distStorageType: minio + +minio: + enabled: true +``` + +#### External MinIO(TM) as distributed storage + +For configuring an external MinIO(TM) installation, use the `externalS3` section (replace the `DREMIO_*` placeholders) + +```yaml +dremio: + distStorageType: minio + +minio: + enabled: false + +externalS3: + host: DREMIO_MINIO_HOST + port: DREMIO_MINIO_PORT + accessKeyID: DREMIO_ACCESS_KEY_ID + accessKeySecret: DREMIO_ACCESS_KEY_SECRET + bucket: DREMIO_BUCKET +``` + +#### AWS as distributed storage using access key authentication + +For configuring AWS as distributed storage, use the `externalS3` section (replace the `DREMIO_*` placeholders): + +```yaml +dremio: + distStorageType: minio + +minio: + enabled: false + +externalS3: + accessKeyID: DREMIO_ACCESS_KEY_ID + accessKeySecret: DREMIO_ACCESS_KEY_SECRET + bucket: DREMIO_BUCKET + regien: DREMIO_REGION +``` + +#### Azure Storage as distributed storage + +For configuring Azure Storage as distributed storage following the [upstream Dremio documentation](https://docs.dremio.com/current/get-started/cluster-deployments/customizing-configuration/dremio-conf/dist-store-config/#azure-storage), use the `dremio.dremioConf` and `dremio.coreSite` parameters (replace the `DREMIO_*` placeholders): + +```yaml +dremio: + distStorageType: other + dremioConf: + configOverrides: + paths.dist: "dremioAzureStorage://:///DREMIO_FILE_SYSTEM_NAME/DREMIO_ALTERNATIVE_STORAGE_ROOT_DIRECTORY" + coreSite: + appendConfiguration: | + + fs.dremioAzureStorage.impl + FileSystem implementation. Must always be com.dremio.plugins.azure.AzureStorageFileSystem + com.dremio.plugins.azure.AzureStorageFileSystem + + + dremio.azure.account + The name of the storage account. + DREMIO_ACCOUNT_NAME + + + dremio.azure.key + The shared access key for the storage account. + DREMIO_ACCESS_KEY + + + dremio.azure.mode + The storage account type. Value: STORAGE_V2 + STORAGE_V2 + + + dremio.azure.secure + Boolean option to enable SSL connections. Default: True Value: True/False + True + + +minio: + enabled: false +``` + +#### Google Cloud Storage as distributed storage + +For configuring Google Cloud Storage as distributed storage following the [upstream Dremio documentation](https://docs.dremio.com/current/get-started/cluster-deployments/customizing-configuration/dremio-conf/dist-store-config/#google-cloud-storage), use the `dremio.dremioConf` and `dremio.coreSite` parameters (replace the `DREMIO_*` placeholders): + +```yaml +dremio: + distStorageType: other + dremioConf: + configOverrides: + paths.dist: "dremiogcs:///DREMIO_BUCKET_NAME/DREMIO_BUCKET_FOLDER" + coreSite: + appendConfiguration: | + + dremio.gcs.whitelisted.buckets + GCS bucket to use for distributed storage + DREMIO_BUCKET_NAME + + + fs.dremiogcs.impl + The FileSystem implementation. Must be set to com.dremio.plugins.gcs.GoogleBucketFileSystem + com.dremio.plugins.gcs.GoogleBucketFileSystem + + + dremio.gcs.use_keyfile + Do not use the key file + false + + +minio: + enabled: false +``` + +### User authentication + +When the `dremio.auth.enabled` parameter is set to true, the chart will create a Job that automatically bootstraps a user using Dremio internal authentication mechanisms. The user is customized with the following parameters: + +- `dremio.auth.username`: Bootstrap username +- `dremio.auth.password`: Bootstrap password +- `dremio.auth.email`: Bootstrap email +- `dremio.auth.firstName`: Bootstrap first name +- `dremio.auth.lastName`: Bootstrap last name + +Also, it is possible to provide the password using an existing secret with the `dremio.auth.existingSecret` value. + +Other authentication mechanisms can be configured using the `dremioConf` and `coreSite` values. You could check [upstream Dremio documentation](https://docs.dremio.com/current/security/authentication/) for all the available options. + +### External Zookeeper support + +You may want to have Dremio connect to an external zookeeper rather than installing one inside your cluster. Typical reasons for this are to use a managed database service, or to share a common database server for all your applications. To achieve this, the chart allows you to specify credentials for an external database with the [`externalZookeeper` parameter](#parameters). You should also disable the Zookeeper installation with the `zookeeper.enabled` option. Here is an example: + +```console +zookeper.enabled=false +externalZookeeper.hosts[0]=myexternalhost +externalZookeeper.port=2181 +``` + +### TLS secrets + +TLS support for the Web interface can be enabled in the chart by specifying the `dremio.tls.enabled=true`while creating a release. Two possible options are available: + +- Provide your own secret with the PEM or JKS certificates +- Have the chart auto-generate the certificates. + +#### Providing your own TLS secret + +To provide your own secret set the `dremio.tls.existingSecret` value. It is possible to use PEM or JKS. + +To use PEM Certs: + +- `dremio.tls.usePemCerts=true`: Use PEM certificates instead of a JKS file. +- `dremio.tls.certFilename`: Certificate filename. Defaults to `tls.crt`. +- `dremio.tls.certKeyFilename`: Certificate key filename. Defaults to `tls.key` + +To use JKS keystore: + +- `dremio.tls.usePemCerts=false`: Use JKS file. +- `dremio.tls.keystoreFilename`: Certificate filename. Defaults to `dremio.jks`. + +In the following example we will use PEM certificates. First, create the secret with the certificates files: + +```console +kubectl create secret generic certificates-tls-secret --from-file=./cert.pem --from-file=./cert.key --from-file=./ca.pem +``` + +Then, use the following parameters: + +```console +dremio.tls.enabled="true" +dremio.tls.existingSecret="certificates-tls-secret" +dremio.tls.usePemCerts="true" +dremio.tls.certFilename="cert.pem" +dremio.tls.certKeyFilename="cert.key" +``` + +#### Auto-generation of TLS certificates + +It is also possible to rely on the chart certificate auto-generation capabilities. The chart supports two different ways to auto-generate the required certificates: + +- Using Helm capabilities. Enable this feature by setting `dremio.tls.autoGenerated.enabled` to `true` and `dremio.tls.autoGenerated.engine` to `helm`. +- Relying on CertManager (please note it's required to have CertManager installed in your K8s cluster). Enable this feature by setting `dremio.tls.autoGenerated.enabled` to `true` and `dremio.tls.autoGenerated.engine` to `cert-manager`. Please note it's supported to use an existing Issuer/ClusterIssuer for issuing the TLS certificates by setting the `dremio.tls.autoGenerated.certManager.existingIssuer` and `dremio.tls.autoGenerated.certManager.existingIssuerKind` parameters. + +### Ingress + +This chart provides support for Ingress resources. If you have an ingress controller installed on your cluster, such as [nginx-ingress-controller](https://github.com/bitnami/charts/tree/main/bitnami/nginx-ingress-controller) or [contour](https://github.com/bitnami/charts/tree/main/bitnami/contour) you can utilize it to serve your application.To enable Ingress integration, set `ingress.enabled` to `true`. + +The most common scenario is to have one host name mapped to the deployment. In this case, the `ingress.hostname` property can be used to set the host name. The `ingress.tls` parameter can be used to add the TLS configuration for this host. + +However, it is also possible to have more than one host. To facilitate this, the `ingress.extraHosts` parameter (if available) can be set with the host names specified as an array. The `ingress.extraTLS` parameter (if available) can also be used to add the TLS configuration for extra hosts. + +> NOTE: For each host specified in the `ingress.extraHosts` parameter, it is necessary to set a name, path, and any annotations that the Ingress controller should know about. Not all annotations are supported by all Ingress controllers, but [this annotation reference document](https://github.com/kubernetes/ingress-nginx/blob/master/docs/user-guide/nginx-configuration/annotations.md) lists the annotations supported by many popular Ingress controllers. + +Adding the TLS parameter (where available) will cause the chart to generate HTTPS URLs, and the application will be available on port 443. The actual TLS secrets do not have to be generated by this chart. However, if TLS is enabled, the Ingress record will not work until the TLS secret exists. + +[Learn more about Ingress controllers](https://kubernetes.io/docs/concepts/services-networking/ingress-controllers/). + +### Configure TLS Secrets for use with Ingress + +This chart facilitates the creation of TLS secrets for use with the Ingress controller (although this is not mandatory). There are several common use cases: + +- Generate certificate secrets based on chart parameters. +- Enable externally generated certificates. +- Manage application certificates via an external service (like [cert-manager](https://github.com/jetstack/cert-manager/)). +- Create self-signed certificates within the chart (if supported). + +In the first two cases, a certificate and a key are needed. Files are expected in `.pem` format. + +Here is an example of a certificate file: + +> NOTE: There may be more than one certificate if there is a certificate chain. + +```text +-----BEGIN CERTIFICATE----- +MIID6TCCAtGgAwIBAgIJAIaCwivkeB5EMA0GCSqGSIb3DQEBCwUAMFYxCzAJBgNV +... +jScrvkiBO65F46KioCL9h5tDvomdU1aqpI/CBzhvZn1c0ZTf87tGQR8NK7v7 +-----END CERTIFICATE----- +``` + +Here is an example of a certificate key: + +```text +-----BEGIN RSA PRIVATE KEY----- +MIIEogIBAAKCAQEAvLYcyu8f3skuRyUgeeNpeDvYBCDcgq+LsWap6zbX5f8oLqp4 +... +wrj2wDbCDCFmfqnSJ+dKI3vFLlEz44sAV8jX/kd4Y6ZTQhlLbYc= +-----END RSA PRIVATE KEY----- +``` + +- If using Helm to manage the certificates based on the parameters, copy these values into the `certificate` and `key` parameters for a given `*.ingress.secrets` entry. +- If managing TLS secrets separately, it is necessary to create a TLS secret with name `INGRESS_HOSTNAME-tls` (where INGRESS_HOSTNAME is a placeholder to be replaced with the hostname you set using the `*.ingress.hostname` parameter). +- If your cluster has a [cert-manager](https://github.com/jetstack/cert-manager) add-on to automate the management and issuance of TLS certificates, add to `*.ingress.annotations` the [corresponding ones](https://cert-manager.io/docs/usage/ingress/#supported-annotations) for cert-manager. +- If using self-signed certificates created by Helm, set both `*.ingress.tls` and `*.ingress.selfSigned` to `true`. + +### Dremio Executor configuration + +The charts deploys a default executor using the configuration inside the `executor.common` section. It is possible to define extra group of executor nodes using the `executor.engines` parameter. Each element inside the `executor.engines` array has the following parameters: + +-`name`: Name of the group of executors (engine). +-`overrides`: Perform overrides over the parameters in the `executor.common` section. + +In the following example we define an extra group of executors, modifying the default `replicaCount` set in the `common` section: + +```yaml +executor: + common: + replicaCount: 1 + engines: + - name: default # This group will have 1 replica + overrides: {} + - name: special # This group will have 3 replicas + overrides: + replicaCount: 3 +``` + +### Additional environment variables + +In case you want to add extra environment variables (useful for advanced operations like custom init scripts), you can use the `extraEnvVars` property. + +```yaml +masterCoordinator: + extraEnvVars: + - name: LOG_LEVEL + value: error +``` + +Alternatively, you can use a ConfigMap or a Secret with the environment variables. To do so, use the `extraEnvVarsCM` or the `extraEnvVarsSecret` parameters. + +### Sidecars + +If additional containers are needed in the same pod as dremio (such as additional metrics or logging exporters), they can be defined using the `sidecars` parameter. + +```yaml +masterCoordinator: + sidecars: + - name: your-image-name + image: your-image + imagePullPolicy: Always + ports: + - name: portname + containerPort: 1234 +``` + +If these sidecars export extra ports, extra port definitions can be added using the `service.extraPorts` parameter (where available), as shown in the example below: + +```yaml +service: + extraPorts: + - name: extraPort + port: 11311 + targetPort: 11311 +``` + +> NOTE: This Helm chart already includes sidecar containers for the Prometheus exporters (where applicable). These can be activated by adding the `--enable-metrics=true` parameter at deployment time. The `sidecars` parameter should therefore only be used for any extra sidecar containers. + +If additional init containers are needed in the same pod, they can be defined using the `initContainers` parameter. Here is an example: + +```yaml +masterCoordinator: + initContainers: + - name: your-image-name + image: your-image + imagePullPolicy: Always + ports: + - name: portname + containerPort: 1234 +``` + +Learn more about [sidecar containers](https://kubernetes.io/docs/concepts/workloads/pods/) and [init containers](https://kubernetes.io/docs/concepts/workloads/pods/init-containers/). + +### Pod affinity + +This chart allows you to set your custom affinity using the `affinity` parameter. Find more information about Pod affinity in the [kubernetes documentation](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity). + +As an alternative, use one of the preset configurations for pod affinity, pod anti-affinity, and node affinity available at the [bitnami/common](https://github.com/bitnami/charts/tree/main/bitnami/common#affinities) chart. To do so, set the `podAffinityPreset`, `podAntiAffinityPreset`, or `nodeAffinityPreset` parameters. + +## Persistence + +The [Bitnami dremio](https://github.com/bitnami/containers/tree/main/bitnami/dremio) image stores the dremio data and configurations at the `/bitnami` path of the container. Persistent Volume Claims are used to keep the data across deployments. + +If you encounter errors when working with persistent volumes, refer to our [troubleshooting guide for persistent volumes](https://docs.bitnami.com/kubernetes/faq/troubleshooting/troubleshooting-persistence-volumes/). + +### Deploying extra resources + +There are cases where you may want to deploy extra objects, such a ConfigMap containing your app's configuration or some extra deployment with a micro service used by your app. For covering this case, the chart allows adding the full specification of other objects using the `extraDeploy` parameter. + +## Parameters + +### Global parameters + +| Name | Description | Value | +| ----------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------ | +| `global.imageRegistry` | Global Docker image registry | `""` | +| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` | +| `global.storageClass` | Global StorageClass for Persistent Volume(s) | `""` | +| `global.compatibility.openshift.adaptSecurityContext` | Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation) | `auto` | + +### Common parameters + +| Name | Description | Value | +| ------------------------ | --------------------------------------------------------------------------------------- | --------------- | +| `kubeVersion` | Override Kubernetes version | `""` | +| `nameOverride` | String to partially override common.names.name | `""` | +| `fullnameOverride` | String to fully override common.names.fullname | `""` | +| `namespaceOverride` | String to fully override common.names.namespace | `""` | +| `commonLabels` | Labels to add to all deployed objects | `{}` | +| `commonAnnotations` | Annotations to add to all deployed objects | `{}` | +| `clusterDomain` | Kubernetes cluster domain name | `cluster.local` | +| `extraDeploy` | Array of extra objects to deploy with the release | `[]` | +| `diagnosticMode.enabled` | Enable diagnostic mode (all probes will be disabled and the command will be overridden) | `false` | +| `diagnosticMode.command` | Command to override all containers in the chart release | `["sleep"]` | +| `diagnosticMode.args` | Args to override all containers in the chart release | `["infinity"]` | +| `usePasswordFile` | Mount secrets as files | `true` | + +### Dremio common configuration settings + +| Name | Description | Value | +| --------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------ | +| `dremio.image.registry` | Dremio image registry | `REGISTRY_NAME` | +| `dremio.image.repository` | Dremio image repository | `REPOSITORY_NAME/dremio` | +| `dremio.image.digest` | Dremio image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag image tag (immutable tags are recommended) | `""` | +| `dremio.image.pullPolicy` | Dremio image pull policy | `IfNotPresent` | +| `dremio.image.pullSecrets` | Dremio image pull secrets | `[]` | +| `dremio.image.debug` | Enable Dremio image debug mode | `false` | +| `dremio.auth.enabled` | Automatically bootstrap a Dremio user | `true` | +| `dremio.auth.username` | Dremio bootstrap username | `user` | +| `dremio.auth.password` | Dremio bootstrap password | `""` | +| `dremio.auth.firstName` | Dremio bootstrap first name | `User` | +| `dremio.auth.lastName` | Dremio bootstrap last name | `User` | +| `dremio.auth.email` | Dremio bootstrap email | `user@example.com` | +| `dremio.auth.existingSecret` | Name of a secret containing the password of the bootstrap user | `""` | +| `dremio.auth.existingSecretKey` | Key inside the secret containing the password of the bootstrap user (requires setting existingSecret) | `""` | +| `dremio.tls.enabled` | Enable TLS in the web frontend | `false` | +| `dremio.tls.usePemCerts` | Use certificates in .pem format | `true` | +| `dremio.tls.existingSecret` | Name of a secret containing the certificate files | `""` | +| `dremio.tls.certFilename` | Filename inside the secret of the .crt file (when usePemCerts=true) | `tls.crt` | +| `dremio.tls.certKeyFilename` | Filename inside the secret of the .key file (when usePemCerts=true) | `tls.key` | +| `dremio.tls.keystoreFilename` | Filename inside the secret of the .jks file (when usePemCerts=false) | `dremio.jks` | +| `dremio.tls.password` | Password of the Java keystore | `""` | +| `dremio.tls.passwordSecret` | Name of a secret containing the password of the Java keystore | `""` | +| `dremio.tls.autoGenerated.enabled` | Enable automatic generation of certificates for TLS | `true` | +| `dremio.tls.autoGenerated.engine` | Mechanism to generate the certificates (allowed values: helm, cert-manager) | `helm` | +| `dremio.tls.autoGenerated.certManager.existingIssuer` | The name of an existing Issuer to use for generating the certificates (only for `cert-manager` engine) | `""` | +| `dremio.tls.autoGenerated.certManager.existingIssuerKind` | Existing Issuer kind, defaults to Issuer (only for `cert-manager` engine) | `""` | +| `dremio.tls.autoGenerated.certManager.keyAlgorithm` | Key algorithm for the certificates (only for `cert-manager` engine) | `RSA` | +| `dremio.tls.autoGenerated.certManager.keySize` | Key size for the certificates (only for `cert-manager` engine) | `2048` | +| `dremio.tls.autoGenerated.certManager.duration` | Duration for the certificates (only for `cert-manager` engine) | `2160h` | +| `dremio.tls.autoGenerated.certManager.renewBefore` | Renewal period for the certificates (only for `cert-manager` engine) | `360h` | +| `dremio.distStorageType` | Dremio distributed storage type. Allowed values: "minio", "aws" and "others" ("minio" and "aws" natively supported, the rest of the types requires adding extra configuration parameters in the "dremio.dremioConf" and "dremio.coreSite" sections) | `minio` | +| `dremio.dremioConf.configOverrides` | Add configuration overrides in dremio.conf applied to all components (using YAML format) | `{}` | +| `dremio.dremioConf.secretConfigOverrides` | Add sensitive configuration overrides in dremio.conf applied to all components (using YAML format) | `{}` | +| `dremio.dremioConf.extraFiles` | Add extra configuration files | `{}` | +| `dremio.dremioConf.extraSecretFiles` | Add extra sensitive configuration files | `{}` | +| `dremio.coreSite.appendConfiguration` | Add extra configuration in the core-site.xml file (in XML format) | `""` | +| `dremio.coreSite.existingSecret` | Name of a secret containing the core-site.xml file | `""` | +| `dremio.containerPorts.web` | Dremio Web container port | `9047` | +| `dremio.containerPorts.client` | Dremio client container port | `31010` | +| `dremio.containerPorts.flight` | Dremio flight container port | `32010` | +| `dremio.containerPorts.fabric` | Dremio fabric container port | `45678` | +| `dremio.containerPorts.conduit` | Dremio conduit container port | `45679` | +| `dremio.containerPorts.jmx` | Dremio JMX container port | `50000` | +| `dremio.containerPorts.liveness` | Dremio liveness container port | `44349` | + +### Dremio Master Coordinator Parameters + +| Name | Description | Value | +| --------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------- | +| `masterCoordinator.replicaCount` | Number of Dremio Master Coordinator replicas to deploy | `1` | +| `masterCoordinator.extraContainerPorts` | Optionally specify extra list of additional ports for Dremio Master Coordinator containers | `[]` | +| `masterCoordinator.extraJavaOpts` | Add extra Java opts | `""` | +| `masterCoordinator.livenessProbe.enabled` | Enable livenessProbe on Dremio Master Coordinator containers | `true` | +| `masterCoordinator.livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `20` | +| `masterCoordinator.livenessProbe.periodSeconds` | Period seconds for livenessProbe | `10` | +| `masterCoordinator.livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `5` | +| `masterCoordinator.livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `5` | +| `masterCoordinator.livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `masterCoordinator.readinessProbe.enabled` | Enable readinessProbe on Dremio Master Coordinator containers | `true` | +| `masterCoordinator.readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `10` | +| `masterCoordinator.readinessProbe.periodSeconds` | Period seconds for readinessProbe | `10` | +| `masterCoordinator.readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `5` | +| `masterCoordinator.readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `5` | +| `masterCoordinator.readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `masterCoordinator.startupProbe.enabled` | Enable startupProbe on Dremio Master Coordinator containers | `false` | +| `masterCoordinator.startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `10` | +| `masterCoordinator.startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `masterCoordinator.startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `5` | +| `masterCoordinator.startupProbe.failureThreshold` | Failure threshold for startupProbe | `5` | +| `masterCoordinator.startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `masterCoordinator.customLivenessProbe` | Custom livenessProbe that overrides the default one | `{}` | +| `masterCoordinator.customReadinessProbe` | Custom readinessProbe that overrides the default one | `{}` | +| `masterCoordinator.customStartupProbe` | Custom startupProbe that overrides the default one | `{}` | +| `masterCoordinator.resourcesPreset` | Set Dremio Master Coordinator container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if masterCoordinator.resources is set (masterCoordinator.resources is recommended for production). | `xlarge` | +| `masterCoordinator.resources` | Set Dremio Master Coordinator container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `masterCoordinator.podSecurityContext.enabled` | Enable Dremio Master Coordinator pods' Security Context | `true` | +| `masterCoordinator.podSecurityContext.fsGroupChangePolicy` | Set filesystem group change policy for Dremio Master Coordinator pods | `Always` | +| `masterCoordinator.podSecurityContext.sysctls` | Set kernel settings using the sysctl interface for Dremio Master Coordinator pods | `[]` | +| `masterCoordinator.podSecurityContext.supplementalGroups` | Set filesystem extra groups for Dremio Master Coordinator pods | `[]` | +| `masterCoordinator.podSecurityContext.fsGroup` | Set fsGroup in Dremio Master Coordinator pods' Security Context | `1001` | +| `masterCoordinator.containerSecurityContext.enabled` | Enabled Dremio Master Coordinator container' Security Context | `true` | +| `masterCoordinator.containerSecurityContext.seLinuxOptions` | Set SELinux options in Dremio Master Coordinator container | `{}` | +| `masterCoordinator.containerSecurityContext.runAsUser` | Set runAsUser in Dremio Master Coordinator container' Security Context | `1001` | +| `masterCoordinator.containerSecurityContext.runAsGroup` | Set runAsGroup in Dremio Master Coordinator container' Security Context | `1001` | +| `masterCoordinator.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Dremio Master Coordinator container' Security Context | `true` | +| `masterCoordinator.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Dremio Master Coordinator container' Security Context | `true` | +| `masterCoordinator.containerSecurityContext.privileged` | Set privileged in Dremio Master Coordinator container' Security Context | `false` | +| `masterCoordinator.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Dremio Master Coordinator container' Security Context | `false` | +| `masterCoordinator.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Dremio Master Coordinator container | `["ALL"]` | +| `masterCoordinator.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Dremio Master Coordinator container | `RuntimeDefault` | +| `masterCoordinator.command` | Override default Dremio Master Coordinator container command (useful when using custom images) | `[]` | +| `masterCoordinator.args` | Override default Dremio Master Coordinator container args (useful when using custom images) | `[]` | +| `masterCoordinator.automountServiceAccountToken` | Mount Service Account token in Dremio Master Coordinator pods | `false` | +| `masterCoordinator.hostAliases` | Dremio Master Coordinator pods host aliases | `[]` | +| `masterCoordinator.statefulsetAnnotations` | Annotations for Dremio Master Coordinator statefulset | `{}` | +| `masterCoordinator.podLabels` | Extra labels for Dremio Master Coordinator pods | `{}` | +| `masterCoordinator.podAnnotations` | Annotations for Dremio Master Coordinator pods | `{}` | +| `masterCoordinator.podAffinityPreset` | Pod affinity preset. Ignored if `masterCoordinator.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `masterCoordinator.podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `masterCoordinator.affinity` is set. Allowed values: `soft` or `hard` | `soft` | +| `masterCoordinator.dremioConf.configOverrides` | Add configuration overrides in dremio.conf applied to all master-coordinator nodes (using YAML format) | `{}` | +| `masterCoordinator.dremioConf.secretConfigOverrides` | Add sensitive configuration overrides in dremio.conf applied to master-coordinator nodes (using YAML format) | `{}` | +| `masterCoordinator.dremioConf.extraFiles` | Add extra files to the ConfigMap | `{}` | +| `masterCoordinator.dremioConf.extraSecretFiles` | Add extra files to the Secret | `{}` | +| `masterCoordinator.dremioConf.existingConfigmap` | Name of a configmap containing a dremio.conf configuration file for the master-coordinator nodes (without sensitive information) | `""` | +| `masterCoordinator.dremioConf.existingSecret` | Name of a secret containing a dremio.conf configuration file for the master-coordinator nodes (with sensitive information) | `""` | +| `masterCoordinator.nodeAffinityPreset.type` | Node affinity preset type. Ignored if `masterCoordinator.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `masterCoordinator.nodeAffinityPreset.key` | Node label key to match. Ignored if `masterCoordinator.affinity` is set | `""` | +| `masterCoordinator.nodeAffinityPreset.values` | Node label values to match. Ignored if `masterCoordinator.affinity` is set | `[]` | +| `masterCoordinator.affinity` | Affinity for Dremio Master Coordinator pods assignment | `{}` | +| `masterCoordinator.nodeSelector` | Node labels for Dremio Master Coordinator pods assignment | `{}` | +| `masterCoordinator.tolerations` | Tolerations for Dremio Master Coordinator pods assignment | `[]` | +| `masterCoordinator.updateStrategy.type` | Dremio Master Coordinator statefulset strategy type | `RollingUpdate` | +| `masterCoordinator.podManagementPolicy` | Pod management policy for Dremio Master Coordinator statefulset | `OrderedReady` | +| `masterCoordinator.priorityClassName` | Dremio Master Coordinator pods' priorityClassName | `""` | +| `masterCoordinator.topologySpreadConstraints` | Topology Spread Constraints for Dremio Master Coordinator pod assignment spread across your cluster among failure-domains | `[]` | +| `masterCoordinator.schedulerName` | Name of the k8s scheduler (other than default) for Dremio Master Coordinator pods | `""` | +| `masterCoordinator.terminationGracePeriodSeconds` | Seconds Dremio Master Coordinator pods need to terminate gracefully | `""` | +| `masterCoordinator.lifecycleHooks` | for Dremio Master Coordinator containers to automate configuration before or after startup | `{}` | +| `masterCoordinator.extraEnvVars` | Array with extra environment variables to add to Dremio Master Coordinator containers | `[]` | +| `masterCoordinator.extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars for Dremio Master Coordinator containers | `""` | +| `masterCoordinator.extraEnvVarsSecret` | Name of existing Secret containing extra env vars for Dremio Master Coordinator containers | `""` | +| `masterCoordinator.extraVolumes` | Optionally specify extra list of additional volumes for the Dremio Master Coordinator pods | `[]` | +| `masterCoordinator.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for the Dremio Master Coordinator containers | `[]` | +| `masterCoordinator.sidecars` | Add additional sidecar containers to the Dremio Master Coordinator pods | `[]` | +| `masterCoordinator.initContainers` | Add additional init containers to the Dremio Master Coordinator pods | `[]` | +| `masterCoordinator.pdb.create` | Enable/disable a Pod Disruption Budget creation | `true` | +| `masterCoordinator.pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` | +| `masterCoordinator.pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `masterCoordinator.pdb.minAvailable` and `masterCoordinator.pdb.maxUnavailable` are empty. | `""` | +| `masterCoordinator.autoscaling.vpa.enabled` | Enable VPA for Dremio Master Coordinator pods | `false` | +| `masterCoordinator.autoscaling.vpa.annotations` | Annotations for VPA resource | `{}` | +| `masterCoordinator.autoscaling.vpa.controlledResources` | VPA List of resources that the vertical pod autoscaler can control. Defaults to cpu and memory | `[]` | +| `masterCoordinator.autoscaling.vpa.maxAllowed` | VPA Max allowed resources for the pod | `{}` | +| `masterCoordinator.autoscaling.vpa.minAllowed` | VPA Min allowed resources for the pod | `{}` | +| `masterCoordinator.autoscaling.vpa.updatePolicy.updateMode` | Autoscaling update policy | `Auto` | +| `masterCoordinator.autoscaling.hpa.enabled` | Enable HPA for Dremio Master Coordinator pods | `false` | +| `masterCoordinator.autoscaling.hpa.minReplicas` | Minimum number of replicas | `""` | +| `masterCoordinator.autoscaling.hpa.maxReplicas` | Maximum number of replicas | `""` | +| `masterCoordinator.autoscaling.hpa.targetCPU` | Target CPU utilization percentage | `""` | +| `masterCoordinator.autoscaling.hpa.targetMemory` | Target Memory utilization percentage | `""` | +| `masterCoordinator.networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` | +| `masterCoordinator.networkPolicy.allowExternal` | Don't require server label for connections | `true` | +| `masterCoordinator.networkPolicy.allowExternalEgress` | Allow the pod to access any range of port and all destinations. | `true` | +| `masterCoordinator.networkPolicy.addExternalClientAccess` | Allow access from pods with client label set to "true". Ignored if `networkPolicy.allowExternal` is true. | `true` | +| `masterCoordinator.networkPolicy.extraIngress` | Add extra ingress rules to the NetworkPolicy | `[]` | +| `masterCoordinator.networkPolicy.extraEgress` | Add extra ingress rules to the NetworkPolicy (ignored if allowExternalEgress=true) | `[]` | +| `masterCoordinator.networkPolicy.ingressPodMatchLabels` | Labels to match to allow traffic from other pods. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `masterCoordinator.networkPolicy.ingressNSMatchLabels` | Labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `masterCoordinator.networkPolicy.ingressNSPodMatchLabels` | Pod labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `masterCoordinator.persistence.enabled` | Enable persistence using Persistent Volume Claims | `true` | +| `masterCoordinator.persistence.mountPath` | Path to mount the volume at. | `/bitnami/dremio/data` | +| `masterCoordinator.persistence.subPath` | The subdirectory of the volume to mount to, useful in dev environments and one PV for multiple services | `""` | +| `masterCoordinator.persistence.storageClass` | Storage class of backing PVC | `""` | +| `masterCoordinator.persistence.annotations` | Persistent Volume Claim annotations | `{}` | +| `masterCoordinator.persistence.accessModes` | Persistent Volume Access Modes | `["ReadWriteOnce"]` | +| `masterCoordinator.persistence.size` | Size of data volume | `8Gi` | +| `masterCoordinator.persistence.existingClaim` | The name of an existing PVC to use for persistence | `""` | +| `masterCoordinator.persistence.selector` | Selector to match an existing Persistent Volume for WordPress data PVC | `{}` | +| `masterCoordinator.persistence.dataSource` | Custom PVC data source | `{}` | +| `masterCoordinator.serviceAccount.create` | Specifies whether a ServiceAccount should be created | `true` | +| `masterCoordinator.serviceAccount.name` | The name of the ServiceAccount to use. | `""` | +| `masterCoordinator.serviceAccount.annotations` | Additional Service Account annotations (evaluated as a template) | `{}` | +| `masterCoordinator.serviceAccount.automountServiceAccountToken` | Automount service account token for the server service account | `false` | + +### Dremio Coordinator Parameters + +| Name | Description | Value | +| --------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------- | +| `coordinator.replicaCount` | Number of Dremio Coordinator replicas to deploy | `1` | +| `coordinator.extraContainerPorts` | Optionally specify extra list of additional ports for Dremio Coordinator containers | `[]` | +| `coordinator.extraJavaOpts` | Add extra Java opts | `""` | +| `coordinator.livenessProbe.enabled` | Enable livenessProbe on Dremio Coordinator containers | `true` | +| `coordinator.livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `20` | +| `coordinator.livenessProbe.periodSeconds` | Period seconds for livenessProbe | `10` | +| `coordinator.livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `5` | +| `coordinator.livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `5` | +| `coordinator.livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `coordinator.readinessProbe.enabled` | Enable readinessProbe on Dremio Coordinator containers | `true` | +| `coordinator.readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `10` | +| `coordinator.readinessProbe.periodSeconds` | Period seconds for readinessProbe | `10` | +| `coordinator.readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `5` | +| `coordinator.readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `5` | +| `coordinator.readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `coordinator.startupProbe.enabled` | Enable startupProbe on Dremio Coordinator containers | `false` | +| `coordinator.startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `10` | +| `coordinator.startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `coordinator.startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `5` | +| `coordinator.startupProbe.failureThreshold` | Failure threshold for startupProbe | `5` | +| `coordinator.startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `coordinator.customLivenessProbe` | Custom livenessProbe that overrides the default one | `{}` | +| `coordinator.customReadinessProbe` | Custom readinessProbe that overrides the default one | `{}` | +| `coordinator.customStartupProbe` | Custom startupProbe that overrides the default one | `{}` | +| `coordinator.resourcesPreset` | Set Dremio Coordinator container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if coordinator.resources is set (coordinator.resources is recommended for production). | `xlarge` | +| `coordinator.resources` | Set Dremio Coordinator container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `coordinator.podSecurityContext.enabled` | Enable Dremio Coordinator pods' Security Context | `true` | +| `coordinator.podSecurityContext.fsGroupChangePolicy` | Set filesystem group change policy for Dremio Coordinator pods | `Always` | +| `coordinator.podSecurityContext.sysctls` | Set kernel settings using the sysctl interface for Dremio Coordinator pods | `[]` | +| `coordinator.podSecurityContext.supplementalGroups` | Set filesystem extra groups for Dremio Coordinator pods | `[]` | +| `coordinator.podSecurityContext.fsGroup` | Set fsGroup in Dremio Coordinator pods' Security Context | `1001` | +| `coordinator.containerSecurityContext.enabled` | Enabled Dremio Coordinator container' Security Context | `true` | +| `coordinator.containerSecurityContext.seLinuxOptions` | Set SELinux options in Dremio Coordinator container | `{}` | +| `coordinator.containerSecurityContext.runAsUser` | Set runAsUser in Dremio Coordinator container' Security Context | `1001` | +| `coordinator.containerSecurityContext.runAsGroup` | Set runAsGroup in Dremio Coordinator container' Security Context | `1001` | +| `coordinator.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Dremio Coordinator container' Security Context | `true` | +| `coordinator.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Dremio Coordinator container' Security Context | `true` | +| `coordinator.containerSecurityContext.privileged` | Set privileged in Dremio Coordinator container' Security Context | `false` | +| `coordinator.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Dremio Coordinator container' Security Context | `false` | +| `coordinator.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Dremio Coordinator container | `["ALL"]` | +| `coordinator.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Dremio Coordinator container | `RuntimeDefault` | +| `coordinator.command` | Override default Dremio Coordinator container command (useful when using custom images) | `[]` | +| `coordinator.args` | Override default Dremio Coordinator container args (useful when using custom images) | `[]` | +| `coordinator.automountServiceAccountToken` | Mount Service Account token in Dremio Coordinator pods | `false` | +| `coordinator.hostAliases` | Dremio Coordinator pods host aliases | `[]` | +| `coordinator.statefulsetAnnotations` | Annotations for Dremio Coordinator statefulset | `{}` | +| `coordinator.podLabels` | Extra labels for Dremio Coordinator pods | `{}` | +| `coordinator.podAnnotations` | Annotations for Dremio Coordinator pods | `{}` | +| `coordinator.podAffinityPreset` | Pod affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `coordinator.podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` | `soft` | +| `coordinator.dremioConf.configOverrides` | Add configuration overrides in dremio.conf applied to all coordinator nodes (using YAML format) | `{}` | +| `coordinator.dremioConf.secretConfigOverrides` | Add sensitive configuration overrides in dremio.conf applied to coordinator nodes (using YAML format) | `{}` | +| `coordinator.dremioConf.extraFiles` | Add extra files to the ConfigMap | `{}` | +| `coordinator.dremioConf.extraSecretFiles` | Add extra files to the Secret | `{}` | +| `coordinator.dremioConf.existingConfigmap` | Name of a configmap containing a dremio.conf configuration file for the coordinator nodes (without sensitive information) | `""` | +| `coordinator.dremioConf.existingSecret` | Name of a secret containing a dremio.conf configuration file for the coordinator nodes (with sensitive information) | `""` | +| `coordinator.nodeAffinityPreset.type` | Node affinity preset type. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `coordinator.nodeAffinityPreset.key` | Node label key to match. Ignored if `coordinator.affinity` is set | `""` | +| `coordinator.nodeAffinityPreset.values` | Node label values to match. Ignored if `coordinator.affinity` is set | `[]` | +| `coordinator.affinity` | Affinity for Dremio Coordinator pods assignment | `{}` | +| `coordinator.nodeSelector` | Node labels for Dremio Coordinator pods assignment | `{}` | +| `coordinator.tolerations` | Tolerations for Dremio Coordinator pods assignment | `[]` | +| `coordinator.updateStrategy.type` | Dremio Coordinator statefulset strategy type | `RollingUpdate` | +| `coordinator.podManagementPolicy` | Pod management policy for Dremio Coordinator statefulset | `OrderedReady` | +| `coordinator.priorityClassName` | Dremio Coordinator pods' priorityClassName | `""` | +| `coordinator.topologySpreadConstraints` | Topology Spread Constraints for Dremio Coordinator pod assignment spread across your cluster among failure-domains | `[]` | +| `coordinator.schedulerName` | Name of the k8s scheduler (other than default) for Dremio Coordinator pods | `""` | +| `coordinator.terminationGracePeriodSeconds` | Seconds Dremio Coordinator pods need to terminate gracefully | `""` | +| `coordinator.lifecycleHooks` | for Dremio Coordinator containers to automate configuration before or after startup | `{}` | +| `coordinator.extraEnvVars` | Array with extra environment variables to add to Dremio Coordinator containers | `[]` | +| `coordinator.extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars for Dremio Coordinator containers | `""` | +| `coordinator.extraEnvVarsSecret` | Name of existing Secret containing extra env vars for Dremio Coordinator containers | `""` | +| `coordinator.extraVolumes` | Optionally specify extra list of additional volumes for the Dremio Coordinator pods | `[]` | +| `coordinator.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for the Dremio Coordinator containers | `[]` | +| `coordinator.sidecars` | Add additional sidecar containers to the Dremio Coordinator pods | `[]` | +| `coordinator.initContainers` | Add additional init containers to the Dremio Coordinator pods | `[]` | +| `coordinator.pdb.create` | Enable/disable a Pod Disruption Budget creation | `true` | +| `coordinator.pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` | +| `coordinator.pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `coordinator.pdb.minAvailable` and `coordinator.pdb.maxUnavailable` are empty. | `""` | +| `coordinator.autoscaling.vpa.enabled` | Enable VPA for Dremio Coordinator pods | `false` | +| `coordinator.autoscaling.vpa.annotations` | Annotations for VPA resource | `{}` | +| `coordinator.autoscaling.vpa.controlledResources` | VPA List of resources that the vertical pod autoscaler can control. Defaults to cpu and memory | `[]` | +| `coordinator.autoscaling.vpa.maxAllowed` | VPA Max allowed resources for the pod | `{}` | +| `coordinator.autoscaling.vpa.minAllowed` | VPA Min allowed resources for the pod | `{}` | +| `coordinator.autoscaling.vpa.updatePolicy.updateMode` | Autoscaling update policy | `Auto` | +| `coordinator.autoscaling.hpa.enabled` | Enable HPA for Dremio Coordinator pods | `false` | +| `coordinator.autoscaling.hpa.minReplicas` | Minimum number of replicas | `""` | +| `coordinator.autoscaling.hpa.maxReplicas` | Maximum number of replicas | `""` | +| `coordinator.autoscaling.hpa.targetCPU` | Target CPU utilization percentage | `""` | +| `coordinator.autoscaling.hpa.targetMemory` | Target Memory utilization percentage | `""` | +| `coordinator.networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` | +| `coordinator.networkPolicy.allowExternal` | Don't require server label for connections | `true` | +| `coordinator.networkPolicy.allowExternalEgress` | Allow the pod to access any range of port and all destinations. | `true` | +| `coordinator.networkPolicy.addExternalClientAccess` | Allow access from pods with client label set to "true". Ignored if `networkPolicy.allowExternal` is true. | `true` | +| `coordinator.networkPolicy.extraIngress` | Add extra ingress rules to the NetworkPolicy | `[]` | +| `coordinator.networkPolicy.extraEgress` | Add extra ingress rules to the NetworkPolicy (ignored if allowExternalEgress=true) | `[]` | +| `coordinator.networkPolicy.ingressPodMatchLabels` | Labels to match to allow traffic from other pods. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `coordinator.networkPolicy.ingressNSMatchLabels` | Labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `coordinator.networkPolicy.ingressNSPodMatchLabels` | Pod labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `coordinator.persistence.enabled` | Enable persistence using Persistent Volume Claims | `true` | +| `coordinator.persistence.mountPath` | Path to mount the volume at. | `/bitnami/dremio/data` | +| `coordinator.persistence.subPath` | The subdirectory of the volume to mount to, useful in dev environments and one PV for multiple services | `""` | +| `coordinator.persistence.storageClass` | Storage class of backing PVC | `""` | +| `coordinator.persistence.annotations` | Persistent Volume Claim annotations | `{}` | +| `coordinator.persistence.accessModes` | Persistent Volume Access Modes | `["ReadWriteOnce"]` | +| `coordinator.persistence.size` | Size of data volume | `8Gi` | +| `coordinator.persistence.existingClaim` | The name of an existing PVC to use for persistence | `""` | +| `coordinator.persistence.selector` | Selector to match an existing Persistent Volume for WordPress data PVC | `{}` | +| `coordinator.persistence.dataSource` | Custom PVC data source | `{}` | +| `coordinator.serviceAccount.create` | Specifies whether a ServiceAccount should be created | `true` | +| `coordinator.serviceAccount.name` | The name of the ServiceAccount to use. | `""` | +| `coordinator.serviceAccount.annotations` | Additional Service Account annotations (evaluated as a template) | `{}` | +| `coordinator.serviceAccount.automountServiceAccountToken` | Automount service account token for the server service account | `false` | + +### Dremio Executor common Parameters + +| Name | Description | Value | +| ------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------- | +| `executor.common.replicaCount` | Number of Dremio Executor replicas to deploy | `1` | +| `executor.common.extraContainerPorts` | Optionally specify extra list of additional ports for Dremio Executor containers | `[]` | +| `executor.common.extraJavaOpts` | Add extra Java opts | `""` | +| `executor.common.livenessProbe.enabled` | Enable livenessProbe on Dremio Executor containers | `true` | +| `executor.common.livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `20` | +| `executor.common.livenessProbe.periodSeconds` | Period seconds for livenessProbe | `10` | +| `executor.common.livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `5` | +| `executor.common.livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `5` | +| `executor.common.livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `executor.common.readinessProbe.enabled` | Enable readinessProbe on Dremio Executor containers | `true` | +| `executor.common.readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `10` | +| `executor.common.readinessProbe.periodSeconds` | Period seconds for readinessProbe | `10` | +| `executor.common.readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `5` | +| `executor.common.readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `5` | +| `executor.common.readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `executor.common.startupProbe.enabled` | Enable startupProbe on Dremio Executor containers | `false` | +| `executor.common.startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `10` | +| `executor.common.startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `executor.common.startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `5` | +| `executor.common.startupProbe.failureThreshold` | Failure threshold for startupProbe | `5` | +| `executor.common.startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `executor.common.customLivenessProbe` | Custom livenessProbe that overrides the default one | `{}` | +| `executor.common.customReadinessProbe` | Custom readinessProbe that overrides the default one | `{}` | +| `executor.common.customStartupProbe` | Custom startupProbe that overrides the default one | `{}` | +| `executor.common.resourcesPreset` | Set Dremio Executor container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if coordinator.resources is set (coordinator.resources is recommended for production). | `xlarge` | +| `executor.common.resources` | Set Dremio Executor container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `executor.common.podSecurityContext.enabled` | Enable Dremio Executor pods' Security Context | `true` | +| `executor.common.podSecurityContext.fsGroupChangePolicy` | Set filesystem group change policy for Dremio Executor pods | `Always` | +| `executor.common.podSecurityContext.sysctls` | Set kernel settings using the sysctl interface for Dremio Executor pods | `[]` | +| `executor.common.podSecurityContext.supplementalGroups` | Set filesystem extra groups for Dremio Executor pods | `[]` | +| `executor.common.podSecurityContext.fsGroup` | Set fsGroup in Dremio Executor pods' Security Context | `1001` | +| `executor.common.containerSecurityContext.enabled` | Enabled Dremio Executor container' Security Context | `true` | +| `executor.common.containerSecurityContext.seLinuxOptions` | Set SELinux options in Dremio Executor container | `{}` | +| `executor.common.containerSecurityContext.runAsUser` | Set runAsUser in Dremio Executor container' Security Context | `1001` | +| `executor.common.containerSecurityContext.runAsGroup` | Set runAsGroup in Dremio Executor container' Security Context | `1001` | +| `executor.common.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Dremio Executor container' Security Context | `true` | +| `executor.common.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Dremio Executor container' Security Context | `true` | +| `executor.common.containerSecurityContext.privileged` | Set privileged in Dremio Executor container' Security Context | `false` | +| `executor.common.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Dremio Executor container' Security Context | `false` | +| `executor.common.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Dremio Executor container | `["ALL"]` | +| `executor.common.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Dremio Executor container | `RuntimeDefault` | +| `executor.common.command` | Override default Dremio Executor container command (useful when using custom images) | `[]` | +| `executor.common.args` | Override default Dremio Executor container args (useful when using custom images) | `[]` | +| `executor.common.automountServiceAccountToken` | Mount Service Account token in Dremio Executor pods | `false` | +| `executor.common.hostAliases` | Dremio Executor pods host aliases | `[]` | +| `executor.common.statefulsetAnnotations` | Annotations for Dremio Executor statefulset | `{}` | +| `executor.common.podLabels` | Extra labels for Dremio Executor pods | `{}` | +| `executor.common.podAnnotations` | Annotations for Dremio Executor pods | `{}` | +| `executor.common.podAffinityPreset` | Pod affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `executor.common.podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` | `soft` | +| `executor.common.dremioConf.configOverrides` | Add configuration overrides in dremio.conf applied to all executor nodes (using YAML format) | `{}` | +| `executor.common.dremioConf.secretConfigOverrides` | Add sensitive configuration overrides in dremio.conf applied to executor nodes (using YAML format) | `{}` | +| `executor.common.dremioConf.extraFiles` | Add extra files to the ConfigMap | `{}` | +| `executor.common.dremioConf.extraSecretFiles` | Add extra files to the Secret | `{}` | +| `executor.common.dremioConf.existingConfigmap` | Name of a configmap containing a dremio.conf configuration file for the executor nodes (without sensitive information) | `""` | +| `executor.common.dremioConf.existingSecret` | Name of a secret containing a dremio.conf configuration file for the executor nodes (with sensitive information) | `""` | +| `executor.common.nodeAffinityPreset.type` | Node affinity preset type. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `executor.common.nodeAffinityPreset.key` | Node label key to match. Ignored if `coordinator.affinity` is set | `""` | +| `executor.common.nodeAffinityPreset.values` | Node label values to match. Ignored if `coordinator.affinity` is set | `[]` | +| `executor.common.affinity` | Affinity for Dremio Executor pods assignment | `{}` | +| `executor.common.nodeSelector` | Node labels for Dremio Executor pods assignment | `{}` | +| `executor.common.tolerations` | Tolerations for Dremio Executor pods assignment | `[]` | +| `executor.common.updateStrategy.type` | Dremio Executor statefulset strategy type | `RollingUpdate` | +| `executor.common.podManagementPolicy` | Pod management policy for Dremio Executor statefulset | `OrderedReady` | +| `executor.common.priorityClassName` | Dremio Executor pods' priorityClassName | `""` | +| `executor.common.topologySpreadConstraints` | Topology Spread Constraints for Dremio Executor pod assignment spread across your cluster among failure-domains | `[]` | +| `executor.common.schedulerName` | Name of the k8s scheduler (other than default) for Dremio Executor pods | `""` | +| `executor.common.terminationGracePeriodSeconds` | Seconds Dremio Executor pods need to terminate gracefully | `""` | +| `executor.common.lifecycleHooks` | for Dremio Executor containers to automate configuration before or after startup | `{}` | +| `executor.common.extraEnvVars` | Array with extra environment variables to add to Dremio Executor containers | `[]` | +| `executor.common.extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars for Dremio Executor containers | `""` | +| `executor.common.extraEnvVarsSecret` | Name of existing Secret containing extra env vars for Dremio Executor containers | `""` | +| `executor.common.extraVolumes` | Optionally specify extra list of additional volumes for the Dremio Executor pods | `[]` | +| `executor.common.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for the Dremio Executor containers | `[]` | +| `executor.common.sidecars` | Add additional sidecar containers to the Dremio Executor pods | `[]` | +| `executor.common.initContainers` | Add additional init containers to the Dremio Executor pods | `[]` | +| `executor.common.pdb.create` | Enable/disable a Pod Disruption Budget creation | `true` | +| `executor.common.pdb.minAvailable` | Minimum number/percentage of pods that should remain scheduled | `""` | +| `executor.common.pdb.maxUnavailable` | Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `coordinator.pdb.minAvailable` and `coordinator.pdb.maxUnavailable` are empty. | `""` | +| `executor.common.autoscaling.vpa.enabled` | Enable VPA for Dremio Executor pods | `false` | +| `executor.common.autoscaling.vpa.annotations` | Annotations for VPA resource | `{}` | +| `executor.common.autoscaling.vpa.controlledResources` | VPA List of resources that the vertical pod autoscaler can control. Defaults to cpu and memory | `[]` | +| `executor.common.autoscaling.vpa.maxAllowed` | VPA Max allowed resources for the pod | `{}` | +| `executor.common.autoscaling.vpa.minAllowed` | VPA Min allowed resources for the pod | `{}` | +| `executor.common.autoscaling.vpa.updatePolicy.updateMode` | Autoscaling update policy | `Auto` | +| `executor.common.autoscaling.hpa.enabled` | Enable HPA for Dremio Executor pods | `false` | +| `executor.common.autoscaling.hpa.minReplicas` | Minimum number of replicas | `""` | +| `executor.common.autoscaling.hpa.maxReplicas` | Maximum number of replicas | `""` | +| `executor.common.autoscaling.hpa.targetCPU` | Target CPU utilization percentage | `""` | +| `executor.common.autoscaling.hpa.targetMemory` | Target Memory utilization percentage | `""` | +| `executor.common.networkPolicy.enabled` | Specifies whether a NetworkPolicy should be created | `true` | +| `executor.common.networkPolicy.allowExternal` | Don't require server label for connections | `true` | +| `executor.common.networkPolicy.allowExternalEgress` | Allow the pod to access any range of port and all destinations. | `true` | +| `executor.common.networkPolicy.addExternalClientAccess` | Allow access from pods with client label set to "true". Ignored if `networkPolicy.allowExternal` is true. | `true` | +| `executor.common.networkPolicy.extraIngress` | Add extra ingress rules to the NetworkPolicy | `[]` | +| `executor.common.networkPolicy.extraEgress` | Add extra ingress rules to the NetworkPolicy (ignored if allowExternalEgress=true) | `[]` | +| `executor.common.networkPolicy.ingressPodMatchLabels` | Labels to match to allow traffic from other pods. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `executor.common.networkPolicy.ingressNSMatchLabels` | Labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. | `{}` | +| `executor.common.networkPolicy.ingressNSPodMatchLabels` | Pod labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. | `{}` | + +### Persistence Parameters + +| Name | Description | Value | +| ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- | ---------------------- | +| `executor.common.persistence.enabled` | Enable persistence using Persistent Volume Claims | `true` | +| `executor.common.persistence.mountPath` | Path to mount the volume at. | `/bitnami/dremio/data` | +| `executor.common.persistence.subPath` | The subdirectory of the volume to mount to, useful in dev environments and one PV for multiple services | `""` | +| `executor.common.persistence.storageClass` | Storage class of backing PVC | `""` | +| `executor.common.persistence.annotations` | Persistent Volume Claim annotations | `{}` | +| `executor.common.persistence.accessModes` | Persistent Volume Access Modes | `["ReadWriteOnce"]` | +| `executor.common.persistence.size` | Size of data volume | `8Gi` | +| `executor.common.persistence.existingClaim` | The name of an existing PVC to use for persistence | `""` | +| `executor.common.persistence.selector` | Selector to match an existing Persistent Volume for WordPress data PVC | `{}` | +| `executor.common.persistence.dataSource` | Custom PVC data source | `{}` | +| `executor.common.serviceAccount.create` | Specifies whether a ServiceAccount should be created | `true` | +| `executor.common.serviceAccount.name` | The name of the ServiceAccount to use. | `""` | +| `executor.common.serviceAccount.annotations` | Additional Service Account annotations (evaluated as a template) | `{}` | +| `executor.common.serviceAccount.automountServiceAccountToken` | Automount service account token for the server service account | `false` | + +### Dremio Executor Engine Parameters + +| Name | Description | Value | +| ------------------------------- | ----------------------------------------------------------- | --------- | +| `executor.engines[0].name` | Name of the engine | `default` | +| `executor.engines[0].overrides` | Override configuration set in the "executor.common" section | `{}` | + +### Traffic Exposure Parameters + +| Name | Description | Value | +| ---------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | ------------------------ | +| `service.type` | Dremio service type | `LoadBalancer` | +| `service.ports.web` | Dremio service web port | `9047` | +| `service.ports.client` | Dremio service client port | `31010` | +| `service.ports.flight` | Dremio service flight port | `32010` | +| `service.nodePorts.web` | Node port for web | `""` | +| `service.nodePorts.client` | Node port for client | `""` | +| `service.nodePorts.flight` | Node port for flight | `""` | +| `service.clusterIP` | Dremio service Cluster IP | `""` | +| `service.loadBalancerIP` | Dremio service Load Balancer IP | `""` | +| `service.loadBalancerSourceRanges` | Dremio service Load Balancer sources | `[]` | +| `service.externalTrafficPolicy` | Dremio service external traffic policy | `Cluster` | +| `service.annotations` | Additional custom annotations for Dremio service | `{}` | +| `service.extraPorts` | Extra ports to expose in Dremio service (normally used with the `sidecars` value) | `[]` | +| `service.sessionAffinity` | Control where client requests go, to the same pod or round-robin | `None` | +| `service.sessionAffinityConfig` | Additional settings for the sessionAffinity | `{}` | +| `service.headless.annotations` | Add annotations to the headless service | `{}` | +| `ingress.enabled` | Enable ingress record generation for Dremio | `false` | +| `ingress.pathType` | Ingress path type | `ImplementationSpecific` | +| `ingress.apiVersion` | Force Ingress API version (automatically detected if not set) | `""` | +| `ingress.hostname` | Default host for the ingress record | `dremio.local` | +| `ingress.ingressClassName` | IngressClass that will be be used to implement the Ingress (Kubernetes 1.18+) | `""` | +| `ingress.path` | Default path for the ingress record | `/` | +| `ingress.annotations` | Additional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations. | `{}` | +| `ingress.tls` | Enable TLS configuration for the host defined at `ingress.hostname` parameter | `false` | +| `ingress.selfSigned` | Create a TLS secret for this ingress record using self-signed certificates generated by Helm | `false` | +| `ingress.extraHosts` | An array with additional hostname(s) to be covered with the ingress record | `[]` | +| `ingress.extraPaths` | An array with additional arbitrary paths that may need to be added to the ingress under the main host | `[]` | +| `ingress.extraTls` | TLS configuration for additional hostname(s) to be covered with this ingress record | `[]` | +| `ingress.secrets` | Custom TLS certificates as secrets | `[]` | +| `ingress.extraRules` | Additional rules to be covered with this ingress record | `[]` | + +### Dremio bootstrap user job + +| Name | Description | Value | +| -------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------- | +| `bootstrapUserJob.enabled` | Enable the bootstrap user job | `true` | +| `bootstrapUserJob.forceRun` | Force the run of the credential job | `false` | +| `bootstrapUserJob.labels` | Add labels to the init job definition | `{}` | +| `bootstrapUserJob.backoffLimit` | set backoff limit of the job | `10` | +| `bootstrapUserJob.extraVolumes` | Optionally specify extra list of additional volumes for the credential init job | `[]` | +| `bootstrapUserJob.extraCommands` | Extra commands to pass to the generation job | `""` | +| `bootstrapUserJob.containerSecurityContext.enabled` | Enabled containers' Security Context | `true` | +| `bootstrapUserJob.containerSecurityContext.seLinuxOptions` | Set SELinux options in container | `{}` | +| `bootstrapUserJob.containerSecurityContext.runAsUser` | Set containers' Security Context runAsUser | `1001` | +| `bootstrapUserJob.containerSecurityContext.runAsGroup` | Set containers' Security Context runAsGroup | `1001` | +| `bootstrapUserJob.containerSecurityContext.runAsNonRoot` | Set container's Security Context runAsNonRoot | `true` | +| `bootstrapUserJob.containerSecurityContext.privileged` | Set container's Security Context privileged | `false` | +| `bootstrapUserJob.containerSecurityContext.readOnlyRootFilesystem` | Set container's Security Context readOnlyRootFilesystem | `true` | +| `bootstrapUserJob.containerSecurityContext.allowPrivilegeEscalation` | Set container's Security Context allowPrivilegeEscalation | `false` | +| `bootstrapUserJob.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped | `["ALL"]` | +| `bootstrapUserJob.containerSecurityContext.seccompProfile.type` | Set container's Security Context seccomp profile | `RuntimeDefault` | +| `bootstrapUserJob.podSecurityContext.enabled` | Enabled credential init job pods' Security Context | `true` | +| `bootstrapUserJob.podSecurityContext.fsGroupChangePolicy` | Set filesystem group change policy | `Always` | +| `bootstrapUserJob.podSecurityContext.sysctls` | Set kernel settings using the sysctl interface | `[]` | +| `bootstrapUserJob.podSecurityContext.supplementalGroups` | Set filesystem extra groups | `[]` | +| `bootstrapUserJob.podSecurityContext.fsGroup` | Set credential init job pod's Security Context fsGroup | `1001` | +| `bootstrapUserJob.extraEnvVars` | Array containing extra env vars to configure the credential init job | `[]` | +| `bootstrapUserJob.extraEnvVarsCM` | ConfigMap containing extra env vars to configure the credential init job | `""` | +| `bootstrapUserJob.extraEnvVarsSecret` | Secret containing extra env vars to configure the credential init job (in case of sensitive data) | `""` | +| `bootstrapUserJob.extraVolumeMounts` | Array of extra volume mounts to be added to the jwt Container (evaluated as template). Normally used with `extraVolumes`. | `[]` | +| `bootstrapUserJob.resourcesPreset` | Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if bootstrapUserJob.resources is set (bootstrapUserJob.resources is recommended for production). | `micro` | +| `bootstrapUserJob.resources` | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `bootstrapUserJob.livenessProbe.enabled` | Enable livenessProbe on init job | `true` | +| `bootstrapUserJob.livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `5` | +| `bootstrapUserJob.livenessProbe.periodSeconds` | Period seconds for livenessProbe | `10` | +| `bootstrapUserJob.livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `5` | +| `bootstrapUserJob.livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `5` | +| `bootstrapUserJob.livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `bootstrapUserJob.readinessProbe.enabled` | Enable readinessProbe on init job | `true` | +| `bootstrapUserJob.readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `5` | +| `bootstrapUserJob.readinessProbe.periodSeconds` | Period seconds for readinessProbe | `10` | +| `bootstrapUserJob.readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `5` | +| `bootstrapUserJob.readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `5` | +| `bootstrapUserJob.readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `bootstrapUserJob.startupProbe.enabled` | Enable startupProbe on Data Coordinator containers | `false` | +| `bootstrapUserJob.startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `5` | +| `bootstrapUserJob.startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `bootstrapUserJob.startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `5` | +| `bootstrapUserJob.startupProbe.failureThreshold` | Failure threshold for startupProbe | `5` | +| `bootstrapUserJob.startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `bootstrapUserJob.customLivenessProbe` | Custom livenessProbe that overrides the default one | `{}` | +| `bootstrapUserJob.customReadinessProbe` | Custom readinessProbe that overrides the default one | `{}` | +| `bootstrapUserJob.customStartupProbe` | Custom startupProbe that overrides the default one | `{}` | +| `bootstrapUserJob.automountServiceAccountToken` | Mount Service Account token in pod | `false` | +| `bootstrapUserJob.hostAliases` | Add deployment host aliases | `[]` | +| `bootstrapUserJob.annotations` | Add annotations to the job | `{}` | +| `bootstrapUserJob.podLabels` | Additional pod labels | `{}` | +| `bootstrapUserJob.podAnnotations` | Additional pod annotations | `{}` | +| `bootstrapUserJob.networkPolicy.enabled` | Enable creation of NetworkPolicy resources | `true` | +| `bootstrapUserJob.networkPolicy.allowExternalEgress` | Allow the pod to access any range of port and all destinations. | `true` | +| `bootstrapUserJob.networkPolicy.extraIngress` | Add extra ingress rules to the NetworkPolicy | `[]` | +| `bootstrapUserJob.networkPolicy.extraEgress` | Add extra ingress rules to the NetworkPolicy | `[]` | +| `bootstrapUserJob.networkPolicy.ingressNSMatchLabels` | Labels to match to allow traffic from other namespaces | `{}` | +| `bootstrapUserJob.networkPolicy.ingressNSPodMatchLabels` | Pod labels to match to allow traffic from other namespaces | `{}` | + +### Default Init Container Parameters + +| Name | Description | Value | +| ----------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------- | +| `defaultInitContainers.defaultImage.registry` | OS Shell + Utility image registry | `REGISTRY_NAME` | +| `defaultInitContainers.defaultImage.repository` | OS Shell + Utility image repository | `REPOSITORY_NAME/os-shell` | +| `defaultInitContainers.defaultImage.pullPolicy` | OS Shell + Utility image pull policy | `IfNotPresent` | +| `defaultInitContainers.defaultImage.pullSecrets` | OS Shell + Utility image pull secrets | `[]` | +| `defaultInitContainers.wait.enabled` | Enable init container that waits for backends to be ready | `true` | +| `defaultInitContainers.wait.resourcesPreset` | Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). | `nano` | +| `defaultInitContainers.wait.resources` | Set init container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `defaultInitContainers.wait.containerSecurityContext.enabled` | Enabled Init container' Security Context | `true` | +| `defaultInitContainers.wait.containerSecurityContext.seLinuxOptions` | Set SELinux options in Init container | `{}` | +| `defaultInitContainers.wait.containerSecurityContext.runAsUser` | Set runAsUser in Init container' Security Context | `1001` | +| `defaultInitContainers.wait.containerSecurityContext.runAsGroup` | Set runAsGroup in Init container' Security Context | `1001` | +| `defaultInitContainers.wait.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Init container' Security Context | `true` | +| `defaultInitContainers.wait.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Init container' Security Context | `true` | +| `defaultInitContainers.wait.containerSecurityContext.privileged` | Set privileged in Init container' Security Context | `false` | +| `defaultInitContainers.wait.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Init container' Security Context | `false` | +| `defaultInitContainers.wait.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Init container | `["ALL"]` | +| `defaultInitContainers.wait.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Init container | `RuntimeDefault` | +| `defaultInitContainers.generateConf.enabled` | Enable init container that merges and renders the dremio.conf and core-site.xml configuration files | `true` | +| `defaultInitContainers.generateConf.resourcesPreset` | Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). | `nano` | +| `defaultInitContainers.generateConf.resources` | Set init container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `defaultInitContainers.generateConf.containerSecurityContext.enabled` | Enabled Init container' Security Context | `true` | +| `defaultInitContainers.generateConf.containerSecurityContext.seLinuxOptions` | Set SELinux options in Init container | `{}` | +| `defaultInitContainers.generateConf.containerSecurityContext.runAsUser` | Set runAsUser in Init container' Security Context | `1001` | +| `defaultInitContainers.generateConf.containerSecurityContext.runAsGroup` | Set runAsGroup in Init container' Security Context | `1001` | +| `defaultInitContainers.generateConf.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Init container' Security Context | `true` | +| `defaultInitContainers.generateConf.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Init container' Security Context | `true` | +| `defaultInitContainers.generateConf.containerSecurityContext.privileged` | Set privileged in Init container' Security Context | `false` | +| `defaultInitContainers.generateConf.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Init container' Security Context | `false` | +| `defaultInitContainers.generateConf.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Init container | `["ALL"]` | +| `defaultInitContainers.generateConf.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Init container | `RuntimeDefault` | +| `defaultInitContainers.generateConf.extraEnvVars` | Array with extra environment variables to add to Dremio containers | `[]` | +| `defaultInitContainers.generateConf.extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars for Dremio containers | `""` | +| `defaultInitContainers.generateConf.extraEnvVarsSecret` | Name of existing Secret containing extra env vars for Dremio containers | `""` | +| `defaultInitContainers.generateConf.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for the Dremio containers | `[]` | +| `defaultInitContainers.initCerts.enabled` | Enable init container that initializes the Java keystore with the TLS certificates (requires dremio.tls.enabled=true) | `true` | +| `defaultInitContainers.initCerts.resourcesPreset` | Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). | `nano` | +| `defaultInitContainers.initCerts.resources` | Set init container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `defaultInitContainers.initCerts.containerSecurityContext.enabled` | Enabled Init container' Security Context | `true` | +| `defaultInitContainers.initCerts.containerSecurityContext.seLinuxOptions` | Set SELinux options in Init container | `{}` | +| `defaultInitContainers.initCerts.containerSecurityContext.runAsUser` | Set runAsUser in Init container' Security Context | `1001` | +| `defaultInitContainers.initCerts.containerSecurityContext.runAsGroup` | Set runAsGroup in Init container' Security Context | `1001` | +| `defaultInitContainers.initCerts.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Init container' Security Context | `true` | +| `defaultInitContainers.initCerts.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Init container' Security Context | `true` | +| `defaultInitContainers.initCerts.containerSecurityContext.privileged` | Set privileged in Init container' Security Context | `false` | +| `defaultInitContainers.initCerts.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Init container' Security Context | `false` | +| `defaultInitContainers.initCerts.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Init container | `["ALL"]` | +| `defaultInitContainers.initCerts.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Init container | `RuntimeDefault` | +| `defaultInitContainers.copyDefaultConf.enabled` | Enable init container that copies the default dremio configuration to an empty-dir volume | `true` | +| `defaultInitContainers.copyDefaultConf.resourcesPreset` | Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). | `nano` | +| `defaultInitContainers.copyDefaultConf.resources` | Set init container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.enabled` | Enabled Init container' Security Context | `true` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.seLinuxOptions` | Set SELinux options in Init container | `{}` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.runAsUser` | Set runAsUser in Init container' Security Context | `1001` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.runAsGroup` | Set runAsGroup in Init container' Security Context | `1001` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Init container' Security Context | `true` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Init container' Security Context | `true` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.privileged` | Set privileged in Init container' Security Context | `false` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Init container' Security Context | `false` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Init container | `["ALL"]` | +| `defaultInitContainers.copyDefaultConf.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Init container | `RuntimeDefault` | +| `defaultInitContainers.upgradeKeystore.enabled` | Enable init container that upgrades the metadata KV store | `true` | +| `defaultInitContainers.upgradeKeystore.resourcesPreset` | Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). | `large` | +| `defaultInitContainers.upgradeKeystore.resources` | Set init container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.enabled` | Enabled Init container' Security Context | `true` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.seLinuxOptions` | Set SELinux options in Init container | `{}` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.runAsUser` | Set runAsUser in Init container' Security Context | `1001` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.runAsGroup` | Set runAsGroup in Init container' Security Context | `1001` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.runAsNonRoot` | Set runAsNonRoot in Init container' Security Context | `true` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.readOnlyRootFilesystem` | Set readOnlyRootFilesystem in Init container' Security Context | `true` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.privileged` | Set privileged in Init container' Security Context | `false` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.allowPrivilegeEscalation` | Set allowPrivilegeEscalation in Init container' Security Context | `false` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.capabilities.drop` | List of capabilities to be dropped in Init container | `["ALL"]` | +| `defaultInitContainers.upgradeKeystore.containerSecurityContext.seccompProfile.type` | Set seccomp profile in Init container | `RuntimeDefault` | +| `defaultInitContainers.volumePermissions.enabled` | Enable init container that changes the owner/group of the PV mount point to `runAsUser:fsGroup` | `false` | +| `defaultInitContainers.volumePermissions.resourcesPreset` | Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). | `nano` | +| `defaultInitContainers.volumePermissions.resources` | Set init container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `defaultInitContainers.volumePermissions.containerSecurityContext.enabled` | Enabled init container' Security Context | `true` | +| `defaultInitContainers.volumePermissions.containerSecurityContext.seLinuxOptions` | Set SELinux options in init container | `{}` | +| `defaultInitContainers.volumePermissions.containerSecurityContext.runAsUser` | Set init container's Security Context runAsUser | `0` | + +### MinIO® chart parameters + +| Name | Description | Value | +| ---------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------- | +| `minio` | For full list of MinIO® values configurations please refere [here](https://github.com/bitnami/charts/tree/main/bitnami/minio) | | +| `minio.enabled` | Enable/disable MinIO® chart installation | `true` | +| `minio.containerPorts.api` | MinIO® container port to open for MinIO® API | `9000` | +| `minio.auth.rootUser` | MinIO® root username | `admin` | +| `minio.auth.rootPassword` | Password for MinIO® root user | `""` | +| `minio.auth.existingSecret` | Name of an existing secret containing the MinIO® credentials | `""` | +| `minio.defaultBuckets` | Comma, semi-colon or space separated list of MinIO® buckets to create | `dremio` | +| `minio.provisioning.enabled` | Enable/disable MinIO® provisioning job | `true` | +| `minio.provisioning.extraCommands` | Extra commands to run on MinIO® provisioning job | `["mc anonymous set download provisioning/dremio"]` | +| `minio.tls.enabled` | Enable/disable MinIO® TLS support | `true` | +| `minio.tls.autoGenerated` | Autogenerate TLS certificates | `true` | +| `minio.service.type` | MinIO® service type | `ClusterIP` | +| `minio.service.loadBalancerIP` | MinIO® service LoadBalancer IP | `""` | +| `minio.service.ports.api` | MinIO® service port | `9000` | + +### Prometheus metrics + +| Name | Description | Value | +| ----------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------ | +| `metrics.enabled` | Enable the export of Prometheus metrics | `false` | +| `metrics.image.registry` | JMX exporter image registry | `REGISTRY_NAME` | +| `metrics.image.repository` | JMX exporter image repository | `REPOSITORY_NAME/jmx-exporter` | +| `metrics.image.digest` | JMX exporter image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag | `""` | +| `metrics.image.pullPolicy` | JMX exporter image pull policy | `IfNotPresent` | +| `metrics.image.pullSecrets` | Specify docker-registry secret names as an array | `[]` | +| `metrics.extraArgs` | Add extra arguments to the default container args section | `[]` | +| `metrics.containerSecurityContext.enabled` | Enable Prometheus JMX exporter containers' Security Context | `true` | +| `metrics.containerSecurityContext.seLinuxOptions` | Set SELinux options in container | `{}` | +| `metrics.containerSecurityContext.runAsUser` | Set Prometheus JMX exporter containers' Security Context runAsUser | `1001` | +| `metrics.containerSecurityContext.runAsGroup` | Group ID for the Prometheus JMX exporter container | `1001` | +| `metrics.containerSecurityContext.runAsNonRoot` | Set Prometheus JMX exporter containers' Security Context runAsNonRoot | `true` | +| `metrics.containerSecurityContext.privileged` | Set Prometheus JMX exporter container's Security Context privileged | `false` | +| `metrics.containerSecurityContext.allowPrivilegeEscalation` | Set Prometheus JMX exporter containers' Security Context allowPrivilegeEscalation | `false` | +| `metrics.containerSecurityContext.readOnlyRootFilesystem` | Set Prometheus JMX exporter containers' Security Context readOnlyRootFilesystem | `true` | +| `metrics.containerSecurityContext.capabilities.drop` | Set Prometheus JMX exporter containers' Security Context capabilities to be dropped | `["ALL"]` | +| `metrics.containerSecurityContext.seccompProfile.type` | Set Prometheus JMX exporter container's Security Context seccomp profile | `RuntimeDefault` | +| `metrics.containerPorts.metrics` | Prometheus JMX exporter metrics container port | `5556` | +| `metrics.resourcesPreset` | Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if metrics.resources is set (metrics.resources is recommended for production). | `micro` | +| `metrics.resources` | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | +| `metrics.livenessProbe.enabled` | Enable livenessProbe | `true` | +| `metrics.livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `60` | +| `metrics.livenessProbe.periodSeconds` | Period seconds for livenessProbe | `10` | +| `metrics.livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `30` | +| `metrics.livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `3` | +| `metrics.livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `metrics.readinessProbe.enabled` | Enable readinessProbe | `true` | +| `metrics.readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `30` | +| `metrics.readinessProbe.periodSeconds` | Period seconds for readinessProbe | `10` | +| `metrics.readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `30` | +| `metrics.readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `3` | +| `metrics.readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `metrics.startupProbe.enabled` | Enable startupProbe | `true` | +| `metrics.startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `30` | +| `metrics.startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `metrics.startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `30` | +| `metrics.startupProbe.failureThreshold` | Failure threshold for startupProbe | `3` | +| `metrics.startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `metrics.service.ports.metrics` | Prometheus JMX exporter metrics service port | `5556` | +| `metrics.service.clusterIP` | Static clusterIP or None for headless services | `""` | +| `metrics.service.sessionAffinity` | Control where client requests go, to the same pod or round-robin | `None` | +| `metrics.service.annotations` | Annotations for the Prometheus JMX exporter service | `{}` | +| `metrics.configOverrides` | Configuration file for JMX exporter | `""` | +| `metrics.existingConfigmap` | Name of existing ConfigMap with JMX exporter configuration | `""` | +| `metrics.serviceMonitor.enabled` | if `true`, creates a Prometheus Operator ServiceMonitor (also requires `metrics.enabled` to be `true`) | `false` | +| `metrics.serviceMonitor.namespace` | Namespace in which Prometheus is running | `""` | +| `metrics.serviceMonitor.annotations` | Additional custom annotations for the ServiceMonitor | `{}` | +| `metrics.serviceMonitor.labels` | Extra labels for the ServiceMonitor | `{}` | +| `metrics.serviceMonitor.jobLabel` | The name of the label on the target service to use as the job name in Prometheus | `""` | +| `metrics.serviceMonitor.honorLabels` | honorLabels chooses the metric's labels on collisions with target labels | `false` | +| `metrics.serviceMonitor.interval` | Interval at which metrics should be scraped. | `""` | +| `metrics.serviceMonitor.scrapeTimeout` | Timeout after which the scrape is ended | `""` | +| `metrics.serviceMonitor.metricRelabelings` | Specify additional relabeling of metrics | `[]` | +| `metrics.serviceMonitor.relabelings` | Specify general relabeling | `[]` | +| `metrics.serviceMonitor.selector` | Prometheus instance selector labels | `{}` | + +### External S3 parameters + +| Name | Description | Value | +| ----------------------------------------- | ------------------------------------------------------------------- | --------------- | +| `externalS3.host` | External S3 host | `""` | +| `externalS3.port` | External S3 port number | `443` | +| `externalS3.accessKeyID` | External S3 access key ID | `""` | +| `externalS3.accessKeySecret` | External S3 access key secret | `""` | +| `externalS3.existingSecret` | Name of an existing secret resource containing the S3 credentials | `""` | +| `externalS3.existingSecretAccessKeyIDKey` | Name of an existing secret key containing the S3 access key ID | `root-user` | +| `externalS3.existingSecretKeySecretKey` | Name of an existing secret key containing the S3 access key secret | `root-password` | +| `externalS3.protocol` | External S3 protocol | `https` | +| `externalS3.bucket` | External S3 bucket | `dremio` | +| `externalS3.path` | External S3 path inside the bucket | `""` | +| `externalS3.region` | External S3 region | `us-east-1` | +| `externalS3.authentication` | External S3 authentication type | `accesskey` | +| `externalS3.disableCertChecking` | Disable certificate checking on external S3 (necessary if it uses ) | `false` | + +### External Zookeeper paramaters + +| Name | Description | Value | +| --------------------------- | ----------------------------------------- | ------ | +| `externalZookeeper.servers` | List of external zookeeper servers to use | `[]` | +| `externalZookeeper.port` | Port of the Zookeeper servers | `2888` | + +### Zookeeper subchart parameters + +| Name | Description | Value | +| --------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | +| `zookeeper.enabled` | Deploy Zookeeper subchart | `true` | +| `zookeeper.replicaCount` | Number of Zookeeper instances | `1` | +| `zookeeper.containerPorts.client` | Zookeeper container port | `2181` | +| `zookeeper.resourcesPreset` | Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production). | `micro` | +| `zookeeper.resources` | Set container requests and limits for different resources like CPU or memory (essential for production workloads) | `{}` | + +Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. + +Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example, + +```console +helm install my-release -f values.yaml oci://REGISTRY_NAME/REPOSITORY_NAME/dremio +``` + +> Note: You need to substitute the placeholders `REGISTRY_NAME` and `REPOSITORY_NAME` with a reference to your Helm chart registry and repository. For example, in the case of Bitnami, you need to use `REGISTRY_NAME=registry-1.docker.io` and `REPOSITORY_NAME=bitnamicharts`. +> **Tip**: You can use the default [values.yaml](https://github.com/bitnami/charts/blob/main/template/dremio/values.yaml) + +## Troubleshooting + +## License + +Copyright © 2024 Broadcom. The term "Broadcom" refers to Broadcom Inc. and/or its subsidiaries. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. diff --git a/bitnami/dremio/templates/NOTES.txt b/bitnami/dremio/templates/NOTES.txt new file mode 100644 index 0000000000..98b56bfd01 --- /dev/null +++ b/bitnami/dremio/templates/NOTES.txt @@ -0,0 +1,69 @@ +CHART NAME: {{ .Chart.Name }} +CHART VERSION: {{ .Chart.Version }} +APP VERSION: {{ .Chart.AppVersion }} + +** Please be patient while the chart is being deployed ** + +{{- if .Values.diagnosticMode.enabled }} +The chart has been deployed in diagnostic mode. All probes have been disabled and the command has been overwritten with: + + command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 4 }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 4 }} + +Get the list of pods by executing: + + kubectl get pods --namespace {{ include "common.names.namespace" . | quote }} -l app.kubernetes.io/instance={{ .Release.Name }} + +Access the pod you want to debug by executing + + kubectl exec --namespace {{ include "common.names.namespace" . | quote }} -ti -- bash + +In order to replicate the container startup scripts execute this command: + + dremio start-fg + +{{- else }} + +Access Dremio from within the cluster using the following URL: + + - {{ include "common.names.fullname" . }}.{{ include "common.names.namespace" . }}.svc.{{ .Values.clusterDomain }}:{{ .Values.service.ports.web }} (web) + - {{ include "common.names.fullname" . }}.{{ include "common.names.namespace" . }}.svc.{{ .Values.clusterDomain }}:{{ .Values.service.ports.client }} (client) + - {{ include "common.names.fullname" . }}.{{ include "common.names.namespace" . }}.svc.{{ .Values.clusterDomain }}:{{ .Values.service.ports.flight }} (flight) + +To access Dremio web interface from outside the cluster follow the steps below: + +{{- if .Values.dremio.auth.enabled }} +Get the Dremio server credentials by running these commands: + +echo Username: {{ .Values.dremio.auth.username }} +echo Password: $(kubectl get secret --namespace {{ include "common.names.namespace" . }} {{ include "common.names.fullname" . }} -o jsonpath="{.data.dremio-password}" | base64 -d) +{{- end }} + +Get the Dremio server URL by running these commands: + +{{- if .Values.ingress.enabled }} + export CLUSTER_IP=$(minikube ip) # On Minikube. Use: `kubectl cluster-info` on others K8s clusters + echo "Dremio web server URL: http{{ if .Values.ingress.tls }}s{{ end }}://{{ .Values.ingress.hostname }}/" + echo "$CLUSTER_IP {{ .Values.ingress.hostname }}" | sudo tee -a /etc/hosts + +{{- else if contains "NodePort" .Values.service.type }} + export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "common.names.fullname" . }}) + export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") + echo "Dremio web server available at $NODE_IP:$NODE_PORT" +{{- else if contains "LoadBalancer" .Values.service.type }} + NOTE: It may take a few minutes for the LoadBalancer IP to be available. + You can watch the status of by running 'kubectl get --namespace {{ include "common.names.namespace" . }} svc -w {{ include "common.names.fullname" . }}' + export SERVICE_IP=$(kubectl get svc --namespace {{ include "common.names.namespace" . }} {{ include "common.names.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}') + echo "Dremio web server available at $SERVICE_IP:{{ .Values.service.ports.web }}" +{{- else if contains "ClusterIP" .Values.service.type }} + echo "Dremio web server available at 127.0.0.1:9047" + kubectl port-forward svc/{{ include "common.names.fullname" . }} 9047:{{ .Values.service.ports.web }} & +{{- end }} +{{- end }} + +{{- include "common.warnings.rollingTag" .Values.dremio.image }} +{{- include "common.warnings.rollingTag" .Values.defaultInitContainers.defaultImage }} +{{- include "common.warnings.rollingTag" .Values.metrics.image }} +{{- include "dremio.validateValues" . }} +{{- include "common.warnings.modifiedImages" (dict "images" (list .Values.dremio.image .Values.defaultInitContainers.defaultImage .Values.metrics.image) "context" $) }} +{{- include "common.warnings.resources" (dict "sections" (list "masterCoordinator" "coordinator" "executor.common" "defaultInitContainers.wait" "defaultInitContainers.generateConf" "defaultInitContainers.initCerts" "defaultInitContainers.copyDefaultConf" "defaultInitContainers.upgradeKeystore" "defaultInitContainers.volumePermissions") "context" $) }} diff --git a/bitnami/dremio/templates/_helpers.tpl b/bitnami/dremio/templates/_helpers.tpl new file mode 100644 index 0000000000..e29592f8d0 --- /dev/null +++ b/bitnami/dremio/templates/_helpers.tpl @@ -0,0 +1,530 @@ +{{/* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{/* +Return the proper image name +*/}} +{{- define "dremio.image" -}} +{{ include "common.images.image" (dict "imageRoot" .Values.dremio.image "global" .Values.global) }} +{{- end -}} + +{{/* +Return the proper image name (for the default init containers) +*/}} +{{- define "dremio.init-containers.default-image" -}} +{{ include "common.images.image" (dict "imageRoot" .Values.defaultInitContainers.defaultImage "global" .Values.global) }} +{{- end -}} + +{{/* +Return the proper image name (for the sidecar JMX exporter image) +*/}} +{{- define "dremio.metrics.image" -}} +{{- include "common.images.image" ( dict "imageRoot" .Values.metrics.image "global" .Values.global ) -}} +{{- end -}} + +{{/* +Return the proper Dremio Master Coordinator fullname +*/}} +{{- define "dremio.master-coordinator.fullname" -}} +{{- printf "%s-%s" (include "common.names.fullname" .) "master-coordinator" | trunc 63 | trimSuffix "-" -}} +{{- end -}} + +{{/* +Return the proper Dremio Coordinator fullname +*/}} +{{- define "dremio.coordinator.fullname" -}} +{{- printf "%s-%s" (include "common.names.fullname" .) "coordinator" | trunc 63 | trimSuffix "-" -}} +{{- end -}} + +{{/* +Return the proper Dremio Executor fullname +*/}} +{{- define "dremio.executor.fullname" -}} +{{- printf "%s-executor-%s" (include "common.names.fullname" .context) .engine | trunc 63 | trimSuffix "-" -}} +{{- end -}} + +{{/* +Return the proper Docker Image Registry Secret Names +*/}} +{{- define "dremio.imagePullSecrets" -}} +{{- include "common.images.renderPullSecrets" (dict "images" (list .Values.dremio.image .Values.defaultInitContainers.defaultImage .Values.metrics.image) "context" $) -}} +{{- end -}} + +{{/* +Create the name of the service account to use +*/}} +{{- define "dremio.master-coordinator.dremio-conf.useSecret" -}} +{{- if or .Values.masterCoordinator.dremioConf.existingSecret .Values.dremio.dremioConf.secretConfigOverrides .Values.masterCoordinator.dremioConf.secretConfigOverrides -}} +{{- true -}} +{{- end -}} +{{- end -}} + +{{/* +Create the name of the service account to use +*/}} +{{- define "dremio.coordinator.dremio-conf.useSecret" -}} +{{- if or .Values.coordinator.dremioConf.existingSecret .Values.dremio.dremioConf.secretConfigOverrides .Values.coordinator.dremioConf.secretConfigOverrides -}} +{{- true -}} +{{- end -}} +{{- end -}} + +{{/* +Create the name of the service account to use +*/}} +{{- define "dremio.executor.dremio-conf.useSecret" -}} +{{- if or .executorValues.dremioConf.existingSecret .context.Values.dremio.dremioConf.secretConfigOverrides .executorValues.dremioConf.secretConfigOverrides -}} +{{- true -}} +{{- end -}} +{{- end -}} + +{{/* +Return the Dremio metrics configuration configmap +*/}} +{{- define "dremio.metrics.configmapName" -}} +{{- if .Values.metrics.existingConfigmap -}} + {{- include "common.tplvalues.render" (dict "value" .Values.metrics.existingConfigmap "context" $) -}} +{{- else -}} + {{- printf "%s-metrics-configuration" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +Create the name of the service account to use +*/}} +{{- define "dremio.master-coordinator.serviceAccountName" -}} +{{- if .Values.masterCoordinator.serviceAccount.create -}} + {{ default (include "dremio.master-coordinator.fullname" .) .Values.masterCoordinator.serviceAccount.name }} +{{- else -}} + {{ default "default" .Values.masterCoordinator.serviceAccount.name }} +{{- end -}} +{{- end -}} + +{{/* +Create the name of the service account to use +*/}} +{{- define "dremio.coordinator.serviceAccountName" -}} +{{- if .Values.coordinator.serviceAccount.create -}} + {{ default (include "dremio.coordinator.fullname" .) .Values.coordinator.serviceAccount.name }} +{{- else -}} + {{ default "default" .Values.coordinator.serviceAccount.name }} +{{- end -}} +{{- end -}} + +{{/* +Create the name of the service account to use +*/}} +{{- define "dremio.executor.serviceAccountName" -}} +{{- if .executorValues.serviceAccount.create -}} + {{ default (include "dremio.executor.fullname" (dict "engine" .engine "context" .context)) .executorValues.serviceAccount.name }} +{{- else -}} + {{ default "default" .executorValues.serviceAccount.name }} +{{- end -}} +{{- end -}} + +{{/* +dremio.conf ConfigMap (master-coordinator) +*/}} +{{- define "dremio.master-coordinator.dremio-conf.configmapName" -}} +{{- if .Values.masterCoordinator.dremioConf.existingConfigmap -}} + {{- tpl .Values.masterCoordinator.dremioConf.existingConfigmap $ -}} +{{- else -}} + {{- printf "%s-dremio-conf" (include "dremio.master-coordinator.fullname" .) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +dremio.conf ConfigMap (coordinator) +*/}} +{{- define "dremio.coordinator.dremio-conf.configmapName" -}} +{{- if .Values.coordinator.dremioConf.existingConfigmap -}} + {{- tpl .Values.coordinator.dremioConf.existingConfigmap $ -}} +{{- else -}} + {{- printf "%s-dremio-conf" (include "dremio.coordinator.fullname" .) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +dremio.conf ConfigMap (executor) +*/}} +{{- define "dremio.executor.dremio-conf.configmapName" -}} +{{- if .executorValues.dremioConf.existingConfigmap -}} + {{- tpl .executorValues.dremioConf.existingConfigmap .context -}} +{{- else -}} + {{- printf "%s-dremio-conf" (include "dremio.executor.fullname" (dict "context" .context "engine" .engine)) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +dremio.conf ConfigMap (master-coordinator) +*/}} +{{- define "dremio.master-coordinator.dremio-conf.secretName" -}} +{{- if .Values.masterCoordinator.dremioConf.existingSecret -}} + {{- tpl .Values.masterCoordinator.dremioConf.existingSecret $ -}} +{{- else -}} + {{- printf "%s-dremio-conf" (include "dremio.master-coordinator.fullname" .) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +dremio.conf ConfigMap (coordinator) +*/}} +{{- define "dremio.coordinator.dremio-conf.secretName" -}} +{{- if .Values.coordinator.dremioConf.existingSecret -}} + {{- tpl .Values.coordinator.dremioConf.existingSecret $ -}} +{{- else -}} + {{- printf "%s-dremio-conf" (include "dremio.coordinator.fullname" .) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +dremio.conf ConfigMap (executor) +*/}} +{{- define "dremio.executor.dremio-conf.secretName" -}} +{{- if .executorValues.dremioConf.existingSecret -}} + {{- tpl .executorValues.dremioConf.existingSecret $ -}} +{{- else -}} + {{- printf "%s-dremio-conf" (include "dremio.executor.fullname" (dict "context" .context "engine" .engine)) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +core-site.xml Secret +*/}} +{{- define "dremio.core-site.secretName" -}} +{{- if .Values.dremio.coreSite.existingSecret -}} + {{- tpl .Values.dremio.coreSite.existingSecret $ -}} +{{- else -}} + {{- printf "%s-core-site" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +Return true if a TLS credentials secret object should be created +*/}} +{{- define "dremio.tls.createSecret" -}} +{{- if and .Values.dremio.tls.enabled .Values.dremio.tls.autoGenerated.enabled (not .Values.dremio.tls.existingSecret) }} + {{- true -}} +{{- end -}} +{{- end -}} + +{{/* +Return the Jenkins JKS password secret name +*/}} +{{- define "dremio.tls.passwordSecretName" -}} +{{- $secretName := .Values.dremio.tls.passwordSecret -}} +{{- if $secretName -}} + {{- printf "%s" (tpl $secretName $) -}} +{{- else -}} + {{- printf "%s-tls-pass" (include "common.names.fullname" .) -}} +{{- end -}} +{{- end -}} + +{{/* +Return the Scylladb TLS credentials secret +*/}} +{{- define "dremio.tls.secretName" -}} +{{- if .Values.dremio.tls.existingSecret -}} + {{- print (tpl .Values.dremio.tls.existingSecret $) -}} +{{- else -}} + {{- printf "%s-crt" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" -}} +{{- end -}} +{{- end -}} + +{{/* +Return the Dremio auth credentials secret +*/}} +{{- define "dremio.auth.secretName" -}} +{{- if .Values.dremio.auth.existingSecret -}} + {{- print (tpl .Values.dremio.auth.existingSecret $) -}} +{{- else -}} + {{- include "common.names.fullname" . -}} +{{- end -}} +{{- end -}} + +{{/* +Return true if the init job should be created +*/}} +{{- define "dremio.bootstrap-user-job.create" -}} +{{- if and .Values.bootstrapUserJob.enabled .Values.dremio.auth.enabled (or .Release.IsInstall .Values.bootstrapUserJob.forceRun) -}} + {{- true -}} +{{- else -}} + {{/* Do not return anything */}} +{{- end -}} +{{- end -}} + +{{/* +Return the Dremio auth credentials secret +*/}} +{{- define "dremio.auth.passwordKey" -}} +{{- if .Values.dremio.auth.existingSecretKey -}} + {{- print (tpl .Values.dremio.auth.existingSecretKey $) -}} +{{- else -}} + {{- print "dremio-password" -}} +{{- end -}} +{{- end -}} + +{{/* Return common dremio.conf configuration */}} +{{- define "dremio.dremio-conf.common.default" -}} +paths.local: {{ .Values.masterCoordinator.persistence.mountPath | quote }} +{{- if or (eq .Values.dremio.distStorageType "minio") (eq .Values.dremio.distStorageType "aws") }} +paths.dist: {{ printf "dremioS3://%s%s" (include "dremio.s3.bucket" .) (include "dremio.s3.path" .) | quote }} +{{- end }} +zookeeper: {{ include "dremio.zookeeper.hosts-with-port" . | quote }} +{{- /* Container ports */}} +services.coordinator.web.port: {{ .Values.dremio.containerPorts.web }} +services.coordinator.client-endpoint.port: {{ .Values.dremio.containerPorts.client }} +services.flight.port: {{ .Values.dremio.containerPorts.flight }} +services.fabric.port: {{ .Values.dremio.containerPorts.fabric }} +services.conduit.port: {{ .Values.dremio.containerPorts.conduit }} +services.web-admin.port: {{ .Values.dremio.containerPorts.liveness }} +services.web-admin.host: {{ print "{{ POD_IP }}" | quote }} +{{- if .Values.dremio.tls.enabled }} +services.coordinator.web.ssl.enabled: true +{{- /* We skip Dremio cert auto-generation and rely on the chart instead */}} +services.coordinator.web.ssl.auto-certificate.enabled: false +services.coordinator.web.ssl.keyStore: "/opt/bitnami/dremio/certs/dremio.jks" +services.coordinator.web.ssl.keyStoreType: "jks" +{{- end }} +{{- end }} + +{{/* Return common dremio.conf configuration (sensitive) */}} +{{- define "dremio.dremio-conf.common.defaultSecret" -}} +{{- if .Values.dremio.tls.enabled }} +{{- /* Set the value dependant on env vars so we can use external secrets */ -}} +services.coordinator.web.ssl.keyStorePassword: {{ print "{{ DREMIO_KEYSTORE_PASSWORD }}" | quote }} +{{- end }} +{{- end }} + +{{- define "dremio.dremio-conf.flattenYAML" -}} +{{- /* Moving parameters to vars before entering the range */ -}} +{{- $prefix := .prefix -}} +{{- /* Loop through the values of the map */ -}} +{{- range $key, $val := .config -}} +{{- $varName := ternary $key (list $prefix $key | join ".") (eq $prefix "") -}} +{{- if kindOf $val | eq "map" -}} +{{- /* If the variable is a map, we call the helper recursively, adding the semi-computed variable name as the prefix */ -}} +{{ include "dremio.dremio-conf.flattenYAML" (dict "config" $val "prefix" $varName) }} +{{- else }} +{{- /* Base case: We reached to a value that is not a map (sting, integer, boolean, array), so we can build the variable */ -}} +{{- if kindOf $val | eq "slice" -}} +{{- /* If it is an array we use the join function to create an array with commas */}} +{{ $varName }}: [{{ join "," $val }}] +{{- else if kindOf $val | eq "string" -}} +{{- /* String, quote */}} +{{ $varName }}: {{ $val | quote }} +{{- else -}} +{{- /* Integer or boolean */}} +{{ $varName }}: {{ $val }} +{{- end }} +{{- end -}} +{{- end -}} +{{- end -}} + +{{/* +Return MinIO(TM) fullname +*/}} +{{- define "dremio.minio.fullname" -}} +{{- include "common.names.dependency.fullname" (dict "chartName" "minio" "chartValues" .Values.minio "context" $) -}} +{{- end -}} + +{{/* +Return the S3 backend host +*/}} +{{- define "dremio.s3.host" -}} + {{- if .Values.minio.enabled -}} + {{- include "dremio.minio.fullname" . -}} + {{- else -}} + {{- print .Values.externalS3.host -}} + {{- end -}} +{{- end -}} + +{{/* +Return the S3 backend host +*/}} +{{- define "dremio.s3.protocol" -}} + {{- if .Values.minio.enabled -}} + {{- ternary "https" "http" .Values.minio.tls.enabled -}} + {{- else -}} + {{- .Values.externalS3.protocol -}} + {{- end -}} +{{- end -}} + +{{/* +Return the S3 bucket +*/}} +{{- define "dremio.s3.bucket" -}} + {{- if .Values.minio.enabled -}} + {{- print .Values.minio.defaultBuckets -}} + {{- else -}} + {{- print .Values.externalS3.bucket -}} + {{- end -}} +{{- end -}} + +{{/* +Return the S3 region +*/}} +{{- define "dremio.s3.region" -}} + {{- if .Values.minio.enabled -}} + {{- print "us-east-1" -}} + {{- else -}} + {{- print .Values.externalS3.region -}} + {{- end -}} +{{- end -}} + +{{/* +Return the S3 port +*/}} +{{- define "dremio.s3.port" -}} +{{- ternary .Values.minio.service.ports.api .Values.externalS3.port .Values.minio.enabled -}} +{{- end -}} + +{{/* +Return the S3 path +*/}} +{{- define "dremio.s3.path" -}} +{{- ternary "/dremio" .Values.externalS3.path .Values.minio.enabled -}} +{{- end -}} + +{{/* +Return the S3 credentials secret name +*/}} +{{- define "dremio.s3.secretName" -}} +{{- if .Values.minio.enabled -}} + {{- if .Values.minio.auth.existingSecret -}} + {{- print .Values.minio.auth.existingSecret -}} + {{- else -}} + {{- print (include "dremio.minio.fullname" .) -}} + {{- end -}} +{{- else if .Values.externalS3.existingSecret -}} + {{- print .Values.externalS3.existingSecret -}} +{{- else -}} + {{- printf "%s-%s" (include "common.names.fullname" .) "externals3" -}} +{{- end -}} +{{- end -}} + +{{/* +Return the S3 access key id inside the secret +*/}} +{{- define "dremio.s3.accessKeyIDKey" -}} + {{- if .Values.minio.enabled -}} + {{- print "root-user" -}} + {{- else -}} + {{- print .Values.externalS3.existingSecretAccessKeyIDKey -}} + {{- end -}} +{{- end -}} + +{{/* +Return the S3 secret access key inside the secret +*/}} +{{- define "dremio.s3.secretAccessKeyKey" -}} + {{- if .Values.minio.enabled -}} + {{- print "root-password" -}} + {{- else -}} + {{- print .Values.externalS3.existingSecretKeySecretKey -}} + {{- end -}} +{{- end -}} + +{{/* +Return Zookeeper fullname +*/}} +{{- define "dremio.zookeeper.fullname" -}} +{{- include "common.names.dependency.fullname" (dict "chartName" "zookeeper" "chartValues" .Values.zookeeper "context" $) -}} +{{- end -}} + +{{/* +Return zookeeper port +*/}} +{{- define "dremio.zookeeper.port" -}} +{{- if .Values.zookeeper.enabled -}} + {{- print .Values.zookeeper.containerPorts.client -}} +{{- else -}} + {{- print .Values.externalZookeeper.port -}} +{{- end -}} +{{- end -}} + +{{/* +Return zookeeper port +*/}} +{{- define "dremio.zookeeper.hosts-with-port" -}} +{{- $context := . -}} +{{- $res := list -}} +{{- if .Values.zookeeper.enabled -}} + {{- $fullname := include "dremio.zookeeper.fullname" . -}} + {{- $port := include "dremio.zookeeper.port" . | int -}} + {{- range $i, $e := until (.Values.zookeeper.replicaCount | int) -}} + {{- $res = append $res (printf "%s-%d.%s-headless.%s.svc:%d" $fullname $i $fullname $context.Release.Namespace $port) -}} + {{- end -}} +{{- else -}} + {{- $port := .Values.externalZookeeper.port | int -}} + {{- range .Values.externalZookeeper.servers -}} + {{- $res = append $res (printf "%s:%d" . $port) -}} + {{- end -}} +{{- end -}} +{{- join "," $res -}} +{{- end -}} + +{{/* +Compile all warnings into a single message. +*/}} +{{- define "dremio.validateValues" -}} +{{- $messages := list -}} +{{- $messages := without $messages "" -}} +{{- $message := join "\n" $messages -}} +{{- $messages := append $messages (include "dremio.validateValues.minio" .) -}} +{{- $messages := append $messages (include "dremio.validateValues.extraVolumes" .) -}} +{{- $messages := append $messages (include "dremio.validateValues.executor" .) -}} +{{- $messages := append $messages (include "dremio.validateValues.master-coordinator" .) -}} +{{- $messages := append $messages (include "dremio.validateValues.dist-storage" .) -}} +{{- if $message -}} +{{- printf "\nVALUES VALIDATION:\n%s" $message -}} +{{- end -}} +{{- end -}} + +{{/* Validate values of dremio - MinIO is properly configured */}} +{{- define "dremio.validateValues.minio" -}} +{{- if and (eq .Values.dremio.distStoreType "minio") (not .Values.minio.enabled) (not .Values.externalS3.host) -}} +dremio: minio + Distributed store type is set to minio but endpoint is not configured. Please set minio.enabled=true or configure the externalS3 section. +{{- end -}} +{{- end -}} + +{{/* Validate values of dremio - Incorrect extra volume settings */}} +{{- define "dremio.validateValues.extraVolumes" -}} +{{- $componentList := list "masterCoordinator" "coordinator" "executor.common" }} +{{- $values := .Values -}} +{{- range $component := $componentList }} +{{- $componentValues := index $values $component }} +{{- if and $componentValues.extraVolumes (not $componentValues.extraVolumeMounts) }} +dremio: missing-extra-volume-mounts + You specified {{ $component }}.extraVolumes but not mount points for them. Please set + the {{ $component }}.extraVolumeMounts value +{{- end }} +{{- end }} +{{- end -}} + +{{/* Validate values of dremio - MinIO is properly configured */}} +{{- define "dremio.validateValues.executor" -}} +{{- if not .Values.executor.engines -}} +dremio: missing-engines + You did not specify any engine for the executors. Please set the executor.engines section. +{{- end -}} +{{- end -}} + +{{/* Validate values of dremio - MinIO is properly configured */}} +{{- define "dremio.validateValues.master-coordinator" -}} +{{- if le (int .Values.masterCoordinator.replicaCount) 0 -}} +dremio: master-coordinator + Dremio requires a master coordinator. Please set masterCoordinator.replicaCount to a minimum value of 1. +{{- end -}} +{{- end -}} + +{{/* Validate values of dremio - MinIO is properly configured */}} +{{- define "dremio.validateValues.dist-storage" -}} +{{- $allowedValues := list "aws" "minio" "other" -}} +{{- if not (has .Values.dremio.distStorageType $allowedValues) -}} +dremio: dist-storage + Allowed values for `distStorageType` are {{ join "," $allowedValues }}. +{{- end -}} +{{- end -}} diff --git a/bitnami/dremio/templates/_init_containers.tpl b/bitnami/dremio/templates/_init_containers.tpl new file mode 100644 index 0000000000..afb7bbdb14 --- /dev/null +++ b/bitnami/dremio/templates/_init_containers.tpl @@ -0,0 +1,494 @@ + +{{/* +Init container definition for generating the configuration +*/}} +{{- define "dremio.init-containers.generate-conf" -}} +# This init container renders and merges the Dremio configuration files. +# We need to use a volume because we're working with ReadOnlyRootFilesystem +- name: generate-conf + image: {{ include "dremio.init-containers.default-image" .context }} + imagePullPolicy: {{ .context.Values.defaultInitContainers.defaultImage.pullPolicy }} + {{- if .context.Values.defaultInitContainers.generateConf.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .context.Values.defaultInitContainers.generateConf.containerSecurityContext "context" .context) | nindent 4 }} + {{- end }} + {{- if .context.Values.defaultInitContainers.generateConf.resources }} + resources: {{- toYaml .context.Values.defaultInitContainers.generateConf.resources | nindent 4 }} + {{- else if ne .context.Values.defaultInitContainers.generateConf.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .context.Values.defaultInitContainers.generateConf.resourcesPreset) | nindent 4 }} + {{- end }} + command: + - bash + args: + - -ec + - | + set -e + {{- if .context.Values.usePasswordFile }} + # We need to load all the secret env vars to the system + for file in $(find /bitnami/dremio/secrets -type f); do + env_var_name="$(basename $file)" + echo "Exporting $env_var_name" + export $env_var_name="$(< $file)" + done + {{- end }} + + # dremio.conf -> We concatenate the configuration from configmap + secret and then + # perform render-template to substitute all the environment variable references + + echo "Expanding env vars from dremio.conf" + find /bitnami/dremio/input-dremio -type f -name dremio.conf -print0 | sort -z | xargs -0 cat > /bitnami/dremio/rendered-conf/pre-render-dremio.conf + render-template /bitnami/dremio/rendered-conf/pre-render-dremio.conf > /bitnami/dremio/rendered-conf/dremio.conf + rm /bitnami/dremio/rendered-conf/pre-render-dremio.conf + + # Files different from dremio.conf -> Here we only apply render-template to expand the env vars + for file in $(find /bitnami/dremio/input-dremio -type f -not -name dremio.conf); do + filename="$(basename $file)" + echo "Expanding env vars from $filename" + render-template "$file" > /bitnami/dremio/rendered-conf/$filename + done + echo "Configuration generated" + env: + - name: BITNAMI_DEBUG + value: {{ ternary "true" "false" (or .context.Values.dremio.image.debug .context.Values.diagnosticMode.enabled) | quote }} + {{- if not .context.Values.usePasswordFile }} + {{- if or .context.Values.dremio.tls.passwordSecret .context.Values.dremio.tls.password .context.Values.dremio.tls.autoGenerated.enabled .context.Values.dremio.tls.usePemCerts }} + - name: DREMIO_KEYSTORE_PASSWORD + valueFrom: + secretKeyRef: + name: {{ include "dremio.tls.passwordSecretName" .context }} + key: keystore-password + {{- end }} + {{- if or (eq .context.Values.dremio.distStorageType "minio") (eq .context.Values.dremio.distStorageType "aws") }} + - name: DREMIO_AWS_ACCESS_KEY_ID + valueFrom: + secretKeyRef: + name: {{ include "dremio.s3.secretName" .context }} + key: {{ include "dremio.s3.accessKeyIDKey" .context | quote }} + - name: DREMIO_AWS_SECRET_ACCESS_KEY + valueFrom: + secretKeyRef: + name: {{ include "dremio.s3.secretName" .context }} + key: {{ include "dremio.s3.secretAccessKeyKey" .context | quote }} + {{- end }} + {{- end }} + - name: POD_IP + valueFrom: + fieldRef: + fieldPath: status.podIP + {{- if .context.Values.defaultInitContainers.generateConf.extraEnvVars }} + {{- include "common.tplvalues.render" (dict "value" .context.Values.defaultInitContainers.generateConf.extraEnvVars "context" $) | nindent 4 }} + {{- end }} + envFrom: + {{- if .context.Values.defaultInitContainers.generateConf.extraEnvVarsCM }} + - configMapRef: + name: {{ include "common.tplvalues.render" (dict "value" .context.Values.defaultInitContainers.generateConf.extraEnvVarsCM "context" .context) }} + {{- end }} + {{- if .context.Values.defaultInitContainers.generateConf.extraEnvVarsSecret }} + - secretRef: + name: {{ include "common.tplvalues.render" (dict "value" .context.Values.defaultInitContainers.generateConf.extraEnvVarsSecret "context" .context) }} + {{- end }} + volumeMounts: + - name: input-dremio-conf-cm + mountPath: /bitnami/dremio/input-dremio/dremio-conf/configmap + {{- if .mountDremioConfSecret }} + - name: input-dremio-conf-secret + mountPath: /bitnami/dremio/input-dremio/dremio-conf/secret + {{- end }} + - name: input-core-site + mountPath: /bitnami/dremio/input-dremio/core-site + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + - name: empty-dir + mountPath: /bitnami/dremio/rendered-conf + subPath: app-conf-dir + {{- if .context.Values.usePasswordFile }} + {{- if or .context.Values.dremio.tls.passwordSecret .context.Values.dremio.tls.password .context.Values.dremio.tls.autoGenerated.enabled .context.Values.dremio.tls.usePemCerts }} + - name: keystore-password + mountPath: /bitnami/dremio/secrets/keystore-password + {{- end }} + {{- if or (eq .context.Values.dremio.distStorageType "minio") (eq .context.Values.dremio.distStorageType "aws") }} + - name: s3-credentials + mountPath: /bitnami/dremio/secrets/s3-credentials + {{- end }} + {{- end }} + {{- if .context.Values.defaultInitContainers.generateConf.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" .context.Values.defaultInitContainers.generateConf.extraVolumeMounts "context" .context) | nindent 4 }} + {{- end }} +{{- end -}} + +{{- define "dremio.init-containers.volume-permissions" -}} +{{- /* As most Bitnami charts have volumePermissions in the root, we add this overwrite to maintain a similar UX */}} +{{- $volumePermissionsValues := mustMergeOverwrite .context.Values.defaultInitContainers.volumePermissions .context.Values.volumePermissions }} +- name: volume-permissions + image: {{ include "dremio.init-containers.default-image" . }} + imagePullPolicy: {{ .context.Values.defaultInitContainers.defaultImage.pullPolicy | quote }} + command: + - /bin/bash + - -ec + - | + {{- if eq ( toString ( $volumePermissionsValues.containerSecurityContext.runAsUser )) "auto" }} + chown -R `id -u`:`id -G | cut -d " " -f2` {{ .componentValues.persistence.mountPath }} + {{- else }} + chown -R {{ .componentValues.containerSecurityContext.runAsUser }}:{{ .componentValues.podSecurityContext.fsGroup }} {{ .componentValues.persistence.mountPath }} + {{- end }} + {{- if $volumePermissionsValues.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $volumePermissionsValues.containerSecurityContext "context" $) | nindent 4 }} + {{- end }} + {{- if $volumePermissionsValues.resources }} + resources: {{- toYaml $volumePermissionsValues.resources | nindent 4 }} + {{- else if ne $volumePermissionsValues.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" $volumePermissionsValues.resourcesPreset) | nindent 4 }} + {{- end }} + volumeMounts: + - name: data + mountPath: {{ .componentValues.persistence.mountPath }} + {{- if .componentValues.persistence.subPath }} + subPath: {{ .componentValues.persistence.subPath }} + {{- end }} +{{- end -}} + +{{/* +Init container definition for waiting for the database to be ready +*/}} +{{- define "dremio.init-containers.wait-for-zookeeper" -}} +- name: wait-for-zookeeper + image: {{ include "dremio.init-containers.default-image" . }} + imagePullPolicy: {{ .Values.defaultInitContainers.defaultImage.pullPolicy }} + {{- if .Values.defaultInitContainers.wait.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.defaultInitContainers.wait.containerSecurityContext "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.defaultInitContainers.wait.resources }} + resources: {{- toYaml .Values.defaultInitContainers.wait.resources | nindent 4 }} + {{- else if ne .Values.defaultInitContainers.wait.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.defaultInitContainers.wait.resourcesPreset) | nindent 4 }} + {{- end }} + command: + - bash + args: + - -ec + - | + retry_while() { + local -r cmd="${1:?cmd is missing}" + local -r retries="${2:-12}" + local -r sleep_time="${3:-5}" + local return_value=1 + + read -r -a command <<< "$cmd" + for ((i = 1 ; i <= retries ; i+=1 )); do + "${command[@]}" && return_value=0 && break + sleep "$sleep_time" + done + return $return_value + } + + zookeeper_hosts=( + {{- if .Values.zookeeper.enabled }} + {{ include "dremio.zookeeper.fullname" . | quote }} + {{- else }} + {{- range $node :=.Values.externalZookeeper.servers }} + {{ print $node | quote }} + {{- end }} + {{- end }} + ) + + check_zookeeper() { + local -r zookeeper_host="${1:-?missing zookeeper}" + if wait-for-port --timeout=5 --host=${zookeeper_host} --state=inuse {{ include "dremio.zookeeper.port" . }}; then + return 0 + else + return 1 + fi + } + + for host in "${zookeeper_hosts[@]}"; do + echo "Checking connection to $host" + if retry_while "check_zookeeper $host"; then + echo "Connected to $host" + else + echo "Error connecting to $host" + exit 1 + fi + done + + echo "Connection success" + exit 0 +{{- end -}} + +{{/* +Init container definition for waiting for the database to be ready +*/}} +{{- define "dremio.init-containers.init-certs" -}} +- name: init-certs + image: {{ include "dremio.image" . }} + imagePullPolicy: {{ .Values.dremio.image.pullPolicy }} + {{- if .Values.defaultInitContainers.initCerts.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.defaultInitContainers.initCerts.containerSecurityContext "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.defaultInitContainers.initCerts.resources }} + resources: {{- toYaml .Values.defaultInitContainers.initCerts.resources | nindent 4 }} + {{- else if ne .Values.defaultInitContainers.initCerts.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.defaultInitContainers.initCerts.resourcesPreset) | nindent 4 }} + {{- end }} + command: + - bash + args: + - -ec + - | + set -e + {{- if .context.Values.usePasswordFile }} + # We need to load all the secret env vars to the system + for file in $(find /bitnami/dremio/secrets -type f); do + env_var_name="$(basename $file)" + echo "Exporting $env_var_name" + export $env_var_name="$(< $file)" + done + {{- end }} + {{- if .Values.dremio.tls.usePemCerts }} + if [[ -f "/certs/tls.key" ]] && [[ -f "/certs/tls.crt" ]]; then + openssl pkcs12 -export -in "/certs/tls.crt" \ + -passout pass:"${DREMIO_KEYSTORE_PASSWORD}" \ + -inkey "/certs/tls.key" \ + -out "/tmp/keystore.p12" + keytool -importkeystore -srckeystore "/tmp/keystore.p12" \ + -srcstoretype PKCS12 \ + -srcstorepass "${DREMIO_KEYSTORE_PASSWORD}" \ + -deststorepass "${DREMIO_KEYSTORE_PASSWORD}" \ + -destkeystore "/opt/bitnami/dremio/certs/dremio.jks" + rm "/tmp/keystore.p12" + else + echo "Couldn't find the expected PEM certificates! They are mandatory when encryption via TLS is enabled." + exit 1 + fi + {{- else }} + if [[ -f "/certs/dremio.jks" ]]; then + cp "/certs/dremio.jks" "/opt/bitnami/dremio/certs/dremio.jks" + else + echo "Couldn't find the expected Java Key Stores (JKS) files! They are mandatory when encryption via TLS is enabled." + exit 1 + fi + {{- end }} + env: + {{- if not .Values.usePasswordFile }} + {{- if or .Values.dremio.tls.passwordSecret .Values.dremio.tls.password .Values.dremio.tls.autoGenerated.enabled .Values.dremio.tls.usePemCerts }} + - name: DREMIO_KEYSTORE_PASSWORD + valueFrom: + secretKeyRef: + name: {{ include "dremio.tls.passwordSecretName" . }} + key: keystore-password + {{- end }} + {{- end }} + volumeMounts: + - name: input-tls-certs + mountPath: /certs + - name: empty-dir + mountPath: /opt/bitnami/dremio/certs + subPath: app-processed-certs-dir + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + {{- if .Values.usePasswordFile }} + {{- if or .Values.dremio.tls.passwordSecret .Values.dremio.tls.password .Values.dremio.tls.autoGenerated.enabled .Values.dremio.tls.usePemCerts }} + - name: keystore-password + mountPath: /bitnami/dremio/secrets/keystore-password + {{- end }} + {{- end }} +{{- end -}} + +{{/* +Init container definition for waiting for the database to be ready +*/}} +{{- define "dremio.init-containers.copy-default-conf" -}} +- name: copy-default-conf + image: {{ include "dremio.image" . }} + imagePullPolicy: {{ .Values.dremio.image.pullPolicy }} + {{- if .Values.defaultInitContainers.copyDefaultConf.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.defaultInitContainers.copyDefaultConf.containerSecurityContext "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.defaultInitContainers.copyDefaultConf.resources }} + resources: {{- toYaml .Values.defaultInitContainers.copyDefaultConf.resources | nindent 4 }} + {{- else if ne .Values.defaultInitContainers.copyDefaultConf.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.defaultInitContainers.copyDefaultConf.resourcesPreset) | nindent 4 }} + {{- end }} + command: + - bash + args: + - -ec + - | + set -e + echo "Copying configuration files from /opt/bitnami/dremio/conf to empty-dir volume" + # First copy the default configuration files so we can fully replace the folder + + cp /opt/bitnami/dremio/conf/* /bitnami/dremio/conf/ + volumeMounts: + - name: empty-dir + mountPath: /bitnami/dremio/conf + subPath: app-conf-dir +{{- end -}} + +{{/* +Init container definition for waiting for the database to be ready +*/}} +{{- define "dremio.init-containers.upgrade-keystore" -}} +- name: upgrade-keystore + image: {{ include "dremio.image" . }} + imagePullPolicy: {{ .Values.dremio.image.pullPolicy }} + {{- if .Values.defaultInitContainers.upgradeKeystore.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.defaultInitContainers.upgradeKeystore.containerSecurityContext "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.defaultInitContainers.upgradeKeystore.resources }} + resources: {{- toYaml .Values.defaultInitContainers.upgradeKeystore.resources | nindent 4 }} + {{- else if ne .Values.defaultInitContainers.upgradeKeystore.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.defaultInitContainers.upgradeKeystore.resourcesPreset) | nindent 4 }} + {{- end }} + command: + - /opt/bitnami/scripts/dremio/entrypoint.sh + args: + - dremio-admin + - upgrade + env: + - name: BITNAMI_DEBUG + value: {{ ternary "true" "false" (or .Values.dremio.image.debug .Values.diagnosticMode.enabled) | quote }} + volumeMounts: + - name: empty-dir + mountPath: /.dremio + subPath: tmp-dir + - name: data + mountPath: {{ .Values.masterCoordinator.persistence.mountPath }} + {{- if .Values.masterCoordinator.persistence.subPath }} + subPath: {{ .Values.masterCoordinator.persistence.subPath }} + {{- end }} + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/tmp + subPath: app-tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/run + subPath: app-run-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/log + subPath: app-log-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/conf + subPath: app-conf-dir + {{- if .Values.dremio.tls.enabled }} + - name: empty-dir + mountPath: /opt/bitnami/dremio/certs + subPath: app-processed-certs-dir + {{- end }} +{{- end -}} + +{{/* +Init container definition for waiting for the database to be ready +*/}} +{{- define "dremio.init-containers.wait-for-s3" -}} +- name: wait-for-s3 + image: {{ include "dremio.init-containers.default-image" . }} + imagePullPolicy: {{ .Values.defaultInitContainers.defaultImage.pullPolicy }} + {{- if .Values.defaultInitContainers.wait.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.defaultInitContainers.wait.containerSecurityContext "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.defaultInitContainers.wait.resources }} + resources: {{- toYaml .Values.defaultInitContainers.wait.resources | nindent 4 }} + {{- else if ne .Values.defaultInitContainers.wait.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.defaultInitContainers.wait.resourcesPreset) | nindent 4 }} + {{- end }} + command: + - bash + args: + - -ec + - | + retry_while() { + local -r cmd="${1:?cmd is missing}" + local -r retries="${2:-12}" + local -r sleep_time="${3:-5}" + local return_value=1 + + read -r -a command <<< "$cmd" + for ((i = 1 ; i <= retries ; i+=1 )); do + "${command[@]}" && return_value=0 && break + sleep "$sleep_time" + done + return $return_value + } + + check_s3() { + local -r s3_host="${1:-?missing s3}" + if curl -k --max-time 5 "${s3_host}" | grep "RequestId"; then + return 0 + else + return 1 + fi + } + + host={{ printf "%s://%v:%v" (include "dremio.s3.protocol" .) (include "dremio.s3.host" .) (include "dremio.s3.port" .) }} + + echo "Checking connection to $host" + if retry_while "check_s3 $host"; then + echo "Connected to $host" + else + echo "Error connecting to $host" + exit 1 + fi + + echo "Connection success" + exit 0 +{{- end -}} + +{{/* +Init container definition for waiting for the database to be ready +*/}} +{{- define "dremio.init-containers.wait-for-master-coordinator" -}} +- name: wait-for-master-coordinator + image: {{ include "dremio.init-containers.default-image" . }} + imagePullPolicy: {{ .Values.defaultInitContainers.defaultImage.pullPolicy }} + {{- if .Values.defaultInitContainers.wait.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.defaultInitContainers.wait.containerSecurityContext "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.defaultInitContainers.wait.resources }} + resources: {{- toYaml .Values.defaultInitContainers.wait.resources | nindent 4 }} + {{- else if ne .Values.defaultInitContainers.wait.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.defaultInitContainers.wait.resourcesPreset) | nindent 4 }} + {{- end }} + command: + - bash + args: + - -ec + - | + retry_while() { + local -r cmd="${1:?cmd is missing}" + local -r retries="${2:-12}" + local -r sleep_time="${3:-5}" + local return_value=1 + + read -r -a command <<< "$cmd" + for ((i = 1 ; i <= retries ; i+=1 )); do + "${command[@]}" && return_value=0 && break + sleep "$sleep_time" + done + return $return_value + } + + check_master_coordinator() { + local -r master_coordinator_host="${1:-?missing master_coordinator}" + if curl -k --max-time 5 "${master_coordinator_host}" | grep dremio; then + return 0 + else + return 1 + fi + } + + host="{{ ternary "https" "http" .Values.dremio.tls.enabled }}://{{ include "dremio.master-coordinator.fullname" . }}-0.{{ printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}:{{ .Values.dremio.containerPorts.web }}" + + echo "Checking connection to $host" + if retry_while "check_master_coordinator $host"; then + echo "Connected to $host" + else + echo "Error connecting to $host" + exit 1 + fi + + echo "Connection success" + exit 0 +{{- end -}} \ No newline at end of file diff --git a/bitnami/dremio/templates/bootstrap-user/job.yaml b/bitnami/dremio/templates/bootstrap-user/job.yaml new file mode 100644 index 0000000000..42aa8951d0 --- /dev/null +++ b/bitnami/dremio/templates/bootstrap-user/job.yaml @@ -0,0 +1,136 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if (include "dremio.bootstrap-user-job.create" .) }} +apiVersion: batch/v1 +kind: Job +metadata: + name: {{ printf "%s-bootstrap-user" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" (list .Values.commonLabels .Values.bootstrapUserJob.labels) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: bootstrap-user + {{- if or .Values.bootstrapUserJob.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list .Values.coordinator.statefulsetAnnotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + backoffLimit: {{ .Values.bootstrapUserJob.backoffLimit }} + template: + metadata: + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.bootstrapUserJob.podLabels .Values.commonLabels ) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $podLabels "context" $ ) | nindent 8 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: bootstrap-user + {{- if .Values.bootstrapUserJob.podAnnotations }} + annotations: {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.podAnnotations "context" $) | nindent 8 }} + {{- end }} + spec: + {{- include "dremio.imagePullSecrets" . | nindent 6 }} + restartPolicy: OnFailure + {{- if .Values.bootstrapUserJob.podSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.bootstrapUserJob.podSecurityContext "context" $) | nindent 8 }} + {{- end }} + automountServiceAccountToken: {{ .Values.bootstrapUserJob.automountServiceAccountToken }} + {{- if .Values.bootstrapUserJob.hostAliases }} + hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.hostAliases "context" $) | nindent 8 }} + {{- end }} + initContainers: + {{- if .Values.defaultInitContainers.wait.enabled }} + {{- include "dremio.init-containers.wait-for-master-coordinator" . | nindent 8 }} + {{- end }} + containers: + - name: bootstrap-user + image: {{ include "dremio.init-containers.default-image" . }} + imagePullPolicy: {{ .Values.defaultInitContainers.defaultImage.pullPolicy }} + command: + - /bin/bash + - -ec + args: + - | + set -e + {{- if .Values.usePasswordFile }} + # We need to load all the secret env vars to the system + for file in $(find /bitnami/dremio/secrets -type f); do + env_var_name="$(basename $file)" + echo "Exporting $env_var_name" + export $env_var_name="$(< $file)" + done + {{- end }} + escaped_password="${DREMIO_PASSWORD//\"/\\\"}" + url="{{ ternary "https" "http" .Values.dremio.tls.enabled }}://{{ include "dremio.master-coordinator.fullname" . }}-0.{{ printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }}:{{ .Values.dremio.containerPorts.web }}/apiv2/bootstrap/firstuser" + echo "Bootstapping user {{ .Values.dremio.auth.username }} in endpoint $url" + curl -k "$url" -X PUT \ + -H 'Authorization: _dremionull' -H 'Content-Type: application/json' \ + --data-binary "{\"userName\":\"{{ .Values.dremio.auth.username }}\",\"firstName\":\"{{ .Values.dremio.auth.firstName }}\",\"lastName\":\"{{ .Values.dremio.auth.lastName }}\",\"email\":\"{{ .Values.dremio.auth.email }}\",\"createdAt\":$(date +%s),\"password\":\"${escaped_password}\"}" + echo "" # To generate a newline in the log because of the curl command + {{- if .Values.bootstrapUserJob.extraCommands }} + echo "Executing extra commands" + {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.extraCommands "context" $) | nindent 14 }} + {{- end }} + echo "Initialization finished" + env: + {{- if not .Values.usePasswordFile }} + - name: DREMIO_PASSWORD + valueFrom: + secretKeyRef: + name: {{ include "dremio.auth.secretName" . }} + key: {{ include "dremio.auth.passwordKey" . }} + {{- end }} + {{- if .Values.bootstrapUserJob.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.bootstrapUserJob.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.bootstrapUserJob.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.customLivenessProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.bootstrapUserJob.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.customReadinessProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.bootstrapUserJob.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.customStartupProbe "context" $) | nindent 12 }} + {{- end }} + {{- if or .Values.bootstrapUserJob.extraEnvVarsCM .Values.bootstrapUserJob.extraEnvVarsSecret }} + envFrom: + {{- if .Values.bootstrapUserJob.extraEnvVarsCM }} + - configMapRef: + name: {{ .Values.bootstrapUserJob.extraEnvVarsCM }} + {{- end }} + {{- if .Values.bootstrapUserJob.extraEnvVarsSecret }} + - secretRef: + name: {{ .Values.bootstrapUserJob.extraEnvVarsSecret }} + {{- end }} + {{- end }} + volumeMounts: + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + {{- if .Values.usePasswordFile }} + - name: password + mountPath: /bitnami/dremio/secrets/password + {{- end }} + {{- if .Values.bootstrapUserJob.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.extraVolumeMounts "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.bootstrapUserJob.resources }} + resources: {{- toYaml .Values.bootstrapUserJob.resources | nindent 12 }} + {{- else if ne .Values.bootstrapUserJob.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.bootstrapUserJob.resourcesPreset) | nindent 12 }} + {{- end }} + volumes: + - name: empty-dir + emptyDir: {} + {{- if .Values.usePasswordFile }} + - name: password + secret: + secretName: {{ include "dremio.auth.secretName" . }} + items: + - key: {{ include "dremio.auth.passwordKey" . }} + path: DREMIO_PASSWORD + {{- end }} + {{- if .Values.bootstrapUserJob.extraVolumes }} + {{- include "common.tplvalues.render" (dict "value" .Values.bootstrapUserJob.extraVolumes "context" $) | nindent 8 }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/bootstrap-user/networkpolicy.yaml b/bitnami/dremio/templates/bootstrap-user/networkpolicy.yaml new file mode 100644 index 0000000000..e7d4b51cf8 --- /dev/null +++ b/bitnami/dremio/templates/bootstrap-user/networkpolicy.yaml @@ -0,0 +1,59 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.bootstrapUserJob.networkPolicy.enabled }} +kind: NetworkPolicy +apiVersion: {{ include "common.capabilities.networkPolicy.apiVersion" . }} +metadata: + name: {{ printf "%s-bootstrap-user" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.bootstrapUserJob.podLabels .Values.commonLabels ) "context" . ) }} + podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: bootstrap-user + policyTypes: + - Ingress + - Egress + {{- if .Values.bootstrapUserJob.networkPolicy.allowExternalEgress }} + egress: + - {} + {{- else }} + egress: + # Allow dns resolution + - ports: + - port: 53 + protocol: UDP + - port: 53 + protocol: TCP + # Allow outbound connections to other cluster pods + - ports: + - port: {{ .Values.dremio.containerPorts.web }} + - port: {{ .Values.dremio.containerPorts.client }} + - port: {{ .Values.dremio.containerPorts.flight }} + - port: {{ .Values.dremio.containerPorts.fabric }} + - port: {{ .Values.dremio.containerPorts.conduit }} + to: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 14 }} + part-of: dremio + {{- if .Values.bootstrapUserJob.networkPolicy.extraEgress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.bootstrapUserJob.networkPolicy.extraEgress "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} + ingress: + {{- if .Values.bootstrapUserJob.networkPolicy.extraIngress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.bootstrapUserJob.networkPolicy.extraIngress "context" $ ) | nindent 4 }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/ca-cert.yaml b/bitnami/dremio/templates/ca-cert.yaml new file mode 100644 index 0000000000..c3d69b385a --- /dev/null +++ b/bitnami/dremio/templates/ca-cert.yaml @@ -0,0 +1,60 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.dremio.tls.enabled .Values.dremio.tls.autoGenerated.enabled (eq .Values.dremio.tls.autoGenerated.engine "cert-manager") }} +{{- if empty .Values.dremio.tls.autoGenerated.certManager.existingIssuer }} +apiVersion: cert-manager.io/v1 +kind: Issuer +metadata: + name: {{ printf "%s-clusterissuer" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + selfSigned: {} +--- +{{- end }} +apiVersion: cert-manager.io/v1 +kind: Certificate +metadata: + name: {{ printf "%s-ca-crt" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + secretName: {{ printf "%s-ca-crt" (include "common.names.fullname" .) }} + commonName: {{ printf "%s-ca" (include "common.names.fullname" .) }} + isCA: true + issuerRef: + name: {{ default (printf "%s-clusterissuer" (include "common.names.fullname" .)) .Values.dremio.tls.autoGenerated.certManager.existingIssuer }} + kind: {{ default "Issuer" .Values.dremio.tls.autoGenerated.certManager.existingIssuerKind }} +--- +apiVersion: cert-manager.io/v1 +kind: Issuer +metadata: + name: {{ printf "%s-ca-issuer" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + ca: + secretName: {{ printf "%s-ca-crt" (include "common.names.fullname" .) }} +{{- end }} diff --git a/bitnami/dremio/templates/cert.yaml b/bitnami/dremio/templates/cert.yaml new file mode 100644 index 0000000000..b87c059f90 --- /dev/null +++ b/bitnami/dremio/templates/cert.yaml @@ -0,0 +1,45 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.dremio.tls.enabled .Values.dremio.tls.autoGenerated.enabled (eq .Values.dremio.tls.autoGenerated.engine "cert-manager") }} +apiVersion: cert-manager.io/v1 +kind: Certificate +metadata: + name: {{ printf "%s-crt" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + secretName: {{ printf "%s-crt" (include "common.names.fullname" .) }} + commonName: {{ printf "%s.%s.svc.%s" (include "common.names.fullname" .) (include "common.names.namespace" .) .Values.clusterDomain }} + issuerRef: + name: {{ printf "%s-ca-issuer" (include "common.names.fullname" .) }} + kind: Issuer + subject: + organizations: + - "Dremio" + dnsNames: + - '*.{{ include "common.names.namespace" . }}' + - '*.{{ include "common.names.namespace" . }}.svc' + - '*.{{ include "common.names.namespace" . }}.svc.{{ .Values.clusterDomain }}' + - '*.{{ include "common.names.fullname" . }}' + - '*.{{ include "common.names.fullname" . }}.{{ include "common.names.namespace" . }}' + - '*.{{ include "common.names.fullname" . }}.{{ include "common.names.namespace" . }}.svc' + - '*.{{ include "common.names.fullname" . }}.{{ include "common.names.namespace" . }}.svc.{{ .Values.clusterDomain }}' + - '*.{{ printf "%s-headless" (include "common.names.fullname" .) }}' + - '*.{{ printf "%s-headless" (include "common.names.fullname" .) }}.{{ include "common.names.namespace" . }}' + - '*.{{ printf "%s-headless" (include "common.names.fullname" .) }}.{{ include "common.names.namespace" . }}.svc' + - '*.{{ printf "%s-headless" (include "common.names.fullname" .) }}.{{ include "common.names.namespace" . }}.svc.{{ .Values.clusterDomain }}' + privateKey: + algorithm: {{ .Values.dremio.tls.autoGenerated.certManager.keyAlgorithm }} + size: {{ int .Values.dremio.tls.autoGenerated.certManager.keySize }} + duration: {{ .Values.dremio.tls.autoGenerated.certManager.duration }} + renewBefore: {{ .Values.dremio.tls.autoGenerated.certManager.renewBefore }} +{{- end }} diff --git a/bitnami/dremio/templates/coordinator/configmap-dremio-conf.yaml b/bitnami/dremio/templates/coordinator/configmap-dremio-conf.yaml new file mode 100644 index 0000000000..9de4fbcc3f --- /dev/null +++ b/bitnami/dremio/templates/coordinator/configmap-dremio-conf.yaml @@ -0,0 +1,50 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{/* Adding the helper in here for better readability */}} +{{- define "dremio.dremio-conf.coordinator.default" -}} +{{/* Common configuration */}} +{{- include "dremio.dremio-conf.common.default" . }} +{{/* Master coordinator settings */}} +services.coordinator.enabled: true +services.coordinator.master.enabled: false +services.coordinator.master.embedded-zookeeper.enabled: false +services.executor.enabled: false +{{- end }} + +{{- if not .Values.coordinator.dremioConf.existingConfigmap -}} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ printf "%s-dremio-conf" (include "dremio.coordinator.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + {{- $extraFiles := mustMergeOverwrite .Values.dremio.dremioConf.extraFiles .Values.coordinator.dremioConf.extraFiles }} + {{- if not (hasKey $extraFiles "dremio.conf") }} + {{- /* dremio.conf uses HOCON, in which flattened YAML is a subset. So converting all values to flattened YAML generates a valid HOCON configuration */}} + {{- $defaultConfiguration := include "dremio.dremio-conf.coordinator.default" . | fromYaml -}} + {{- /* Obtain first the flattened version of all YAML content so the merge works as expected */}} + {{- $defaultConfigurationFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $defaultConfiguration "prefix" "" "context" $) | fromYaml -}} + {{- $commonConfigOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.dremio.dremioConf.configOverrides "prefix" "" "context" $) | fromYaml -}} + {{- $configOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.coordinator.dremioConf.configOverrides "prefix" "" "context" $) | fromYaml -}} + {{- /* Override order: default configuration <- common overrides <- specific overrides */}} + {{- $mergedConfiguration := mustMergeOverwrite $defaultConfigurationFlat $commonConfigOverridesFlat }} + {{- $mergedConfiguration = mustMergeOverwrite $mergedConfiguration $configOverridesFlat }} + dremio.conf: | + {{- /* Apply the helper again to avoid arrays having a HOCON incompatible format */}} + {{- include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) | nindent 4 }} + {{- end }} + {{- if $extraFiles }} + {{- include "common.tplvalues.render" (dict "value" $extraFiles "context" $) | nindent 2 }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/coordinator/hpa.yaml b/bitnami/dremio/templates/coordinator/hpa.yaml new file mode 100644 index 0000000000..5679efee51 --- /dev/null +++ b/bitnami/dremio/templates/coordinator/hpa.yaml @@ -0,0 +1,52 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.coordinator.autoscaling.hpa.enabled }} +apiVersion: {{ include "common.capabilities.hpa.apiVersion" (dict "context" $) }} +kind: HorizontalPodAutoscaler +metadata: + name: {{ include "dremio.coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + scaleTargetRef: + apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} + kind: StatefulSet + name: {{ include "dremio.coordinator.fullname" . }} + minReplicas: {{ .Values.coordinator.autoscaling.hpa.minReplicas }} + maxReplicas: {{ .Values.coordinator.autoscaling.hpa.maxReplicas }} + metrics: + {{- if .Values.coordinator.autoscaling.hpa.targetMemory }} + - type: Resource + resource: + name: memory + {{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" .) }} + targetAverageUtilization: {{ .Values.coordinator.autoscaling.hpa.targetMemory }} + {{- else }} + target: + type: Utilization + averageUtilization: {{ .Values.coordinator.autoscaling.hpa.targetMemory }} + {{- end }} + {{- end }} + {{- if .Values.coordinator.autoscaling.hpa.targetCPU }} + - type: Resource + resource: + name: cpu + {{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" .) }} + targetAverageUtilization: {{ .Values.coordinator.autoscaling.hpa.targetCPU }} + {{- else }} + target: + type: Utilization + averageUtilization: {{ .Values.coordinator.autoscaling.hpa.targetCPU }} + {{- end }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/coordinator/networkpolicy.yaml b/bitnami/dremio/templates/coordinator/networkpolicy.yaml new file mode 100644 index 0000000000..5d43bed9fe --- /dev/null +++ b/bitnami/dremio/templates/coordinator/networkpolicy.yaml @@ -0,0 +1,122 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.coordinator.networkPolicy.enabled }} +kind: NetworkPolicy +apiVersion: {{ include "common.capabilities.networkPolicy.apiVersion" . }} +metadata: + name: {{ template "dremio.coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.coordinator.podLabels .Values.commonLabels ) "context" . ) }} + podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + app: dremio-coordinator + policyTypes: + - Ingress + - Egress + {{- if .Values.coordinator.networkPolicy.allowExternalEgress }} + egress: + - {} + {{- else }} + egress: + # Allow dns resolution + - ports: + - port: 53 + protocol: UDP + - port: 53 + protocol: TCP + # Allow outbound connections to other cluster pods + - ports: + - port: {{ .Values.dremio.containerPorts.web }} + - port: {{ .Values.dremio.containerPorts.client }} + - port: {{ .Values.dremio.containerPorts.flight }} + - port: {{ .Values.dremio.containerPorts.fabric }} + - port: {{ .Values.dremio.containerPorts.conduit }} + to: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 14 }} + part-of: dremio + # Allow outbound connections to S3 + - ports: + - port: {{ include "dremio.s3.port" . }} + {{- if .Values.minio.enabled }} + - port: {{ .Values.minio.containerPorts.api }} + to: + - podSelector: + matchLabels: + app.kubernetes.io/name: minio + app.kubernetes.io/instance: {{ .Release.Name }} + {{- end }} + # Allow outbound connections to zookeeper + - ports: + - port: {{ include "dremio.zookeeper.port" . }} + to: + {{- if .Values.zookeeper.enabled }} + - podSelector: + matchLabels: + app.kubernetes.io/name: zookeeper + app.kubernetes.io/instance: {{ .Release.Name }} + {{- end }} + {{- if .Values.coordinator.networkPolicy.extraEgress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.coordinator.networkPolicy.extraEgress "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} + ingress: + - ports: + - port: {{ .Values.dremio.containerPorts.web }} + - port: {{ .Values.dremio.containerPorts.client }} + - port: {{ .Values.dremio.containerPorts.flight }} + - port: {{ .Values.dremio.containerPorts.fabric }} + - port: {{ .Values.dremio.containerPorts.conduit }} + {{- if .Values.metrics.enabled }} + - port: {{ .Values.dremio.containerPorts.jmx }} + {{- end }} + {{- range .Values.coordinator.extraContainerPorts }} + - port: {{ . }} + {{- end }} + {{- if not .Values.coordinator.networkPolicy.allowExternal }} + from: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 14 }} + app.kubernetes.io/part-of: dremio + {{- if .Values.coordinator.networkPolicy.addExternalClientAccess }} + - podSelector: + matchLabels: + {{ template "dremio.coordinator.fullname" . }}-client: "true" + {{- end }} + {{- if .Values.coordinator.networkPolicy.ingressPodMatchLabels }} + - podSelector: + matchLabels: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.networkPolicy.ingressPodMatchLabels "context" $ ) | nindent 14 }} + {{- end }} + {{- if .Values.coordinator.networkPolicy.ingressNSMatchLabels }} + - namespaceSelector: + matchLabels: + {{- range $key, $value := .Values.coordinator.networkPolicy.ingressNSMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- if .Values.coordinator.networkPolicy.ingressNSPodMatchLabels }} + podSelector: + matchLabels: + {{- range $key, $value := .Values.coordinator.networkPolicy.ingressNSPodMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- end }} + {{- end }} + {{- end }} + {{- if .Values.coordinator.networkPolicy.extraIngress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.coordinator.networkPolicy.extraIngress "context" $ ) | nindent 4 }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/coordinator/pdb.yaml b/bitnami/dremio/templates/coordinator/pdb.yaml new file mode 100644 index 0000000000..0c894a91b4 --- /dev/null +++ b/bitnami/dremio/templates/coordinator/pdb.yaml @@ -0,0 +1,32 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.coordinator.pdb.create }} +apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} +kind: PodDisruptionBudget +metadata: + name: {{ include "dremio.coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.coordinator.pdb.minAvailable }} + minAvailable: {{ .Values.coordinator.pdb.minAvailable }} + {{- end }} + {{- if or .Values.coordinator.pdb.maxUnavailable ( not .Values.coordinator.pdb.minAvailable ) }} + maxUnavailable: {{ .Values.coordinator.pdb.maxUnavailable | default 1 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.coordinator.podLabels .Values.commonLabels ) "context" . ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator +{{- end }} diff --git a/bitnami/dremio/templates/coordinator/secret-dremio-conf.yaml b/bitnami/dremio/templates/coordinator/secret-dremio-conf.yaml new file mode 100644 index 0000000000..0ed626eca6 --- /dev/null +++ b/bitnami/dremio/templates/coordinator/secret-dremio-conf.yaml @@ -0,0 +1,42 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- $extraFiles := mustMergeOverwrite .Values.dremio.dremioConf.extraSecretFiles .Values.coordinator.dremioConf.extraSecretFiles }} +{{- $createDremioConf := or .Values.dremio.dremioConf.secretConfigOverrides .Values.coordinator.dremioConf.secretConfigOverrides .Values.dremio.tls.enabled }} +{{- if and (not .Values.coordinator.dremioConf.existingSecret) (or $createDremioConf $extraFiles) }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-dremio-conf" (include "dremio.coordinator.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +{{- /* We use stringData to simplify the templating of this file. It is as insecure as using base64 */}} +stringData: + {{- if and (not (hasKey $extraFiles "dremio.conf")) $createDremioConf }} + {{- /* dremio.conf uses HOCON, in which flattened YAML is a subset. So converting all values to flattened YAML generates a valid HOCON configuration */}} + {{- $defaultConfiguration := include "dremio.dremio-conf.common.defaultSecret" . | fromYaml -}} + {{- /* Obtain first the flattened version of all YAML content so the merge works as expected */}} + {{- $defaultConfigurationFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $defaultConfiguration "prefix" "" "context" $) | fromYaml -}} + {{- $commonConfigOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.dremio.dremioConf.secretConfigOverrides "prefix" "" "context" $) | fromYaml -}} + {{- $configOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.coordinator.dremioConf.secretConfigOverrides "prefix" "" "context" $) | fromYaml -}} + {{- /* Override order: default configuration <- common overrides <- specific overrides */}} + {{- $mergedConfiguration := mustMergeOverwrite $defaultConfigurationFlat $commonConfigOverridesFlat }} + {{- $mergedConfiguration = mustMergeOverwrite $mergedConfiguration $configOverridesFlat }} + {{- $result := include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) }} + {{- /* Apply the helper again to avoid arrays having a HOCON incompatible format */}} + dremio.conf: | + {{- include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) | nindent 4 }} + {{- end }} + {{- if $extraFiles }} + {{- include "common.tplvalues.render" (dict "value" $extraFiles "context" $) | nindent 2 }} + {{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/coordinator/service-account.yaml b/bitnami/dremio/templates/coordinator/service-account.yaml new file mode 100644 index 0000000000..3ad662db01 --- /dev/null +++ b/bitnami/dremio/templates/coordinator/service-account.yaml @@ -0,0 +1,22 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.coordinator.serviceAccount.create }} +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "dremio.coordinator.serviceAccountName" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.coordinator.serviceAccount.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list .Values.coordinator.serviceAccount.annotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +automountServiceAccountToken: {{ .Values.coordinator.serviceAccount.automountServiceAccountToken }} +{{- end }} diff --git a/bitnami/dremio/templates/coordinator/statefulset.yaml b/bitnami/dremio/templates/coordinator/statefulset.yaml new file mode 100644 index 0000000000..3871d4c805 --- /dev/null +++ b/bitnami/dremio/templates/coordinator/statefulset.yaml @@ -0,0 +1,394 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet +metadata: + name: {{ include "dremio.coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.coordinator.statefulsetAnnotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list .Values.coordinator.statefulsetAnnotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if not .Values.coordinator.autoscaling.hpa.enabled }} + replicas: {{ .Values.coordinator.replicaCount }} + {{- end }} + podManagementPolicy: {{ .Values.coordinator.podManagementPolicy | quote }} + {{- $podLabels := include "common.tplvalues.merge" (dict "values" (list .Values.coordinator.podLabels .Values.commonLabels) "context" .) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + app: dremio-coordinator + serviceName: {{ printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + {{- if .Values.coordinator.updateStrategy }} + updateStrategy: {{- toYaml .Values.coordinator.updateStrategy | nindent 4 }} + {{- end }} + template: + metadata: + annotations: + checksum/dremio-conf-cm: {{ include (print $.Template.BasePath "/coordinator/configmap-dremio-conf.yaml") . | sha256sum }} + checksum/dremio-conf-secret: {{ include (print $.Template.BasePath "/coordinator/secret-dremio-conf.yaml") . | sha256sum }} + checksum/core-site-secret: {{ include (print $.Template.BasePath "/secret-core-site.yaml") . | sha256sum }} + {{- if .Values.coordinator.podAnnotations }} + {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.podAnnotations "context" $) | nindent 8 }} + {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" $podLabels "context" $) | nindent 8 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + app: dremio-coordinator + spec: + {{- include "dremio.imagePullSecrets" . | nindent 6 }} + serviceAccountName: {{ template "dremio.coordinator.serviceAccountName" . }} + automountServiceAccountToken: {{ .Values.coordinator.automountServiceAccountToken }} + {{- if .Values.coordinator.hostAliases }} + hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.hostAliases "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.coordinator.affinity }} + affinity: {{- include "common.tplvalues.render" ( dict "value" .Values.coordinator.affinity "context" $) | nindent 8 }} + {{- else }} + affinity: + podAffinity: {{- include "common.affinities.pods" (dict "type" .Values.coordinator.podAffinityPreset "component" "coordinator" "customLabels" $podLabels "context" $) | nindent 10 }} + podAntiAffinity: {{- include "common.affinities.pods" (dict "type" .Values.coordinator.podAntiAffinityPreset "component" "coordinator" "customLabels" $podLabels "context" $) | nindent 10 }} + nodeAffinity: {{- include "common.affinities.nodes" (dict "type" .Values.coordinator.nodeAffinityPreset.type "key" .Values.coordinator.nodeAffinityPreset.key "values" .Values.coordinator.nodeAffinityPreset.values) | nindent 10 }} + {{- end }} + {{- if .Values.coordinator.nodeSelector }} + nodeSelector: {{- include "common.tplvalues.render" ( dict "value" .Values.coordinator.nodeSelector "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.coordinator.tolerations }} + tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.tolerations "context" .) | nindent 8 }} + {{- end }} + {{- if .Values.coordinator.priorityClassName }} + priorityClassName: {{ .Values.coordinator.priorityClassName | quote }} + {{- end }} + {{- if .Values.coordinator.schedulerName }} + schedulerName: {{ .Values.coordinator.schedulerName | quote }} + {{- end }} + {{- if .Values.coordinator.topologySpreadConstraints }} + topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.topologySpreadConstraints "context" .) | nindent 8 }} + {{- end }} + {{- if .Values.coordinator.podSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.coordinator.podSecurityContext "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.coordinator.terminationGracePeriodSeconds }} + terminationGracePeriodSeconds: {{ .Values.coordinator.terminationGracePeriodSeconds }} + {{- end }} + initContainers: + {{- /* As most Bitnami charts have volumePermissions in the root, we add a volumePermissions.enabled check to maintain a similar UX */}} + {{- if and (or .Values.defaultInitContainers.volumePermissions.enabled ((.Values.volumePermissions).enabled)) .Values.coordinator.persistence.enabled }} + {{- include "dremio.init-containers.volume-permissions" (dict "context" . "componentValues" .Values.coordinator) | nindent 8}} + {{- end }} + {{- if .Values.defaultInitContainers.copyDefaultConf.enabled }} + {{- include "dremio.init-containers.copy-default-conf" . | nindent 8 }} + {{- end }} + {{- if .Values.defaultInitContainers.wait.enabled }} + {{- include "dremio.init-containers.wait-for-s3" . | nindent 8 }} + {{- include "dremio.init-containers.wait-for-zookeeper" . | nindent 8 }} + {{- include "dremio.init-containers.wait-for-master-coordinator" . | nindent 8 }} + {{- end }} + {{- if .Values.defaultInitContainers.generateConf.enabled }} + {{- include "dremio.init-containers.generate-conf" (dict "context" . "mountDremioConfSecret" (include "dremio.coordinator.dremio-conf.useSecret" .)) | nindent 8 }} + {{- end }} + {{- if and .Values.dremio.tls.enabled .Values.defaultInitContainers.initCerts.enabled }} + {{- include "dremio.init-containers.init-certs" . | nindent 8 }} + {{- end }} + {{- if .Values.coordinator.initContainers }} + {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.initContainers "context" $) | nindent 8 }} + {{- end }} + containers: + - name: dremio + image: {{ template "dremio.image" . }} + imagePullPolicy: {{ .Values.dremio.image.pullPolicy }} + {{- if .Values.coordinator.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.coordinator.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.diagnosticMode.enabled }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 12 }} + {{- else if .Values.coordinator.command }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.command "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.diagnosticMode.enabled }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else if .Values.coordinator.args }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.args "context" $) | nindent 12 }} + {{- end }} + env: + - name: BITNAMI_DEBUG + value: {{ ternary "true" "false" (or .Values.dremio.image.debug .Values.diagnosticMode.enabled) | quote }} + - name: DREMIO_JAVA_SERVER_EXTRA_OPTS + value: | + {{- if and (eq .Values.dremio.distStorageType "minio") (or (and .Values.minio.enabled (((.Values.minio).tls).enabled) (((.Values.minio).tls).autoGenerated)) .Values.externalS3.disableCertChecking) }} + -Dcom.amazonaws.sdk.disableCertChecking=true + {{- end }} + {{- if .Values.metrics.enabled }} + -Dcom.sun.management.jmxremote.port={{ .Values.dremio.containerPorts.jmx }} + -Dcom.sun.management.jmxremote.authenticate=false + -Dcom.sun.management.jmxremote.ssl=false + {{- end }} + {{- if .Values.coordinator.extraJavaOpts }} + {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.extraJavaOpts "context" $) | nindent 16 }} + {{- end }} + - name: DREMIO_MAX_MEMORY_SIZE_MB + valueFrom: + resourceFieldRef: + containerName: dremio + resource: limits.memory + divisor: 1Mi + {{- if .Values.coordinator.extraEnvVars }} + {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.extraEnvVars "context" $) | nindent 12 }} + {{- end }} + envFrom: + {{- if .Values.coordinator.extraEnvVarsCM }} + - configMapRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.coordinator.extraEnvVarsCM "context" $) }} + {{- end }} + {{- if .Values.coordinator.extraEnvVarsSecret }} + - secretRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.coordinator.extraEnvVarsSecret "context" $) }} + {{- end }} + {{- if .Values.coordinator.resources }} + resources: {{- toYaml .Values.coordinator.resources | nindent 12 }} + {{- else if ne .Values.coordinator.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.coordinator.resourcesPreset) | nindent 12 }} + {{- end }} + ports: + - containerPort: {{ .Values.dremio.containerPorts.web }} + name: web + - containerPort: {{ .Values.dremio.containerPorts.client }} + name: client + - containerPort: {{ .Values.dremio.containerPorts.flight }} + name: flight + - containerPort: {{ .Values.dremio.containerPorts.liveness }} + name: liveness + - containerPort: {{ .Values.dremio.containerPorts.fabric }} + name: server-fabric + - containerPort: {{ .Values.dremio.containerPorts.conduit }} + name: server-conduit + {{- if .Values.metrics.enabled }} + - containerPort: {{ .Values.dremio.containerPorts.jmx }} + name: jmx + {{- end }} + {{- if .Values.coordinator.extraContainerPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.extraContainerPorts "context" $) | nindent 12 }} + {{- end }} + {{- if not .Values.diagnosticMode.enabled }} + {{- if .Values.coordinator.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.customLivenessProbe "context" $) | nindent 12 }} + {{- else if .Values.coordinator.livenessProbe.enabled }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.coordinator.livenessProbe "enabled") "context" $) | nindent 12 }} + tcpSocket: + port: liveness + {{- end }} + {{- if .Values.coordinator.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.customReadinessProbe "context" $) | nindent 12 }} + {{- else if .Values.coordinator.readinessProbe.enabled }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.coordinator.readinessProbe "enabled") "context" $) | nindent 12 }} + httpGet: + path: / + port: web + scheme: {{ ternary "HTTPS" "HTTP" .Values.dremio.tls.enabled }} + {{- end }} + {{- if .Values.coordinator.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.customStartupProbe "context" $) | nindent 12 }} + {{- else if .Values.coordinator.startupProbe.enabled }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.coordinator.startupProbe "enabled") "context" $) | nindent 12 }} + tcpSocket: + port: liveness + {{- end }} + {{- end }} + {{- if .Values.coordinator.lifecycleHooks }} + lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.lifecycleHooks "context" $) | nindent 12 }} + {{- end }} + volumeMounts: + - name: data + mountPath: {{ .Values.coordinator.persistence.mountPath }} + {{- if .Values.coordinator.persistence.subPath }} + subPath: {{ .Values.coordinator.persistence.subPath }} + {{- end }} + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/tmp + subPath: app-tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/run + subPath: app-run-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/log + subPath: app-log-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/conf + subPath: app-conf-dir + {{- if .Values.dremio.tls.enabled }} + - name: empty-dir + mountPath: /opt/bitnami/dremio/certs + subPath: app-processed-certs-dir + {{- end }} + {{- if .Values.metrics.enabled }} + - name: metrics-configuration + mountPath: /opt/bitnami/dremio/conf/dremio-telemetry.yaml + subPath: dremio-telemetry.yaml + {{- end }} + {{- if .Values.coordinator.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.extraVolumeMounts "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.metrics.enabled }} + - name: metrics + image: {{ include "dremio.metrics.image" . }} + imagePullPolicy: {{ .Values.metrics.image.pullPolicy | quote }} + {{- if .Values.metrics.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.metrics.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.diagnosticMode.enabled }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 12 }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else }} + command: + - java + args: + - -XX:MaxRAMPercentage=100 + - -XshowSettings:vm + - -jar + - jmx_prometheus_httpserver.jar + - {{ .Values.metrics.containerPorts.metrics | quote }} + - /etc/jmx-dremio/jmx-prometheus.yml + {{- if .Values.metrics.extraArgs }} + {{- include "common.tplvalues.render" ( dict "value" .Values.metrics.extraArgs "context" $) | nindent 12 }} + {{- end -}} + {{- end }} + ports: + - name: metrics + containerPort: {{ .Values.metrics.containerPorts.metrics }} + {{- if .Values.metrics.resources }} + resources: {{- toYaml .Values.metrics.resources | nindent 12 }} + {{- else if ne .Values.metrics.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.metrics.resourcesPreset) | nindent 12 }} + {{- end }} + {{- if not .Values.diagnosticMode.enabled }} + {{- if .Values.metrics.livenessProbe.enabled }} + livenessProbe: {{- omit .Values.metrics.livenessProbe "enabled" | toYaml | nindent 12 }} + tcpSocket: + port: metrics + {{- end }} + {{- if .Values.metrics.readinessProbe.enabled }} + readinessProbe: {{- omit .Values.metrics.readinessProbe "enabled" | toYaml | nindent 12 }} + httpGet: + path: / + port: metrics + {{- end }} + {{- if .Values.metrics.startupProbe.enabled }} + startupProbe: {{- omit .Values.metrics.startupProbe "enabled" | toYaml | nindent 12 }} + httpGet: + path: / + port: metrics + {{- end }} + {{- end }} + volumeMounts: + - name: metrics-configuration + mountPath: /etc/jmx-dremio/jmx-prometheus.yml + subPath: jmx-prometheus.yml + {{- end }} + {{- if .Values.coordinator.sidecars }} + {{- include "common.tplvalues.render" ( dict "value" .Values.coordinator.sidecars "context" $) | nindent 8 }} + {{- end }} + volumes: + - name: empty-dir + emptyDir: {} + {{- if .Values.usePasswordFile }} + {{- if or .Values.dremio.tls.passwordSecret .Values.dremio.tls.password .Values.dremio.tls.autoGenerated.enabled .Values.dremio.tls.usePemCerts }} + - name: keystore-password + secret: + secretName: {{ include "dremio.tls.passwordSecretName" . }} + items: + - key: keystore-password + path: DREMIO_KEYSTORE_PASSWORD + {{- end }} + {{- if or (eq .Values.dremio.distStorageType "minio") (eq .Values.dremio.distStorageType "aws") }} + - name: s3-credentials + secret: + secretName: {{ include "dremio.s3.secretName" . }} + items: + - key: {{ include "dremio.s3.accessKeyIDKey" . }} + path: DREMIO_AWS_ACCESS_KEY_ID + - key: {{ include "dremio.s3.secretAccessKeyKey" . }} + path: DREMIO_AWS_SECRET_ACCESS_KEY + {{- end }} + {{- end }} + - name: input-dremio-conf-cm + configMap: + name: {{ include "dremio.coordinator.dremio-conf.configmapName" . }} + {{- if (include "dremio.coordinator.dremio-conf.useSecret" .) }} + - name: input-dremio-conf-secret + secret: + secretName: {{ include "dremio.coordinator.dremio-conf.secretName" . }} + {{- end }} + - name: input-core-site + secret: + secretName: {{ include "dremio.core-site.secretName" . }} + {{- if .Values.metrics.enabled }} + - name: metrics-configuration + configMap: + name: {{ include "dremio.metrics.configmapName" . }} + {{- end }} + {{- if .Values.dremio.tls.enabled }} + - name: input-tls-certs + secret: + secretName: {{ include "dremio.tls.secretName" . }} + items: + {{- if .Values.dremio.tls.usePemCerts }} + - key: {{ .Values.dremio.tls.certFilename }} + path: tls.crt + - key: {{ .Values.dremio.tls.certKeyFilename }} + path: tls.key + {{- else }} + - key: {{ .Values.dremio.tls.keystoreFilename }} + path: dremio.jks + {{- end }} + {{- end }} + {{- if and .Values.coordinator.persistence.enabled .Values.coordinator.persistence.existingClaim }} + - name: data + persistentVolumeClaim: + claimName: {{ .Values.coordinator.persistence.existingClaim }} + {{- else if (not .Values.coordinator.persistence.enabled)}} + - name: data + emptyDir: {} + {{- end }} + {{- if .Values.coordinator.extraVolumes }} + {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.extraVolumes "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.coordinator.persistence.enabled }} + volumeClaimTemplates: + - metadata: + name: data + {{- if or .Values.coordinator.persistence.annotations .Values.commonAnnotations }} + {{- $claimAnnotations := include "common.tplvalues.merge" (dict "values" .Values.coordinator.persistence.annotations .Values.commonAnnotations "context" .) | fromYaml }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $claimAnnotations "context" $ ) | nindent 10 }} + {{- end }} + {{- if .Values.commonLabels }} + labels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 10 }} + {{- end }} + spec: + accessModes: + {{- range .Values.coordinator.persistence.accessModes }} + - {{ . | quote }} + {{- end }} + {{- if .Values.coordinator.persistence.dataSource }} + dataSource: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.persistence.dataSource "context" $) | nindent 10 }} + {{- end }} + resources: + requests: + storage: {{ .Values.coordinator.persistence.size | quote }} + {{- if .Values.coordinator.persistence.selector }} + selector: {{- include "common.tplvalues.render" (dict "value" .Values.coordinator.persistence.selector "context" $) | nindent 10 }} + {{- end }} + {{- include "common.storage.class" (dict "persistence" .Values.coordinator.persistence "global" .Values.global) | nindent 8 }} + {{- end }} diff --git a/bitnami/dremio/templates/coordinator/vpa.yaml b/bitnami/dremio/templates/coordinator/vpa.yaml new file mode 100644 index 0000000000..e094701689 --- /dev/null +++ b/bitnami/dremio/templates/coordinator/vpa.yaml @@ -0,0 +1,47 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and (.Capabilities.APIVersions.Has "autoscaling.k8s.io/v1/VerticalPodAutoscaler") .Values.coordinator.autoscaling.vpa.enabled }} +apiVersion: {{ include "common.capabilities.vpa.apiVersion" (dict "context" $) }} +kind: VerticalPodAutoscaler +metadata: + name: {{ include "dremio.coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.coordinator.autoscaling.vpa.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.coordinator.autoscaling.vpa.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + resourcePolicy: + containerPolicies: + - containerName: dremio + {{- with .Values.coordinator.autoscaling.vpa.controlledResources }} + controlledResources: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.coordinator.autoscaling.vpa.maxAllowed }} + maxAllowed: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.coordinator.autoscaling.vpa.minAllowed }} + minAllowed: + {{- toYaml . | nindent 8 }} + {{- end }} + targetRef: + apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} + kind: StatefulSet + name: {{ include "dremio.coordinator.fullname" . }} + {{- if .Values.coordinator.autoscaling.vpa.updatePolicy }} + updatePolicy: + {{- with .Values.coordinator.autoscaling.vpa.updatePolicy.updateMode }} + updateMode: {{ . }} + {{- end }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/executor/configmap-dremio-conf.yaml b/bitnami/dremio/templates/executor/configmap-dremio-conf.yaml new file mode 100644 index 0000000000..8a73cd45c2 --- /dev/null +++ b/bitnami/dremio/templates/executor/configmap-dremio-conf.yaml @@ -0,0 +1,64 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{/* Adding the helper in here for better readability */}} +{{- define "dremio.dremio-conf.executor.default" -}} +{{/* Common configuration */}} +{{- include "dremio.dremio-conf.common.default" . }} +{{/* Master coordinator settings */}} +services.coordinator.enabled: false +services.coordinator.master.enabled: false +services.coordinator.master.embedded-zookeeper.enabled: false +services.executor.enabled: true +{{- end }} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} +{{- if not $executorValues.dremioConf.existingConfigmap }} +--- +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ printf "%s-dremio-conf" (include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name)) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + {{- $extraFiles := mustMergeOverwrite $.Values.dremio.dremioConf.extraFiles $executorValues.dremioConf.extraFiles }} + {{- if not (hasKey $extraFiles "dremio.conf") }} + {{- /* dremio.conf uses HOCON, in which flattened YAML is a subset. So converting all values to flattened YAML generates a valid HOCON configuration */}} + {{- $defaultConfiguration := include "dremio.dremio-conf.executor.default" $ | fromYaml -}} + {{- /* Obtain first the flattened version of all YAML content so the merge works as expected */}} + {{- $defaultConfigurationFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $defaultConfiguration "prefix" "" "context" $) | fromYaml -}} + {{- $commonConfigOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $.Values.dremio.dremioConf.configOverrides "prefix" "" "context" $) | fromYaml -}} + {{- $configOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $executorValues.dremioConf.configOverrides "prefix" "" "context" $) | fromYaml -}} + {{- /* Override order: default configuration <- common overrides <- specific overrides */}} + {{- $mergedConfiguration := mustMergeOverwrite $defaultConfigurationFlat $commonConfigOverridesFlat }} + {{- $mergedConfiguration = mustMergeOverwrite $mergedConfiguration $configOverridesFlat }} + {{- /* Adding this engine specific configuration as we cannot put a "define" inside a "range" */}} + {{- $mergedConfiguration = mustMergeOverwrite $mergedConfiguration (dict "services.node-tag" $engine.name) }} + dremio.conf: | + {{- /* Apply the helper again to avoid arrays having a HOCON incompatible format */}} + {{- include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) | nindent 4 }} + {{- end }} + {{- if $extraFiles }} + {{- include "common.tplvalues.render" (dict "value" $extraFiles "context" $) | nindent 2 }} + {{- end }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/executor/hpa.yaml b/bitnami/dremio/templates/executor/hpa.yaml new file mode 100644 index 0000000000..192152c6d2 --- /dev/null +++ b/bitnami/dremio/templates/executor/hpa.yaml @@ -0,0 +1,64 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} +{{- if $executorValues.autoscaling.hpa.enabled }} +--- +apiVersion: {{ include "common.capabilities.hpa.apiVersion" (dict "context" $) }} +kind: HorizontalPodAutoscaler +metadata: + name: {{ include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name) }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + scaleTargetRef: + apiVersion: {{ include "common.capabilities.statefulset.apiVersion" $ }} + kind: StatefulSet + name: {{ include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name) }} + minReplicas: {{ $executorValues.autoscaling.hpa.minReplicas }} + maxReplicas: {{ $executorValues.autoscaling.hpa.maxReplicas }} + metrics: + {{- if $executorValues.autoscaling.hpa.targetMemory }} + - type: Resource + resource: + name: memory + {{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" $) }} + targetAverageUtilization: {{ $executorValues.autoscaling.hpa.targetMemory }} + {{- else }} + target: + type: Utilization + averageUtilization: {{ $executorValues.autoscaling.hpa.targetMemory }} + {{- end }} + {{- end }} + {{- if $executorValues.autoscaling.hpa.targetCPU }} + - type: Resource + resource: + name: cpu + {{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" $) }} + targetAverageUtilization: {{ $executorValues.autoscaling.hpa.targetCPU }} + {{- else }} + target: + type: Utilization + averageUtilization: {{ $executorValues.autoscaling.hpa.targetCPU }} + {{- end }} + {{- end }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/executor/networkpolicy.yaml b/bitnami/dremio/templates/executor/networkpolicy.yaml new file mode 100644 index 0000000000..e1359a8716 --- /dev/null +++ b/bitnami/dremio/templates/executor/networkpolicy.yaml @@ -0,0 +1,131 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} +{{- if $executorValues.networkPolicy.enabled }} +--- +kind: NetworkPolicy +apiVersion: {{ include "common.capabilities.networkPolicy.apiVersion" $ }} +metadata: + name: {{ include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name) }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list $executorValues.podLabels $.Values.commonLabels ) "context" $ ) }} + podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + engine: {{ $engine.name }} + policyTypes: + - Ingress + - Egress + {{- if $executorValues.networkPolicy.allowExternalEgress }} + egress: + - {} + {{- else }} + egress: + # Allow dns resolution + - ports: + - port: 53 + protocol: UDP + - port: 53 + protocol: TCP + # Allow outbound connections to other cluster pods + - ports: + - port: {{ $.Values.dremio.containerPorts.web }} + - port: {{ $.Values.dremio.containerPorts.client }} + - port: {{ $.Values.dremio.containerPorts.flight }} + - port: {{ $.Values.dremio.containerPorts.fabric }} + - port: {{ $.Values.dremio.containerPorts.conduit }} + to: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 14 }} + part-of: dremio + # Allow outbound connections to S3 + - ports: + - port: {{ include "dremio.s3.port" $ }} + {{- if $.Values.minio.enabled }} + - port: {{ $.Values.minio.containerPorts.api }} + to: + - podSelector: + matchLabels: + app.kubernetes.io/name: minio + app.kubernetes.io/instance: {{ .Release.Name }} + {{- end }} + # Allow outbound connections to zookeeper + - ports: + - port: {{ include "dremio.zookeeper.port" $ }} + to: + {{- if $.Values.zookeeper.enabled }} + - podSelector: + matchLabels: + app.kubernetes.io/name: zookeeper + app.kubernetes.io/instance: {{ .Release.Name }} + {{- end }} + {{- if $executorValues.networkPolicy.extraEgress }} + {{- include "common.tplvalues.render" ( dict "value" $executorValues.networkPolicy.extraEgress "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} + ingress: + - ports: + - port: {{ $.Values.dremio.containerPorts.conduit }} + - port: {{ $.Values.dremio.containerPorts.fabric }} + {{- if $.Values.metrics.enabled }} + - port: {{ $.Values.dremio.containerPorts.jmx }} + {{- end }} + {{- range $executorValues.extraContainerPorts }} + - port: {{ . }} + {{- end }} + {{- if not $executorValues.networkPolicy.allowExternal }} + from: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 14 }} + app.kubernetes.io/part-of: dremio + {{- if $executorValues.networkPolicy.addExternalClientAccess }} + - podSelector: + matchLabels: + {{ template "dremio.executor.fullname" $ }}-client: "true" + {{- end }} + {{- if $executorValues.networkPolicy.ingressPodMatchLabels }} + - podSelector: + matchLabels: {{- include "common.tplvalues.render" (dict "value" $executorValues.networkPolicy.ingressPodMatchLabels "context" $ ) | nindent 14 }} + {{- end }} + {{- if $executorValues.networkPolicy.ingressNSMatchLabels }} + - namespaceSelector: + matchLabels: + {{- range $key, $value := $executorValues.networkPolicy.ingressNSMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- if $executorValues.networkPolicy.ingressNSPodMatchLabels }} + podSelector: + matchLabels: + {{- range $key, $value := $executorValues.networkPolicy.ingressNSPodMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- end }} + {{- end }} + {{- end }} + {{- if $executorValues.networkPolicy.extraIngress }} + {{- include "common.tplvalues.render" ( dict "value" $executorValues.networkPolicy.extraIngress "context" $ ) | nindent 4 }} + {{- end }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/executor/pdb.yaml b/bitnami/dremio/templates/executor/pdb.yaml new file mode 100644 index 0000000000..cfb4077db3 --- /dev/null +++ b/bitnami/dremio/templates/executor/pdb.yaml @@ -0,0 +1,45 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} +{{- if $executorValues.pdb.create }} +--- +apiVersion: {{ include "common.capabilities.policy.apiVersion" $ }} +kind: PodDisruptionBudget +metadata: + name: {{ include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name) }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if $executorValues.pdb.minAvailable }} + minAvailable: {{ $executorValues.pdb.minAvailable }} + {{- end }} + {{- if or $executorValues.pdb.maxUnavailable ( not $executorValues.pdb.minAvailable ) }} + maxUnavailable: {{ $executorValues.pdb.maxUnavailable | default 1 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list $executorValues.podLabels $.Values.commonLabels ) "context" . ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + engine: {{ $engine.name }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/executor/secret-dremio-conf.yaml b/bitnami/dremio/templates/executor/secret-dremio-conf.yaml new file mode 100644 index 0000000000..ac8732c7e4 --- /dev/null +++ b/bitnami/dremio/templates/executor/secret-dremio-conf.yaml @@ -0,0 +1,54 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} +{{- $extraFiles := mustMergeOverwrite $.Values.dremio.dremioConf.extraSecretFiles $executorValues.dremioConf.extraSecretFiles }} +{{- $createDremioConf := or $.Values.dremio.dremioConf.secretConfigOverrides $executorValues.dremioConf.secretConfigOverrides $.Values.dremio.tls.enabled }} +{{- if and (not $executorValues.dremioConf.existingSecret) (or $createDremioConf $extraFiles) }} +--- +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-dremio-conf" (include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name)) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +{{- /* We use stringData to simplify the templating of this file. It is as insecure as using base64 */}} +stringData: + {{- if and (not (hasKey $extraFiles "dremio.conf")) $createDremioConf }} + {{- /* dremio.conf uses HOCON, in which flattened YAML is a subset. So converting all values to flattened YAML generates a valid HOCON configuration */}} + {{- $defaultConfiguration := include "dremio.dremio-conf.common.defaultSecret" $ | fromYaml -}} + {{- /* Obtain first the flattened version of all YAML content so the merge works as expected */}} + {{- $defaultConfigurationFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $defaultConfiguration "prefix" "" "context" $) | fromYaml -}} + {{- $commonConfigOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $.Values.dremio.dremioConf.secretConfigOverrides "prefix" "" "context" $) | fromYaml -}} + {{- $configOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $executorValues.dremioConf.secretConfigOverrides "prefix" "" "context" $) | fromYaml -}} + {{- /* Override order: default configuration <- common overrides <- specific overrides */}} + {{- $mergedConfiguration := mustMergeOverwrite $defaultConfigurationFlat $commonConfigOverridesFlat }} + {{- $mergedConfiguration = mustMergeOverwrite $mergedConfiguration $configOverridesFlat }} + {{- $result := include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) }} + {{- /* Apply the helper again to avoid arrays having a HOCON incompatible format */}} + dremio.conf: | + {{- include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) | nindent 4 }} + {{- end }} + {{- if $extraFiles }} + {{- include "common.tplvalues.render" (dict "value" $extraFiles "context" $) | nindent 2 }} + {{- end }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/executor/service-account.yaml b/bitnami/dremio/templates/executor/service-account.yaml new file mode 100644 index 0000000000..310bf87d0a --- /dev/null +++ b/bitnami/dremio/templates/executor/service-account.yaml @@ -0,0 +1,34 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} +{{- if $executorValues.serviceAccount.create }} +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "dremio.executor.serviceAccountName" (dict "engine" $engine.name "executorValues" $executorValues "context" $) }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if or $executorValues.serviceAccount.annotations $.Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list $executorValues.serviceAccount.annotations $.Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +automountServiceAccountToken: {{ $executorValues.serviceAccount.automountServiceAccountToken }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/executor/statefulset.yaml b/bitnami/dremio/templates/executor/statefulset.yaml new file mode 100644 index 0000000000..75de2ec2a2 --- /dev/null +++ b/bitnami/dremio/templates/executor/statefulset.yaml @@ -0,0 +1,396 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} +--- +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" $ }} +kind: StatefulSet +metadata: + name: {{ include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name) }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if or $executorValues.statefulsetAnnotations $.Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list $executorValues.statefulsetAnnotations $.Values.commonAnnotations) "context" $) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if not $executorValues.autoscaling.hpa.enabled }} + replicas: {{ $executorValues.replicaCount }} + {{- end }} + podManagementPolicy: {{ $executorValues.podManagementPolicy | quote }} + {{- $podLabels := include "common.tplvalues.merge" (dict "values" (list $executorValues.podLabels $.Values.commonLabels) "context" $) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + engine: {{ $engine.name }} + serviceName: {{ printf "%s-headless" (include "common.names.fullname" $) | trunc 63 | trimSuffix "-" }} + {{- if $executorValues.updateStrategy }} + updateStrategy: {{- toYaml $executorValues.updateStrategy | nindent 4 }} + {{- end }} + template: + metadata: + annotations: + checksum/dremio-conf-cm: {{ include (print $.Template.BasePath "/executor/configmap-dremio-conf.yaml") $ | sha256sum }} + checksum/dremio-conf-secret: {{ include (print $.Template.BasePath "/executor/secret-dremio-conf.yaml") $ | sha256sum }} + checksum/core-site-secret: {{ include (print $.Template.BasePath "/secret-core-site.yaml") $ | sha256sum }} + {{- if $executorValues.podAnnotations }} + {{- include "common.tplvalues.render" (dict "value" $executorValues.podAnnotations "context" $) | nindent 8 }} + {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" $podLabels "context" $) | nindent 8 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + engine: {{ $engine.name }} + spec: + {{- include "dremio.imagePullSecrets" $ | nindent 6 }} + serviceAccountName: {{ include "dremio.executor.serviceAccountName" (dict "engine" $engine.name "executorValues" $executorValues "context" $) }} + automountServiceAccountToken: {{ $executorValues.automountServiceAccountToken }} + {{- if $executorValues.hostAliases }} + hostAliases: {{- include "common.tplvalues.render" (dict "value" $executorValues.hostAliases "context" $) | nindent 8 }} + {{- end }} + {{- if $executorValues.affinity }} + affinity: {{- include "common.tplvalues.render" ( dict "value" $executorValues.affinity "context" $) | nindent 8 }} + {{- else }} + affinity: + podAffinity: {{- include "common.affinities.pods" (dict "type" $executorValues.podAffinityPreset "component" (printf "executor-%s" $engine.name) "customLabels" $podLabels "context" $) | nindent 10 }} + podAntiAffinity: {{- include "common.affinities.pods" (dict "type" $executorValues.podAntiAffinityPreset "component" (printf "executor-%s" $engine.name) "customLabels" $podLabels "context" $) | nindent 10 }} + nodeAffinity: {{- include "common.affinities.nodes" (dict "type" $executorValues.nodeAffinityPreset.type "key" $executorValues.nodeAffinityPreset.key "values" $executorValues.nodeAffinityPreset.values) | nindent 10 }} + {{- end }} + {{- if $executorValues.nodeSelector }} + nodeSelector: {{- include "common.tplvalues.render" ( dict "value" $executorValues.nodeSelector "context" $) | nindent 8 }} + {{- end }} + {{- if $executorValues.tolerations }} + tolerations: {{- include "common.tplvalues.render" (dict "value" $executorValues.tolerations "context" $) | nindent 8 }} + {{- end }} + {{- if $executorValues.priorityClassName }} + priorityClassName: {{ $executorValues.priorityClassName | quote }} + {{- end }} + {{- if $executorValues.schedulerName }} + schedulerName: {{ $executorValues.schedulerName | quote }} + {{- end }} + {{- if $executorValues.topologySpreadConstraints }} + topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" $executorValues.topologySpreadConstraints "context" $) | nindent 8 }} + {{- end }} + {{- if $executorValues.podSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $executorValues.podSecurityContext "context" $) | nindent 8 }} + {{- end }} + {{- if $executorValues.terminationGracePeriodSeconds }} + terminationGracePeriodSeconds: {{ $executorValues.terminationGracePeriodSeconds }} + {{- end }} + initContainers: + {{- /* As most Bitnami charts have volumePermissions in the root, we add a volumePermissions.enabled check to maintain a similar UX */}} + {{- if and (or $.Values.defaultInitContainers.volumePermissions.enabled (($.Values.volumePermissions).enabled)) $executorValues.persistence.enabled }} + {{- include "dremio.init-containers.volume-permissions" (dict "context" $ "componentValues" $executorValues) | nindent 8}} + {{- end }} + {{- if $.Values.defaultInitContainers.copyDefaultConf.enabled }} + {{- include "dremio.init-containers.copy-default-conf" $ | nindent 8 }} + {{- end }} + {{- if $.Values.defaultInitContainers.wait.enabled }} + {{- include "dremio.init-containers.wait-for-s3" $ | nindent 8 }} + {{- include "dremio.init-containers.wait-for-zookeeper" $ | nindent 8 }} + {{- include "dremio.init-containers.wait-for-master-coordinator" $ | nindent 8 }} + {{- end }} + {{- if $.Values.defaultInitContainers.generateConf.enabled }} + {{- include "dremio.init-containers.generate-conf" (dict "context" $ "mountDremioConfSecret" (include "dremio.executor.dremio-conf.useSecret" (dict "context" $ "executorValues" $executorValues))) | nindent 8 }} + {{- end }} + {{- if and $.Values.dremio.tls.enabled $.Values.defaultInitContainers.initCerts.enabled }} + {{- include "dremio.init-containers.init-certs" $ | nindent 8 }} + {{- end }} + {{- if $executorValues.initContainers }} + {{- include "common.tplvalues.render" (dict "value" $executorValues.initContainers "context" $) | nindent 8 }} + {{- end }} + containers: + - name: dremio + image: {{ template "dremio.image" $ }} + imagePullPolicy: {{ $.Values.dremio.image.pullPolicy }} + {{- if $executorValues.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $executorValues.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.diagnosticMode.enabled }} + command: {{- include "common.tplvalues.render" (dict "value" $.Values.diagnosticMode.command "context" $) | nindent 12 }} + {{- else if $executorValues.command }} + command: {{- include "common.tplvalues.render" (dict "value" $executorValues.command "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.diagnosticMode.enabled }} + args: {{- include "common.tplvalues.render" (dict "value" $.Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else if $executorValues.args }} + args: {{- include "common.tplvalues.render" (dict "value" $executorValues.args "context" $) | nindent 12 }} + {{- end }} + env: + - name: BITNAMI_DEBUG + value: {{ ternary "true" "false" (or $.Values.dremio.image.debug $.Values.diagnosticMode.enabled) | quote }} + - name: DREMIO_JAVA_SERVER_EXTRA_OPTS + value: | + {{- if and (eq $.Values.dremio.distStorageType "minio") (or (and $.Values.minio.enabled ((($.Values.minio).tls).enabled) ((($.Values.minio).tls).autoGenerated)) $.Values.externalS3.disableCertChecking) }} + -Dcom.amazonaws.sdk.disableCertChecking=true + {{- end }} + {{- if $.Values.metrics.enabled }} + -Dcom.sun.management.jmxremote.port={{ $.Values.dremio.containerPorts.jmx }} + -Dcom.sun.management.jmxremote.authenticate=false + -Dcom.sun.management.jmxremote.ssl=false + {{- end }} + {{- if $executorValues.extraJavaOpts }} + {{- include "common.tplvalues.render" (dict "value" $executorValues.extraJavaOpts "context" $) | nindent 16 }} + {{- end }} + - name: DREMIO_MAX_MEMORY_SIZE_MB + valueFrom: + resourceFieldRef: + containerName: dremio + resource: limits.memory + divisor: 1Mi + {{- if $executorValues.extraEnvVars }} + {{- include "common.tplvalues.render" (dict "value" $executorValues.extraEnvVars "context" $) | nindent 12 }} + {{- end }} + envFrom: + {{- if $executorValues.extraEnvVarsCM }} + - configMapRef: + name: {{ include "common.tplvalues.render" (dict "value" $executorValues.extraEnvVarsCM "context" $) }} + {{- end }} + {{- if $executorValues.extraEnvVarsSecret }} + - secretRef: + name: {{ include "common.tplvalues.render" (dict "value" $executorValues.extraEnvVarsSecret "context" $) }} + {{- end }} + {{- if $executorValues.resources }} + resources: {{- toYaml $executorValues.resources | nindent 12 }} + {{- else if ne $executorValues.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" $executorValues.resourcesPreset) | nindent 12 }} + {{- end }} + ports: + - containerPort: {{ $.Values.dremio.containerPorts.liveness }} + name: liveness + - containerPort: {{ $.Values.dremio.containerPorts.fabric }} + name: server-fabric + - containerPort: {{ $.Values.dremio.containerPorts.conduit }} + name: server-conduit + {{- if $.Values.metrics.enabled }} + - containerPort: {{ $.Values.dremio.containerPorts.jmx }} + name: jmx + {{- end }} + {{- if $executorValues.extraContainerPorts }} + {{- include "common.tplvalues.render" (dict "value" $executorValues.extraContainerPorts "context" $) | nindent 12 }} + {{- end }} + {{- if not $.Values.diagnosticMode.enabled }} + {{- if $executorValues.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" $executorValues.customLivenessProbe "context" $) | nindent 12 }} + {{- else if $executorValues.livenessProbe.enabled }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit $executorValues.livenessProbe "enabled") "context" $) | nindent 12 }} + {{- /* Using the fabric port because of a strange issue in which the liveness port is working but not the fabric one, in which case we want to restart the executor */}} + tcpSocket: + port: server-fabric + {{- end }} + {{- if $executorValues.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" $executorValues.customReadinessProbe "context" $) | nindent 12 }} + {{- else if $executorValues.readinessProbe.enabled }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit $executorValues.readinessProbe "enabled") "context" $) | nindent 12 }} + tcpSocket: + port: liveness + {{- end }} + {{- if $executorValues.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" $executorValues.customStartupProbe "context" $) | nindent 12 }} + {{- else if $executorValues.startupProbe.enabled }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit $executorValues.startupProbe "enabled") "context" $) | nindent 12 }} + tcpSocket: + port: liveness + {{- end }} + {{- end }} + {{- if $executorValues.lifecycleHooks }} + lifecycle: {{- include "common.tplvalues.render" (dict "value" $executorValues.lifecycleHooks "context" $) | nindent 12 }} + {{- end }} + volumeMounts: + - name: data + mountPath: {{ $executorValues.persistence.mountPath }} + {{- if $executorValues.persistence.subPath }} + subPath: {{ $executorValues.persistence.subPath }} + {{- end }} + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/tmp + subPath: app-tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/run + subPath: app-run-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/log + subPath: app-log-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/conf + subPath: app-conf-dir + {{- if $.Values.metrics.enabled }} + - name: metrics-configuration + mountPath: /opt/bitnami/dremio/conf/dremio-telemetry.yaml + subPath: dremio-telemetry.yaml + {{- end }} + {{- if $.Values.dremio.tls.enabled }} + - name: empty-dir + mountPath: /opt/bitnami/dremio/certs + subPath: app-processed-certs-dir + {{- end }} + {{- if $executorValues.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" $executorValues.extraVolumeMounts "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.metrics.enabled }} + - name: metrics + image: {{ include "dremio.metrics.image" $ }} + imagePullPolicy: {{ $.Values.metrics.image.pullPolicy | quote }} + {{- if $.Values.metrics.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" $.Values.metrics.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if $.Values.diagnosticMode.enabled }} + command: {{- include "common.tplvalues.render" (dict "value" $.Values.diagnosticMode.command "context" $) | nindent 12 }} + args: {{- include "common.tplvalues.render" (dict "value" $.Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else }} + command: + - java + args: + - -XX:MaxRAMPercentage=100 + - -XshowSettings:vm + - -jar + - jmx_prometheus_httpserver.jar + - {{ $.Values.metrics.containerPorts.metrics | quote }} + - /etc/jmx-dremio/jmx-prometheus.yml + {{- end }} + ports: + - name: metrics + containerPort: {{ $.Values.metrics.containerPorts.metrics }} + {{- if $.Values.metrics.resources }} + resources: {{- toYaml $.Values.metrics.resources | nindent 12 }} + {{- else if ne $.Values.metrics.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" $.Values.metrics.resourcesPreset) | nindent 12 }} + {{- end }} + {{- if not $.Values.diagnosticMode.enabled }} + {{- if $.Values.metrics.livenessProbe.enabled }} + livenessProbe: {{- omit $.Values.metrics.livenessProbe "enabled" | toYaml | nindent 12 }} + tcpSocket: + port: metrics + {{- end }} + {{- if $.Values.metrics.readinessProbe.enabled }} + readinessProbe: {{- omit $.Values.metrics.readinessProbe "enabled" | toYaml | nindent 12 }} + httpGet: + path: / + port: metrics + {{- end }} + {{- if $.Values.metrics.startupProbe.enabled }} + startupProbe: {{- omit $.Values.metrics.startupProbe "enabled" | toYaml | nindent 12 }} + httpGet: + path: / + port: metrics + {{- end }} + {{- end }} + volumeMounts: + - name: metrics-configuration + mountPath: /etc/jmx-dremio/jmx-prometheus.yml + subPath: jmx-prometheus.yml + {{- end }} + {{- if $executorValues.sidecars }} + {{- include "common.tplvalues.render" ( dict "value" $executorValues.sidecars "context" $) | nindent 8 }} + {{- end }} + volumes: + - name: empty-dir + emptyDir: {} + - name: input-dremio-conf-cm + configMap: + name: {{ include "dremio.executor.dremio-conf.configmapName" (dict "context" $ "executorValues" $executorValues "engine" $engine.name) }} + {{- if (include "dremio.executor.dremio-conf.useSecret" (dict "context" $ "executorValues" $executorValues "engine" $engine.name)) }} + - name: input-dremio-conf-secret + secret: + secretName: {{ include "dremio.executor.dremio-conf.secretName" (dict "context" $ "executorValues" $executorValues "engine" $engine.name) }} + {{- end }} + - name: input-core-site + secret: + secretName: {{ include "dremio.core-site.secretName" $ }} + {{- if $.Values.metrics.enabled }} + - name: metrics-configuration + configMap: + name: {{ include "dremio.metrics.configmapName" $ }} + {{- end }} + {{- if $.Values.dremio.tls.enabled }} + - name: input-tls-certs + secret: + secretName: {{ include "dremio.tls.secretName" $ }} + items: + {{- if $.Values.dremio.tls.usePemCerts }} + - key: {{ $.Values.dremio.tls.certFilename }} + path: tls.crt + - key: {{ $.Values.dremio.tls.certKeyFilename }} + path: tls.key + {{- else }} + - key: {{ $.Values.dremio.tls.keystoreFilename }} + path: dremio.jks + {{- end }} + {{- end }} + {{- if and $executorValues.persistence.enabled $executorValues.persistence.existingClaim }} + - name: data + persistentVolumeClaim: + claimName: {{ $executorValues.persistence.existingClaim }} + {{- else if (not $executorValues.persistence.enabled)}} + - name: data + emptyDir: {} + {{- end }} + {{- if $.Values.usePasswordFile }} + {{- if or $.Values.dremio.tls.passwordSecret $.Values.dremio.tls.password $.Values.dremio.tls.autoGenerated.enabled $.Values.dremio.tls.usePemCerts }} + - name: keystore-password + secret: + secretName: {{ include "dremio.tls.passwordSecretName" $ }} + items: + - key: keystore-password + path: DREMIO_KEYSTORE_PASSWORD + {{- end }} + {{- if or (eq $.Values.dremio.distStorageType "minio") (eq $.Values.dremio.distStorageType "aws") }} + - name: s3-credentials + secret: + secretName: {{ include "dremio.s3.secretName" $ }} + items: + - key: {{ include "dremio.s3.accessKeyIDKey" $ }} + path: DREMIO_AWS_ACCESS_KEY_ID + - key: {{ include "dremio.s3.secretAccessKeyKey" $ }} + path: DREMIO_AWS_SECRET_ACCESS_KEY + {{- end }} + {{- end }} + {{- if $executorValues.extraVolumes }} + {{- include "common.tplvalues.render" (dict "value" $executorValues.extraVolumes "context" $) | nindent 8 }} + {{- end }} + {{- if $executorValues.persistence.enabled }} + volumeClaimTemplates: + - metadata: + name: data + {{- if or $executorValues.persistence.annotations $.Values.commonAnnotations }} + {{- $claimAnnotations := include "common.tplvalues.merge" (dict "values" $executorValues.persistence.annotations $.Values.commonAnnotations "context" $) | fromYaml }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $claimAnnotations "context" $ ) | nindent 10 }} + {{- end }} + {{- if $.Values.commonLabels }} + labels: {{- include "common.labels.matchLabels" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 10 }} + {{- end }} + spec: + accessModes: + {{- range $executorValues.persistence.accessModes }} + - {{ . | quote }} + {{- end }} + {{- if $executorValues.persistence.dataSource }} + dataSource: {{- include "common.tplvalues.render" (dict "value" $executorValues.persistence.dataSource "context" $) | nindent 10 }} + {{- end }} + resources: + requests: + storage: {{ $executorValues.persistence.size | quote }} + {{- if $executorValues.persistence.selector }} + selector: {{- include "common.tplvalues.render" (dict "value" $executorValues.persistence.selector "context" $) | nindent 10 }} + {{- end }} + {{- include "common.storage.class" (dict "persistence" $executorValues.persistence "global" $.Values.global) | nindent 8 }} + {{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/executor/vpa.yaml b/bitnami/dremio/templates/executor/vpa.yaml new file mode 100644 index 0000000000..aa27eca330 --- /dev/null +++ b/bitnami/dremio/templates/executor/vpa.yaml @@ -0,0 +1,60 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- /* + Dremio supports different executor groups called "engines". + These are defined in executor.engines and all the executor-specific k8s objects are created per engine. + Each engine contains an "overrides" section which allows replacing the common executor configuration + set in executor.common. This logic is inspired in upstream Dremio chart. + + https://docs.dremio.com/cloud/sonar/workloads/engines/ + */}} +{{- range $engine := .Values.executor.engines }} +{{- $executorValues := mustMergeOverwrite $.Values.executor.common $engine.overrides }} + +{{- if and ($.Capabilities.APIVersions.Has "autoscaling.k8s.io/v1/VerticalPodAutoscaler") $executorValues.autoscaling.vpa.enabled }} +--- +apiVersion: {{ include "common.capabilities.vpa.apiVersion" (dict "context" $) }} +kind: VerticalPodAutoscaler +metadata: + name: {{ include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name) }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: executor + {{- /* We need an extra label for the engine */}} + engine: {{ $engine.name }} + {{- if or $executorValues.autoscaling.vpa.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list $executorValues.autoscaling.vpa.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + resourcePolicy: + containerPolicies: + - containerName: dremio + {{- with $executorValues.autoscaling.vpa.controlledResources }} + controlledResources: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $executorValues.autoscaling.vpa.maxAllowed }} + maxAllowed: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with $executorValues.autoscaling.vpa.minAllowed }} + minAllowed: + {{- toYaml . | nindent 8 }} + {{- end }} + targetRef: + apiVersion: {{ include "common.capabilities.statefulset.apiVersion" $ }} + kind: StatefulSet + name: {{ include "dremio.executor.fullname" (dict "context" $ "engine" $engine.name) }} + {{- if $executorValues.autoscaling.vpa.updatePolicy }} + updatePolicy: + {{- with $executorValues.autoscaling.vpa.updatePolicy.updateMode }} + updateMode: {{ . }} + {{- end }} + {{- end }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/externals3-secret.yaml b/bitnami/dremio/templates/externals3-secret.yaml new file mode 100644 index 0000000000..9fb2f5cc03 --- /dev/null +++ b/bitnami/dremio/templates/externals3-secret.yaml @@ -0,0 +1,21 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and (not .Values.minio.enabled) (not .Values.externalS3.existingSecret) .Values.enableS3 }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-externals3" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" (dict "value" .Values.commonAnnotations "context" $) | nindent 4 }} + {{- end }} +type: Opaque +data: + {{ .Values.externalS3.existingSecretAccessKeyIDKey }}: {{ .Values.externalS3.accessKeyID | b64enc | quote }} + {{ .Values.externalS3.existingSecretKeySecretKey }}: {{ .Values.externalS3.accessKeySecret | b64enc | quote }} +{{- end }} diff --git a/bitnami/dremio/templates/extra-list.yaml b/bitnami/dremio/templates/extra-list.yaml new file mode 100644 index 0000000000..329f5c653a --- /dev/null +++ b/bitnami/dremio/templates/extra-list.yaml @@ -0,0 +1,9 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- range .Values.extraDeploy }} +--- +{{ include "common.tplvalues.render" (dict "value" . "context" $) }} +{{- end }} diff --git a/bitnami/dremio/templates/headless-service.yaml b/bitnami/dremio/templates/headless-service.yaml new file mode 100644 index 0000000000..0b92b2becf --- /dev/null +++ b/bitnami/dremio/templates/headless-service.yaml @@ -0,0 +1,51 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +apiVersion: v1 +kind: Service +metadata: + name: {{ printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- if or .Values.commonAnnotations .Values.service.headless.annotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.service.headless.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + type: ClusterIP + publishNotReadyAddresses: true + clusterIP: None + ports: + - name: http-web + port: {{ .Values.dremio.containerPorts.web }} + targetPort: web + protocol: TCP + - name: tcp-client + port: {{ .Values.dremio.containerPorts.client }} + targetPort: client + protocol: TCP + - name: tcp-flight + port: {{ .Values.dremio.containerPorts.flight }} + targetPort: flight + protocol: TCP + - name: tcp-fabric + port: {{ .Values.dremio.containerPorts.fabric }} + targetPort: fabric + protocol: TCP + - name: tcp-conduit + port: {{ .Values.dremio.containerPorts.conduit }} + targetPort: conduit + protocol: TCP + - name: tcp-liveness + port: {{ .Values.dremio.containerPorts.liveness }} + targetPort: conduit + protocol: TCP + - name: tcp-jmx + port: {{ .Values.dremio.containerPorts.jmx }} + targetPort: jmx + protocol: TCP + selector: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio \ No newline at end of file diff --git a/bitnami/dremio/templates/ingress-tls-secret.yaml b/bitnami/dremio/templates/ingress-tls-secret.yaml new file mode 100644 index 0000000000..29e6717261 --- /dev/null +++ b/bitnami/dremio/templates/ingress-tls-secret.yaml @@ -0,0 +1,50 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.ingress.enabled }} +{{- if .Values.ingress.secrets }} +{{- range .Values.ingress.secrets }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ .name }} + namespace: {{ include "common.names.namespace" $ | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $.Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ .certificate | b64enc }} + tls.key: {{ .key | b64enc }} +--- +{{- end }} +{{- else if and .Values.ingress.tls .Values.ingress.selfSigned }} +{{- $secretName := printf "%s-tls" .Values.ingress.hostname }} +{{- $ca := genCA "dremio-ca" 365 }} +{{- $cert := genSignedCert .Values.ingress.hostname nil (list .Values.ingress.hostname) 365 $ca }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ $secretName }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.crt" "defaultValue" $cert.Cert "context" $) }} + tls.key: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.key" "defaultValue" $cert.Key "context" $) }} + ca.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "ca.crt" "defaultValue" $ca.Cert "context" $) }} +--- +{{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/ingress.yaml b/bitnami/dremio/templates/ingress.yaml new file mode 100644 index 0000000000..db14ec624d --- /dev/null +++ b/bitnami/dremio/templates/ingress.yaml @@ -0,0 +1,62 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.ingress.enabled }} +apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} +kind: Ingress +metadata: + name: {{ include "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.ingress.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list .Values.ingress.annotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if and .Values.ingress.ingressClassName (eq "true" (include "common.ingress.supportsIngressClassname" .)) }} + ingressClassName: {{ .Values.ingress.ingressClassName | quote }} + {{- end }} + rules: + {{- if .Values.ingress.hostname }} + - host: {{ .Values.ingress.hostname }} + http: + paths: + {{- if .Values.ingress.extraPaths }} + {{- toYaml .Values.ingress.extraPaths | nindent 10 }} + {{- end }} + - path: {{ .Values.ingress.path }} + {{- if eq "true" (include "common.ingress.supportsPathType" .) }} + pathType: {{ .Values.ingress.pathType }} + {{- end }} + backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" .) "servicePort" "http" "context" $) | nindent 14 }} + {{- end }} + {{- range .Values.ingress.extraHosts }} + - host: {{ .name | quote }} + http: + paths: + - path: {{ default "/" .path }} + {{- if eq "true" (include "common.ingress.supportsPathType" $) }} + pathType: {{ default "ImplementationSpecific" .pathType }} + {{- end }} + backend: {{- include "common.ingress.backend" (dict "serviceName" (include "common.names.fullname" $) "servicePort" "http" "context" $) | nindent 14 }} + {{- end }} + {{- if .Values.ingress.extraRules }} + {{- include "common.tplvalues.render" (dict "value" .Values.ingress.extraRules "context" $) | nindent 4 }} + {{- end }} + {{- if or (and .Values.ingress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.ingress.annotations )) .Values.ingress.selfSigned)) .Values.ingress.extraTls }} + tls: + {{- if and .Values.ingress.tls (or (include "common.ingress.certManagerRequest" ( dict "annotations" .Values.ingress.annotations )) .Values.ingress.selfSigned) }} + - hosts: + - {{ .Values.ingress.hostname | quote }} + secretName: {{ printf "%s-tls" .Values.ingress.hostname }} + {{- end }} + {{- if .Values.ingress.extraTls }} + {{- include "common.tplvalues.render" (dict "value" .Values.ingress.extraTls "context" $) | nindent 4 }} + {{- end }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/master-coordinator/configmap-dremio-conf.yaml b/bitnami/dremio/templates/master-coordinator/configmap-dremio-conf.yaml new file mode 100644 index 0000000000..d783f9c873 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/configmap-dremio-conf.yaml @@ -0,0 +1,50 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{/* Adding the helper in here for better readability */}} +{{- define "dremio.dremio-conf.master-coordinator.default" -}} +{{/* Common configuration */}} +{{- include "dremio.dremio-conf.common.default" . }} +{{/* Master coordinator settings */}} +services.coordinator.enabled: true +services.coordinator.master.enabled: true +services.coordinator.master.embedded-zookeeper.enabled: false +services.executor.enabled: false +{{- end }} + +{{- if not .Values.masterCoordinator.dremioConf.existingConfigmap -}} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ printf "%s-dremio-conf" (include "dremio.master-coordinator.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + {{- $extraFiles := mustMergeOverwrite .Values.dremio.dremioConf.extraFiles .Values.masterCoordinator.dremioConf.extraFiles }} + {{- if not (hasKey $extraFiles "dremio.conf") }} + {{- /* dremio.conf uses HOCON, in which flattened YAML is a subset. So converting all values to flattened YAML generates a valid HOCON configuration */}} + {{- $defaultConfiguration := include "dremio.dremio-conf.master-coordinator.default" . | fromYaml -}} + {{- /* Obtain first the flattened version of all YAML content so the merge works as expected */}} + {{- $defaultConfigurationFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $defaultConfiguration "prefix" "" "context" $) | fromYaml -}} + {{- $commonConfigOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.dremio.dremioConf.configOverrides "prefix" "" "context" $) | fromYaml -}} + {{- $configOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.masterCoordinator.dremioConf.configOverrides "prefix" "" "context" $) | fromYaml -}} + {{- /* Override order: default configuration <- common overrides <- specific overrides */}} + {{- $mergedConfiguration := mustMergeOverwrite $defaultConfigurationFlat $commonConfigOverridesFlat }} + {{- $mergedConfiguration = mustMergeOverwrite $mergedConfiguration $configOverridesFlat }} + dremio.conf: | + {{- /* Apply the helper again to avoid arrays having a HOCON incompatible format */}} + {{- include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) | nindent 4 }} + {{- end }} + {{- if $extraFiles }} + {{- include "common.tplvalues.render" (dict "value" $extraFiles "context" $) | nindent 2 }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/master-coordinator/hpa.yaml b/bitnami/dremio/templates/master-coordinator/hpa.yaml new file mode 100644 index 0000000000..7b86fccf52 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/hpa.yaml @@ -0,0 +1,52 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.masterCoordinator.autoscaling.hpa.enabled }} +apiVersion: {{ include "common.capabilities.hpa.apiVersion" (dict "context" $) }} +kind: HorizontalPodAutoscaler +metadata: + name: {{ include "dremio.master-coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + scaleTargetRef: + apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} + kind: StatefulSet + name: {{ include "dremio.master-coordinator.fullname" . }} + minReplicas: {{ .Values.masterCoordinator.autoscaling.hpa.minReplicas }} + maxReplicas: {{ .Values.masterCoordinator.autoscaling.hpa.maxReplicas }} + metrics: + {{- if .Values.masterCoordinator.autoscaling.hpa.targetMemory }} + - type: Resource + resource: + name: memory + {{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" .) }} + targetAverageUtilization: {{ .Values.masterCoordinator.autoscaling.hpa.targetMemory }} + {{- else }} + target: + type: Utilization + averageUtilization: {{ .Values.masterCoordinator.autoscaling.hpa.targetMemory }} + {{- end }} + {{- end }} + {{- if .Values.masterCoordinator.autoscaling.hpa.targetCPU }} + - type: Resource + resource: + name: cpu + {{- if semverCompare "<1.23-0" (include "common.capabilities.kubeVersion" .) }} + targetAverageUtilization: {{ .Values.masterCoordinator.autoscaling.hpa.targetCPU }} + {{- else }} + target: + type: Utilization + averageUtilization: {{ .Values.masterCoordinator.autoscaling.hpa.targetCPU }} + {{- end }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/master-coordinator/networkpolicy.yaml b/bitnami/dremio/templates/master-coordinator/networkpolicy.yaml new file mode 100644 index 0000000000..e52afff7c0 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/networkpolicy.yaml @@ -0,0 +1,124 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.masterCoordinator.networkPolicy.enabled }} +kind: NetworkPolicy +apiVersion: {{ include "common.capabilities.networkPolicy.apiVersion" . }} +metadata: + name: {{ template "dremio.master-coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.masterCoordinator.podLabels .Values.commonLabels ) "context" . ) }} + podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + app: dremio-coordinator + policyTypes: + - Ingress + - Egress + {{- if .Values.masterCoordinator.networkPolicy.allowExternalEgress }} + egress: + - {} + {{- else }} + egress: + # Allow dns resolution + - ports: + - port: 53 + protocol: UDP + - port: 53 + protocol: TCP + # Allow outbound connections to other cluster pods + - ports: + - port: {{ .Values.dremio.containerPorts.web }} + - port: {{ .Values.dremio.containerPorts.client }} + - port: {{ .Values.dremio.containerPorts.flight }} + - port: {{ .Values.dremio.containerPorts.fabric }} + - port: {{ .Values.dremio.containerPorts.conduit }} + to: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 14 }} + part-of: dremio + # Allow outbound connections to S3 + - ports: + - port: {{ include "dremio.s3.port" . }} + {{- if .Values.minio.enabled }} + - port: {{ .Values.minio.containerPorts.api }} + to: + - podSelector: + matchLabels: + app.kubernetes.io/name: minio + app.kubernetes.io/instance: {{ .Release.Name }} + {{- end }} + # Allow outbound connections to zookeeper + - ports: + - port: {{ include "dremio.zookeeper.port" . }} + to: + {{- if .Values.zookeeper.enabled }} + - podSelector: + matchLabels: + app.kubernetes.io/name: zookeeper + app.kubernetes.io/instance: {{ .Release.Name }} + {{- end }} + {{- if .Values.masterCoordinator.networkPolicy.extraEgress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.masterCoordinator.networkPolicy.extraEgress "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} + ingress: + - ports: + - port: {{ .Values.dremio.containerPorts.web }} + {{- if (le (int .Values.coordinator.replicaCount) 0) }} + - port: {{ .Values.dremio.containerPorts.client }} + - port: {{ .Values.dremio.containerPorts.flight }} + {{- end }} + - port: {{ .Values.dremio.containerPorts.fabric }} + - port: {{ .Values.dremio.containerPorts.conduit }} + {{- if .Values.metrics.enabled }} + - port: {{ .Values.dremio.containerPorts.jmx }} + {{- end }} + {{- range .Values.masterCoordinator.extraContainerPorts }} + - port: {{ . }} + {{- end }} + {{- if not .Values.masterCoordinator.networkPolicy.allowExternal }} + from: + - podSelector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 14 }} + app.kubernetes.io/part-of: dremio + {{- if .Values.masterCoordinator.networkPolicy.addExternalClientAccess }} + - podSelector: + matchLabels: + {{ template "dremio.master-coordinator.fullname" . }}-client: "true" + {{- end }} + {{- if .Values.masterCoordinator.networkPolicy.ingressPodMatchLabels }} + - podSelector: + matchLabels: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.networkPolicy.ingressPodMatchLabels "context" $ ) | nindent 14 }} + {{- end }} + {{- if .Values.masterCoordinator.networkPolicy.ingressNSMatchLabels }} + - namespaceSelector: + matchLabels: + {{- range $key, $value := .Values.masterCoordinator.networkPolicy.ingressNSMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- if .Values.masterCoordinator.networkPolicy.ingressNSPodMatchLabels }} + podSelector: + matchLabels: + {{- range $key, $value := .Values.masterCoordinator.networkPolicy.ingressNSPodMatchLabels }} + {{ $key | quote }}: {{ $value | quote }} + {{- end }} + {{- end }} + {{- end }} + {{- end }} + {{- if .Values.masterCoordinator.networkPolicy.extraIngress }} + {{- include "common.tplvalues.render" ( dict "value" .Values.masterCoordinator.networkPolicy.extraIngress "context" $ ) | nindent 4 }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/master-coordinator/pdb.yaml b/bitnami/dremio/templates/master-coordinator/pdb.yaml new file mode 100644 index 0000000000..b2d30ad538 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/pdb.yaml @@ -0,0 +1,32 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.masterCoordinator.pdb.create }} +apiVersion: {{ include "common.capabilities.policy.apiVersion" . }} +kind: PodDisruptionBudget +metadata: + name: {{ include "dremio.master-coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.masterCoordinator.pdb.minAvailable }} + minAvailable: {{ .Values.masterCoordinator.pdb.minAvailable }} + {{- end }} + {{- if or .Values.masterCoordinator.pdb.maxUnavailable ( not .Values.masterCoordinator.pdb.minAvailable ) }} + maxUnavailable: {{ .Values.masterCoordinator.pdb.maxUnavailable | default 1 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" ( dict "values" ( list .Values.masterCoordinator.podLabels .Values.commonLabels ) "context" . ) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator +{{- end }} diff --git a/bitnami/dremio/templates/master-coordinator/pvc.yaml b/bitnami/dremio/templates/master-coordinator/pvc.yaml new file mode 100644 index 0000000000..4d05c95796 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/pvc.yaml @@ -0,0 +1,39 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.masterCoordinator.persistence.enabled (not .Values.masterCoordinator.persistence.existingClaim) }} +kind: PersistentVolumeClaim +apiVersion: v1 +metadata: + name: {{ include "dremio.master-coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + app: dremio-coordinator + annotations: + {{- if .Values.masterCoordinator.persistence.resourcePolicy }} + helm.sh/resource-policy: {{ .Values.masterCoordinator.persistence.resourcePolicy | quote }} + {{- end }} + {{- if or .Values.masterCoordinator.persistence.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.masterCoordinator.persistence.annotations .Values.commonAnnotations ) "context" . ) }} + {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + accessModes: + {{- range .Values.masterCoordinator.persistence.accessModes }} + - {{ . | quote }} + {{- end }} + resources: + requests: + storage: {{ .Values.masterCoordinator.persistence.size | quote }} + {{- if .Values.masterCoordinator.persistence.selector }} + selector: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.persistence.selector "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.masterCoordinator.persistence.dataSource }} + dataSource: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.persistence.dataSource "context" $) | nindent 4 }} + {{- end }} + {{- include "common.storage.class" (dict "persistence" .Values.masterCoordinator.persistence "global" .Values.global) | nindent 2 }} +{{- end -}} diff --git a/bitnami/dremio/templates/master-coordinator/secret-dremio-conf.yaml b/bitnami/dremio/templates/master-coordinator/secret-dremio-conf.yaml new file mode 100644 index 0000000000..7ca483028c --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/secret-dremio-conf.yaml @@ -0,0 +1,42 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- $extraFiles := mustMergeOverwrite .Values.dremio.dremioConf.extraSecretFiles .Values.masterCoordinator.dremioConf.extraSecretFiles }} +{{- $createDremioConf := or .Values.dremio.dremioConf.secretConfigOverrides .Values.masterCoordinator.dremioConf.secretConfigOverrides .Values.dremio.tls.enabled }} +{{- if and (not .Values.masterCoordinator.dremioConf.existingSecret) (or $createDremioConf $extraFiles) }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-dremio-conf" (include "dremio.master-coordinator.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +{{- /* We use stringData to simplify the templating of this file. It is as insecure as using base64 */}} +stringData: + {{- if and (not (hasKey $extraFiles "dremio.conf")) $createDremioConf }} + {{- /* dremio.conf uses HOCON, in which flattened YAML is a subset. So converting all values to flattened YAML generates a valid HOCON configuration */}} + {{- $defaultConfiguration := include "dremio.dremio-conf.common.defaultSecret" . | fromYaml -}} + {{- /* Obtain first the flattened version of all YAML content so the merge works as expected */}} + {{- $defaultConfigurationFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" $defaultConfiguration "prefix" "" "context" $) | fromYaml -}} + {{- $commonConfigOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.dremio.dremioConf.secretConfigOverrides "prefix" "" "context" $) | fromYaml -}} + {{- $configOverridesFlat := include "dremio.dremio-conf.flattenYAML" (dict "config" .Values.masterCoordinator.dremioConf.secretConfigOverrides "prefix" "" "context" $) | fromYaml -}} + {{- /* Override order: default configuration <- common overrides <- specific overrides */}} + {{- $mergedConfiguration := mustMergeOverwrite $defaultConfigurationFlat $commonConfigOverridesFlat }} + {{- $mergedConfiguration = mustMergeOverwrite $mergedConfiguration $configOverridesFlat }} + {{- $result := include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) }} + {{- /* Apply the helper again to avoid arrays having a HOCON incompatible format */}} + dremio.conf: | + {{- include "dremio.dremio-conf.flattenYAML" (dict "config" $mergedConfiguration "prefix" "" "context" $) | nindent 4 }} + {{- end }} + {{- if $extraFiles }} + {{- include "common.tplvalues.render" (dict "value" $extraFiles "context" $) | nindent 2 }} + {{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/master-coordinator/service-account.yaml b/bitnami/dremio/templates/master-coordinator/service-account.yaml new file mode 100644 index 0000000000..a4ce43b385 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/service-account.yaml @@ -0,0 +1,22 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.masterCoordinator.serviceAccount.create }} +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "dremio.master-coordinator.serviceAccountName" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.masterCoordinator.serviceAccount.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list .Values.masterCoordinator.serviceAccount.annotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +automountServiceAccountToken: {{ .Values.masterCoordinator.serviceAccount.automountServiceAccountToken }} +{{- end }} diff --git a/bitnami/dremio/templates/master-coordinator/statefulset.yaml b/bitnami/dremio/templates/master-coordinator/statefulset.yaml new file mode 100644 index 0000000000..b4b08b60a8 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/statefulset.yaml @@ -0,0 +1,371 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} +kind: StatefulSet +metadata: + name: {{ include "dremio.master-coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.masterCoordinator.statefulsetAnnotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list .Values.masterCoordinator.statefulsetAnnotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if not .Values.masterCoordinator.autoscaling.hpa.enabled }} + replicas: {{ .Values.masterCoordinator.replicaCount }} + {{- end }} + podManagementPolicy: {{ .Values.masterCoordinator.podManagementPolicy | quote }} + {{- $podLabels := include "common.tplvalues.merge" (dict "values" (list .Values.masterCoordinator.podLabels .Values.commonLabels) "context" .) }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 6 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + app: dremio-coordinator + serviceName: {{ printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + {{- if .Values.masterCoordinator.updateStrategy }} + updateStrategy: {{- toYaml .Values.masterCoordinator.updateStrategy | nindent 4 }} + {{- end }} + template: + metadata: + annotations: + checksum/dremio-conf-cm: {{ include (print $.Template.BasePath "/master-coordinator/configmap-dremio-conf.yaml") . | sha256sum }} + checksum/dremio-conf-secret: {{ include (print $.Template.BasePath "/master-coordinator/secret-dremio-conf.yaml") . | sha256sum }} + checksum/core-site-secret: {{ include (print $.Template.BasePath "/secret-core-site.yaml") . | sha256sum }} + {{- if .Values.masterCoordinator.podAnnotations }} + annotations: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.podAnnotations "context" $) | nindent 8 }} + {{- end }} + labels: {{- include "common.labels.standard" (dict "customLabels" $podLabels "context" $) | nindent 8 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + app: dremio-coordinator + spec: + {{- include "dremio.imagePullSecrets" . | nindent 6 }} + serviceAccountName: {{ template "dremio.master-coordinator.serviceAccountName" . }} + automountServiceAccountToken: {{ .Values.masterCoordinator.automountServiceAccountToken }} + {{- if .Values.masterCoordinator.hostAliases }} + hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.hostAliases "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.masterCoordinator.affinity }} + affinity: {{- include "common.tplvalues.render" ( dict "value" .Values.masterCoordinator.affinity "context" $) | nindent 8 }} + {{- else }} + affinity: + podAffinity: {{- include "common.affinities.pods" (dict "type" .Values.masterCoordinator.podAffinityPreset "component" "master-coordinator" "customLabels" $podLabels "context" $) | nindent 10 }} + podAntiAffinity: {{- include "common.affinities.pods" (dict "type" .Values.masterCoordinator.podAntiAffinityPreset "component" "master-coordinator" "customLabels" $podLabels "context" $) | nindent 10 }} + nodeAffinity: {{- include "common.affinities.nodes" (dict "type" .Values.masterCoordinator.nodeAffinityPreset.type "key" .Values.masterCoordinator.nodeAffinityPreset.key "values" .Values.masterCoordinator.nodeAffinityPreset.values) | nindent 10 }} + {{- end }} + {{- if .Values.masterCoordinator.nodeSelector }} + nodeSelector: {{- include "common.tplvalues.render" ( dict "value" .Values.masterCoordinator.nodeSelector "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.masterCoordinator.tolerations }} + tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.tolerations "context" .) | nindent 8 }} + {{- end }} + {{- if .Values.masterCoordinator.priorityClassName }} + priorityClassName: {{ .Values.masterCoordinator.priorityClassName | quote }} + {{- end }} + {{- if .Values.masterCoordinator.schedulerName }} + schedulerName: {{ .Values.masterCoordinator.schedulerName | quote }} + {{- end }} + {{- if .Values.masterCoordinator.topologySpreadConstraints }} + topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.topologySpreadConstraints "context" .) | nindent 8 }} + {{- end }} + {{- if .Values.masterCoordinator.podSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.masterCoordinator.podSecurityContext "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.masterCoordinator.terminationGracePeriodSeconds }} + terminationGracePeriodSeconds: {{ .Values.masterCoordinator.terminationGracePeriodSeconds }} + {{- end }} + initContainers: + {{- /* As most Bitnami charts have volumePermissions in the root, we add a volumePermissions.enabled check to maintain a similar UX */}} + {{- if and (or .Values.defaultInitContainers.volumePermissions.enabled ((.Values.volumePermissions).enabled)) .Values.masterCoordinator.persistence.enabled }} + {{- include "dremio.init-containers.volume-permissions" (dict "context" . "componentValues" .Values.masterCoordinator) | nindent 8}} + {{- end }} + {{- if .Values.defaultInitContainers.copyDefaultConf.enabled }} + {{- include "dremio.init-containers.copy-default-conf" . | nindent 8 }} + {{- end }} + {{- if .Values.defaultInitContainers.wait.enabled }} + {{- include "dremio.init-containers.wait-for-s3" . | nindent 8 }} + {{- include "dremio.init-containers.wait-for-zookeeper" . | nindent 8 }} + {{- end }} + {{- if .Values.defaultInitContainers.generateConf.enabled }} + {{- include "dremio.init-containers.generate-conf" (dict "context" . "mountDremioConfSecret" (include "dremio.master-coordinator.dremio-conf.useSecret" .)) | nindent 8 }} + {{- end }} + {{- if and .Values.dremio.tls.enabled .Values.defaultInitContainers.initCerts.enabled }} + {{- include "dremio.init-containers.init-certs" . | nindent 8 }} + {{- end }} + {{- if .Values.defaultInitContainers.upgradeKeystore.enabled }} + {{- include "dremio.init-containers.upgrade-keystore" . | nindent 8 }} + {{- end }} + {{- if .Values.masterCoordinator.initContainers }} + {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.initContainers "context" $) | nindent 8 }} + {{- end }} + containers: + - name: dremio + image: {{ template "dremio.image" . }} + imagePullPolicy: {{ .Values.dremio.image.pullPolicy }} + {{- if .Values.masterCoordinator.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.masterCoordinator.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.diagnosticMode.enabled }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 12 }} + {{- else if .Values.masterCoordinator.command }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.command "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.diagnosticMode.enabled }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else if .Values.masterCoordinator.args }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.args "context" $) | nindent 12 }} + {{- end }} + env: + - name: BITNAMI_DEBUG + value: {{ ternary "true" "false" (or .Values.dremio.image.debug .Values.diagnosticMode.enabled) | quote }} + - name: DREMIO_JAVA_SERVER_EXTRA_OPTS + value: | + {{- if and (eq .Values.dremio.distStorageType "minio") (or (and .Values.minio.enabled (((.Values.minio).tls).enabled) (((.Values.minio).tls).autoGenerated)) .Values.externalS3.disableCertChecking) }} + -Dcom.amazonaws.sdk.disableCertChecking=true + {{- end }} + {{- if .Values.metrics.enabled }} + -Dcom.sun.management.jmxremote.port={{ .Values.dremio.containerPorts.jmx }} + -Dcom.sun.management.jmxremote.authenticate=false + -Dcom.sun.management.jmxremote.ssl=false + {{- end }} + {{- if .Values.masterCoordinator.extraJavaOpts }} + {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.extraJavaOpts "context" $) | nindent 16 }} + {{- end }} + - name: DREMIO_MAX_MEMORY_SIZE_MB + valueFrom: + resourceFieldRef: + containerName: dremio + resource: limits.memory + divisor: 1Mi + {{- if .Values.masterCoordinator.extraEnvVars }} + {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.extraEnvVars "context" $) | nindent 12 }} + {{- end }} + envFrom: + {{- if .Values.masterCoordinator.extraEnvVarsCM }} + - configMapRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.extraEnvVarsCM "context" $) }} + {{- end }} + {{- if .Values.masterCoordinator.extraEnvVarsSecret }} + - secretRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.extraEnvVarsSecret "context" $) }} + {{- end }} + {{- if .Values.masterCoordinator.resources }} + resources: {{- toYaml .Values.masterCoordinator.resources | nindent 12 }} + {{- else if ne .Values.masterCoordinator.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.masterCoordinator.resourcesPreset) | nindent 12 }} + {{- end }} + ports: + - containerPort: {{ .Values.dremio.containerPorts.web }} + name: web + - containerPort: {{ .Values.dremio.containerPorts.liveness }} + name: liveness + {{- if (le (int .Values.coordinator.replicaCount) 0) }} + - containerPort: {{ .Values.dremio.containerPorts.client }} + name: client + - containerPort: {{ .Values.dremio.containerPorts.flight }} + name: flight + {{- end }} + - containerPort: {{ .Values.dremio.containerPorts.fabric }} + name: server-fabric + - containerPort: {{ .Values.dremio.containerPorts.conduit }} + name: server-conduit + {{- if .Values.metrics.enabled }} + - containerPort: {{ .Values.dremio.containerPorts.jmx }} + name: jmx + {{- end }} + {{- if .Values.masterCoordinator.extraContainerPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.extraContainerPorts "context" $) | nindent 12 }} + {{- end }} + {{- if not .Values.diagnosticMode.enabled }} + {{- if .Values.masterCoordinator.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.customLivenessProbe "context" $) | nindent 12 }} + {{- else if .Values.masterCoordinator.livenessProbe.enabled }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.masterCoordinator.livenessProbe "enabled") "context" $) | nindent 12 }} + tcpSocket: + port: liveness + {{- end }} + {{- if .Values.masterCoordinator.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.customReadinessProbe "context" $) | nindent 12 }} + {{- else if .Values.masterCoordinator.readinessProbe.enabled }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.masterCoordinator.readinessProbe "enabled") "context" $) | nindent 12 }} + httpGet: + path: / + port: web + scheme: {{ ternary "HTTPS" "HTTP" .Values.dremio.tls.enabled }} + {{- end }} + {{- if .Values.masterCoordinator.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.customStartupProbe "context" $) | nindent 12 }} + {{- else if .Values.masterCoordinator.startupProbe.enabled }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.masterCoordinator.startupProbe "enabled") "context" $) | nindent 12 }} + tcpSocket: + port: liveness + {{- end }} + {{- end }} + {{- if .Values.masterCoordinator.lifecycleHooks }} + lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.lifecycleHooks "context" $) | nindent 12 }} + {{- end }} + volumeMounts: + - name: data + mountPath: {{ .Values.masterCoordinator.persistence.mountPath }} + {{- if .Values.masterCoordinator.persistence.subPath }} + subPath: {{ .Values.masterCoordinator.persistence.subPath }} + {{- end }} + - name: empty-dir + mountPath: /tmp + subPath: tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/tmp + subPath: app-tmp-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/run + subPath: app-run-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/log + subPath: app-log-dir + - name: empty-dir + mountPath: /opt/bitnami/dremio/conf + subPath: app-conf-dir + {{- if .Values.metrics.enabled }} + - name: metrics-configuration + mountPath: /opt/bitnami/dremio/conf/dremio-telemetry.yaml + subPath: dremio-telemetry.yaml + {{- end }} + {{- if .Values.dremio.tls.enabled }} + - name: empty-dir + mountPath: /opt/bitnami/dremio/certs + subPath: app-processed-certs-dir + {{- end }} + {{- if .Values.masterCoordinator.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.extraVolumeMounts "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.metrics.enabled }} + - name: metrics + image: {{ include "dremio.metrics.image" . }} + imagePullPolicy: {{ .Values.metrics.image.pullPolicy | quote }} + {{- if .Values.metrics.containerSecurityContext.enabled }} + securityContext: {{- include "common.compatibility.renderSecurityContext" (dict "secContext" .Values.metrics.containerSecurityContext "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.diagnosticMode.enabled }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.command "context" $) | nindent 12 }} + args: {{- include "common.tplvalues.render" (dict "value" .Values.diagnosticMode.args "context" $) | nindent 12 }} + {{- else }} + command: + - java + args: + - -XX:MaxRAMPercentage=100 + - -XshowSettings:vm + - -jar + - jmx_prometheus_httpserver.jar + - {{ .Values.metrics.containerPorts.metrics | quote }} + - /etc/jmx-dremio/jmx-prometheus.yml + {{- end }} + ports: + - name: metrics + containerPort: {{ .Values.metrics.containerPorts.metrics }} + {{- if .Values.metrics.resources }} + resources: {{- toYaml .Values.metrics.resources | nindent 12 }} + {{- else if ne .Values.metrics.resourcesPreset "none" }} + resources: {{- include "common.resources.preset" (dict "type" .Values.metrics.resourcesPreset) | nindent 12 }} + {{- end }} + {{- if not .Values.diagnosticMode.enabled }} + {{- if .Values.metrics.livenessProbe.enabled }} + livenessProbe: {{- omit .Values.metrics.livenessProbe "enabled" | toYaml | nindent 12 }} + tcpSocket: + port: metrics + {{- end }} + {{- if .Values.metrics.readinessProbe.enabled }} + readinessProbe: {{- omit .Values.metrics.readinessProbe "enabled" | toYaml | nindent 12 }} + httpGet: + path: / + port: metrics + {{- end }} + {{- if .Values.metrics.startupProbe.enabled }} + startupProbe: {{- omit .Values.metrics.startupProbe "enabled" | toYaml | nindent 12 }} + httpGet: + path: / + port: metrics + {{- end }} + {{- end }} + volumeMounts: + - name: metrics-configuration + mountPath: /etc/jmx-dremio/jmx-prometheus.yml + subPath: jmx-prometheus.yml + {{- end }} + {{- if .Values.masterCoordinator.sidecars }} + {{- include "common.tplvalues.render" ( dict "value" .Values.masterCoordinator.sidecars "context" $) | nindent 8 }} + {{- end }} + volumes: + - name: empty-dir + emptyDir: {} + - name: input-dremio-conf-cm + configMap: + name: {{ include "dremio.master-coordinator.dremio-conf.configmapName" . }} + {{- if .Values.usePasswordFile }} + {{- if or .Values.dremio.tls.passwordSecret .Values.dremio.tls.password .Values.dremio.tls.autoGenerated.enabled .Values.dremio.tls.usePemCerts }} + - name: keystore-password + secret: + secretName: {{ include "dremio.tls.passwordSecretName" . }} + items: + - key: keystore-password + path: DREMIO_KEYSTORE_PASSWORD + {{- end }} + {{- if or (eq .Values.dremio.distStorageType "minio") (eq .Values.dremio.distStorageType "aws") }} + - name: s3-credentials + secret: + secretName: {{ include "dremio.s3.secretName" . }} + items: + - key: {{ include "dremio.s3.accessKeyIDKey" . }} + path: DREMIO_AWS_ACCESS_KEY_ID + - key: {{ include "dremio.s3.secretAccessKeyKey" . }} + path: DREMIO_AWS_SECRET_ACCESS_KEY + {{- end }} + {{- end }} + {{- if (include "dremio.master-coordinator.dremio-conf.useSecret" .) }} + - name: input-dremio-conf-secret + secret: + secretName: {{ include "dremio.master-coordinator.dremio-conf.secretName" . }} + {{- end }} + - name: input-core-site + secret: + secretName: {{ include "dremio.core-site.secretName" . }} + {{- if .Values.metrics.enabled }} + - name: metrics-configuration + configMap: + name: {{ include "dremio.metrics.configmapName" . }} + {{- end }} + {{- if .Values.dremio.tls.enabled }} + - name: input-tls-certs + secret: + secretName: {{ include "dremio.tls.secretName" . }} + items: + {{- if .Values.dremio.tls.usePemCerts }} + - key: {{ .Values.dremio.tls.certFilename }} + path: tls.crt + - key: {{ .Values.dremio.tls.certKeyFilename }} + path: tls.key + {{- else }} + - key: {{ .Values.dremio.tls.keystoreFilename }} + path: dremio.jks + {{- end }} + {{- end }} + {{- /* + All Dremio master-coordinator instances need to share the same PVC: + https://docs.dremio.com/current/get-started/cluster-deployments/architecture/high-availability/ + */}} + - name: data + {{- if .Values.masterCoordinator.persistence.enabled }} + persistentVolumeClaim: + claimName: {{ default (include "dremio.master-coordinator.fullname" .) .Values.masterCoordinator.persistence.existingClaim }} + {{- else }} + emptyDir: {} + {{- end }} + {{- if .Values.masterCoordinator.extraVolumes }} + {{- include "common.tplvalues.render" (dict "value" .Values.masterCoordinator.extraVolumes "context" $) | nindent 8 }} + {{- end }} diff --git a/bitnami/dremio/templates/master-coordinator/vpa.yaml b/bitnami/dremio/templates/master-coordinator/vpa.yaml new file mode 100644 index 0000000000..70a892fe45 --- /dev/null +++ b/bitnami/dremio/templates/master-coordinator/vpa.yaml @@ -0,0 +1,47 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and (.Capabilities.APIVersions.Has "autoscaling.k8s.io/v1/VerticalPodAutoscaler") .Values.masterCoordinator.autoscaling.vpa.enabled }} +apiVersion: {{ include "common.capabilities.vpa.apiVersion" (dict "context" $) }} +kind: VerticalPodAutoscaler +metadata: + name: {{ include "dremio.master-coordinator.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: master-coordinator + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.masterCoordinator.autoscaling.vpa.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.masterCoordinator.autoscaling.vpa.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + resourcePolicy: + containerPolicies: + - containerName: dremio + {{- with .Values.masterCoordinator.autoscaling.vpa.controlledResources }} + controlledResources: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.masterCoordinator.autoscaling.vpa.maxAllowed }} + maxAllowed: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.masterCoordinator.autoscaling.vpa.minAllowed }} + minAllowed: + {{- toYaml . | nindent 8 }} + {{- end }} + targetRef: + apiVersion: {{ include "common.capabilities.statefulset.apiVersion" . }} + kind: StatefulSet + name: {{ include "dremio.master-coordinator.fullname" . }} + {{- if .Values.masterCoordinator.autoscaling.vpa.updatePolicy }} + updatePolicy: + {{- with .Values.masterCoordinator.autoscaling.vpa.updatePolicy.updateMode }} + updateMode: {{ . }} + {{- end }} + {{- end }} +{{- end }} diff --git a/bitnami/dremio/templates/metrics/metrics-configmap.yaml b/bitnami/dremio/templates/metrics/metrics-configmap.yaml new file mode 100644 index 0000000000..374cabb94e --- /dev/null +++ b/bitnami/dremio/templates/metrics/metrics-configmap.yaml @@ -0,0 +1,51 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{/* Adding the helper in here for better readability */}} +{{- define "dremio.metrics.jmxConfiguration.default" }} +jmxUrl: service:jmx:rmi:///jndi/rmi://127.0.0.1:{{ .Values.dremio.containerPorts.jmx }}/jmxrmi +lowercaseOutputName: true +lowercaseOutputLabelNames: true +ssl: false +rules: + - pattern: ".*" +{{- end }} + +{{- define "dremio.metrics.telemetryConfiguration.default" }} +{{- /* Taken from https://docs.dremio.com/current/sonar/monitoring/dremio-nodes/#enabling-node-metrics */}} +auto-reload: + enabled: True + period: 90 + unit: SECONDS + +metrics: + - name: jmx_reporter + comment: "Publish metrics on jmx" + reporter: + type: jmx + rate: SECONDS + duration: MILLISECONDS +{{- end }} + +{{- if and .Values.metrics.enabled (not .Values.metrics.existingConfigmap) }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ printf "%s-metrics-configuration" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: metrics + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + {{- $jmxConfiguration := mustMergeOverwrite (include "dremio.metrics.jmxConfiguration.default" . | fromYaml) (include "common.tplvalues.render" (dict "value" .Values.metrics.jmxConfigOverrides "context" $) | fromYaml) }} + jmx-prometheus.yml: | + {{- toYaml $jmxConfiguration | nindent 4 }} + {{- $telemetryConfiguration := mustMergeOverwrite (include "dremio.metrics.telemetryConfiguration.default" . | fromYaml) (include "common.tplvalues.render" (dict "value" .Values.metrics.telemetryConfigOverrides "context" $) | fromYaml) }} + dremio-telemetry.yaml: | + {{- toYaml $telemetryConfiguration | nindent 4 }} +{{- end -}} diff --git a/bitnami/dremio/templates/metrics/service.yaml b/bitnami/dremio/templates/metrics/service.yaml new file mode 100644 index 0000000000..291f0ab3fa --- /dev/null +++ b/bitnami/dremio/templates/metrics/service.yaml @@ -0,0 +1,32 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if .Values.metrics.enabled }} +apiVersion: v1 +kind: Service +metadata: + name: {{ printf "%s-metrics" (include "common.names.fullname" .) }} + namespace: {{ include "common.names.namespace" . | quote }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.commonLabels .Values.metrics.service.labels) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: metrics + {{- $defaultAnnotations := dict "prometheus.io/scrape" "true" "prometheus.io/port" (.Values.metrics.service.ports.metrics | quote) "prometheus.io/path" "/" }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list $defaultAnnotations .Values.metrics.service.annotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" (dict "value" $annotations "context" $) | nindent 4 }} +spec: + type: ClusterIP + sessionAffinity: {{ .Values.metrics.service.sessionAffinity }} + {{- if .Values.metrics.service.clusterIP }} + clusterIP: {{ .Values.metrics.service.clusterIP }} + {{- end }} + ports: + - name: http-metrics + port: {{ .Values.metrics.service.ports.metrics }} + protocol: TCP + targetPort: metrics + selector: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio +{{- end }} diff --git a/bitnami/dremio/templates/metrics/servicemonitor.yaml b/bitnami/dremio/templates/metrics/servicemonitor.yaml new file mode 100644 index 0000000000..9e07997189 --- /dev/null +++ b/bitnami/dremio/templates/metrics/servicemonitor.yaml @@ -0,0 +1,52 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and .Values.metrics.enabled .Values.metrics.serviceMonitor.enabled }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ printf "%s-metrics" (include "common.names.fullname" .) }} + namespace: {{ default (include "common.names.namespace" .) .Values.metrics.serviceMonitor.namespace | quote }} + {{- $labels := include "common.tplvalues.merge" ( dict "values" ( list .Values.metrics.serviceMonitor.labels .Values.commonLabels ) "context" . ) }} + labels: {{- include "common.labels.standard" ( dict "customLabels" $labels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: metrics + {{- if or .Values.metrics.serviceMonitor.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.metrics.serviceMonitor.annotations .Values.commonAnnotations ) "context" . ) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.metrics.serviceMonitor.jobLabel }} + jobLabel: {{ .Values.metrics.serviceMonitor.jobLabel }} + {{- end }} + selector: + matchLabels: {{- include "common.labels.matchLabels" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 6 }} + {{- if .Values.metrics.serviceMonitor.selector }} + {{- include "common.tplvalues.render" (dict "value" .Values.metrics.serviceMonitor.selector "context" $) | nindent 6 }} + {{- end }} + app.kubernetes.io/part-of: dremio + app.kubernetes.io/component: metrics + endpoints: + - port: http-metrics + path: "/" + {{- if .Values.metrics.serviceMonitor.interval }} + interval: {{ .Values.metrics.serviceMonitor.interval }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.scrapeTimeout }} + scrapeTimeout: {{ .Values.metrics.serviceMonitor.scrapeTimeout }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.relabelings }} + relabelings: {{- include "common.tplvalues.render" ( dict "value" .Values.metrics.serviceMonitor.relabelings "context" $) | nindent 6 }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.metricRelabelings }} + metricRelabelings: {{- include "common.tplvalues.render" ( dict "value" .Values.metrics.serviceMonitor.metricRelabelings "context" $) | nindent 6 }} + {{- end }} + {{- if .Values.metrics.serviceMonitor.honorLabels }} + honorLabels: {{ .Values.metrics.serviceMonitor.honorLabels }} + {{- end }} + namespaceSelector: + matchNames: + - {{ include "common.names.namespace" . }} +{{- end }} diff --git a/bitnami/dremio/templates/secret-core-site.yaml b/bitnami/dremio/templates/secret-core-site.yaml new file mode 100644 index 0000000000..f40191d2f3 --- /dev/null +++ b/bitnami/dremio/templates/secret-core-site.yaml @@ -0,0 +1,82 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if not .Values.dremio.coreSite.existingSecret }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-core-site" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +stringData: + core-site.xml: | + {{- /* There are values that depend on other secrets, so we make them relative to env vars. These will be rendered using an init container */}} + + + {{- if or (eq .Values.dremio.distStorageType "minio") (eq .Values.dremio.distStorageType "aws") }} + + fs.dremioS3.impl + The FileSystem implementation. Must be set to com.dremio.plugins.s3.store.S3FileSystem + com.dremio.plugins.s3.store.S3FileSystem + + + fs.s3a.connection.ssl.enabled + Value can either be true or false, set to true to use SSL with a secure Minio server. + {{ ternary "true" "false" (eq (include "dremio.s3.protocol" .) "https") }} + + {{- if or (eq .Values.dremio.distStorageType "minio") (eq .Values.externalS3.authentication "accesskey") }} + + fs.s3a.aws.credentials.provider + The credential provider type. + org.apache.hadoop.fs.s3a.SimpleAWSCredentialsProvider + + + fs.s3a.access.key + AWS access key ID. + {{ print "{{ DREMIO_AWS_ACCESS_KEY_ID }}" }} + + + fs.s3a.secret.key + AWS secret key. + {{ print "{{ DREMIO_AWS_SECRET_ACCESS_KEY }}" }} + + {{- end }} + {{- if eq .Values.dremio.distStorageType "minio" }} + {{- /* MinIO specific settings */}} + + fs.s3a.endpoint + {{ include "dremio.s3.host" . }}:{{ include "dremio.s3.port" . }} + + + fs.s3a.path.style.access + true + + + dremio.s3.compat + true + + {{- else }} + {{- /* AWS specific settings */}} + {{- if .Values.externalS3.host }} + + fs.s3a.endpoint + {{ include "dremio.s3.host" . }} + + {{- end }} + + fs.s3a.endpoint.region + {{ include "dremio.s3.region" . }} + + {{- end }} + {{- end }} + {{- if .Values.dremio.coreSite.appendConfiguration }} + {{- include "common.tplvalues.render" (dict "value" .Values.dremio.coreSite.appendConfiguration "context" $) | nindent 6 }} + {{- end }} + +{{- end }} \ No newline at end of file diff --git a/bitnami/dremio/templates/secrets.yaml b/bitnami/dremio/templates/secrets.yaml new file mode 100644 index 0000000000..aa762d7068 --- /dev/null +++ b/bitnami/dremio/templates/secrets.yaml @@ -0,0 +1,42 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} +{{- if .Values.dremio.auth.enabled }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ include "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: Opaque +data: + dremio-password: {{ include "common.secrets.passwords.manage" (dict "secret" ( include "common.names.fullname" .) "key" "dremio-password" "providedValues" (list "dremio.auth.password") "context" $) }} +{{- end }} +{{- if and (or .Values.dremio.tls.autoGenerated.enabled .Values.dremio.tls.existingSecret) (not .Values.dremio.tls.passwordSecret) }} +--- +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-tls-pass" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: Opaque +data: + {{- if .Values.dremio.tls.existingSecret }} + {{- $pass := required "If 'dremio.tls.existingSecret' is provided, providing a JKS password is mandatory" .Values.dremio.tls.password }} + {{- end }} + keystore-password: {{ include "common.secrets.passwords.manage" (dict "secret" ( printf "%s-tls-pass" (include "common.names.fullname" .)) "key" "keystore-password" "providedValues" (list "dremio.tls.password") "context" $) }} +{{- end }} diff --git a/bitnami/dremio/templates/service.yaml b/bitnami/dremio/templates/service.yaml new file mode 100644 index 0000000000..9079848cbd --- /dev/null +++ b/bitnami/dremio/templates/service.yaml @@ -0,0 +1,69 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +apiVersion: v1 +kind: Service +metadata: + name: {{ include "common.names.fullname" . }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if or .Values.service.annotations .Values.commonAnnotations }} + {{- $annotations := include "common.tplvalues.merge" (dict "values" (list .Values.service.annotations .Values.commonAnnotations) "context" .) }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + type: {{ .Values.service.type }} + {{- if and .Values.service.clusterIP (eq .Values.service.type "ClusterIP") }} + clusterIP: {{ .Values.service.clusterIP }} + {{- end }} + {{- if .Values.service.sessionAffinity }} + sessionAffinity: {{ .Values.service.sessionAffinity }} + {{- end }} + {{- if .Values.service.sessionAffinityConfig }} + sessionAffinityConfig: {{- include "common.tplvalues.render" (dict "value" .Values.service.sessionAffinityConfig "context" $) | nindent 4 }} + {{- end }} + {{- if or (eq .Values.service.type "LoadBalancer") (eq .Values.service.type "NodePort") }} + externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy | quote }} + {{- end }} + {{- if and (eq .Values.service.type "LoadBalancer") (not (empty .Values.service.loadBalancerSourceRanges)) }} + loadBalancerSourceRanges: {{ .Values.service.loadBalancerSourceRanges }} + {{- end }} + {{- if and (eq .Values.service.type "LoadBalancer") (not (empty .Values.service.loadBalancerIP)) }} + loadBalancerIP: {{ .Values.service.loadBalancerIP }} + {{- end }} + ports: + - name: http-web + port: {{ .Values.service.ports.web }} + targetPort: web + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.web)) }} + nodePort: {{ .Values.service.nodePorts.web }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + - name: tcp-client + port: {{ .Values.service.ports.client }} + targetPort: client + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.client)) }} + nodePort: {{ .Values.service.nodePorts.client }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + - name: tcp-flight + port: {{ .Values.service.ports.flight }} + targetPort: flight + {{- if and (or (eq .Values.service.type "NodePort") (eq .Values.service.type "LoadBalancer")) (not (empty .Values.service.nodePorts.flight)) }} + nodePort: {{ .Values.service.nodePorts.flight }} + {{- else if eq .Values.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- if .Values.service.extraPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.service.extraPorts "context" $) | nindent 4 }} + {{- end }} + {{- $podLabels := include "common.tplvalues.merge" (dict "values" (list .Values.commonLabels) "context" .) | fromYaml }} + selector: {{- include "common.labels.matchLabels" ( dict "customLabels" $podLabels "context" $ ) | nindent 4 }} + app: dremio-coordinator diff --git a/bitnami/dremio/templates/tls-secret.yaml b/bitnami/dremio/templates/tls-secret.yaml new file mode 100644 index 0000000000..2a1feb960c --- /dev/null +++ b/bitnami/dremio/templates/tls-secret.yaml @@ -0,0 +1,52 @@ +{{- /* +Copyright Broadcom, Inc. All Rights Reserved. +SPDX-License-Identifier: APACHE-2.0 +*/}} + +{{- if and (include "dremio.tls.createSecret" . ) (eq .Values.dremio.tls.autoGenerated.engine "helm") }} +{{- $ca := genCA "dremio-ca" 365 }} +{{- $caSecretName := printf "%s-ca-crt" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ $caSecretName }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ include "common.secrets.lookup" (dict "secret" $caSecretName "key" "tls.crt" "defaultValue" $ca.Cert "context" $) }} + tls.key: {{ include "common.secrets.lookup" (dict "secret" $caSecretName "key" "tls.key" "defaultValue" $ca.Key "context" $) }} + ca.crt: {{ include "common.secrets.lookup" (dict "secret" $caSecretName "key" "ca.crt" "defaultValue" $ca.Cert "context" $) }} + +--- +{{- $fullname := include "common.names.fullname" . }} +{{- $releaseNamespace := include "common.names.namespace" . }} +{{- $clusterDomain := .Values.clusterDomain }} +{{- $serviceName := include "common.names.fullname" . }} +{{- $headlessServiceName := printf "%s-headless" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} +{{- $altNames := list (printf "*.%s.%s.svc.%s" $serviceName $releaseNamespace $clusterDomain) (printf "%s.%s.svc.%s" $serviceName $releaseNamespace $clusterDomain) (printf "*.%s.%s.svc.%s" $headlessServiceName $releaseNamespace $clusterDomain) (printf "%s.%s.svc.%s" $headlessServiceName $releaseNamespace $clusterDomain) "localhost" "127.0.0.1" $fullname }} +{{- $cert := genSignedCert $fullname nil $altNames 365 $ca }} +{{- $secretName := printf "%s-crt" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ $secretName }} + namespace: {{ include "common.names.namespace" . | quote }} + labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }} + app.kubernetes.io/part-of: dremio + {{- /* We need an extra label that applies to both master and non-master coordinators. Taken from upstream dremio chart */}} + app: dremio-coordinator + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.crt" "defaultValue" $cert.Cert "context" $) }} + tls.key: {{ include "common.secrets.lookup" (dict "secret" $secretName "key" "tls.key" "defaultValue" $cert.Key "context" $) }} +{{- end }} diff --git a/bitnami/dremio/values.yaml b/bitnami/dremio/values.yaml new file mode 100644 index 0000000000..2788feb1e4 --- /dev/null +++ b/bitnami/dremio/values.yaml @@ -0,0 +1,2585 @@ +# Copyright Broadcom, Inc. All Rights Reserved. +# SPDX-License-Identifier: APACHE-2.0 + +## @section Global parameters +## Global Docker image parameters +## Please, note that this will override the image parameters, including dependencies, configured to use the global value +## Current available global Docker image parameters: imageRegistry, imagePullSecrets and storageClass +## + +## @param global.imageRegistry Global Docker image registry +## @param global.imagePullSecrets Global Docker registry secret names as an array +## @param global.storageClass Global StorageClass for Persistent Volume(s) +## +global: + imageRegistry: "" + ## e.g: + ## imagePullSecrets: + ## - myRegistryKeySecretName + ## + imagePullSecrets: [] + storageClass: "" + ## Compatibility adaptations for Kubernetes platforms + ## + compatibility: + ## Compatibility adaptations for Openshift + ## + openshift: + ## @param global.compatibility.openshift.adaptSecurityContext Adapt the securityContext sections of the deployment to make them compatible with Openshift restricted-v2 SCC: remove runAsUser, runAsGroup and fsGroup and let the platform use their allowed default IDs. Possible values: auto (apply if the detected running cluster is Openshift), force (perform the adaptation always), disabled (do not perform adaptation) + ## + adaptSecurityContext: auto + +## @section Common parameters +## + +## @param kubeVersion Override Kubernetes version +## +kubeVersion: "" +## @param nameOverride String to partially override common.names.name +## +nameOverride: "" +## @param fullnameOverride String to fully override common.names.fullname +## +fullnameOverride: "" +## @param namespaceOverride String to fully override common.names.namespace +## +namespaceOverride: "" +## @param commonLabels Labels to add to all deployed objects +## +commonLabels: {} +## @param commonAnnotations Annotations to add to all deployed objects +## +commonAnnotations: {} +## @param clusterDomain Kubernetes cluster domain name +## +clusterDomain: cluster.local +## @param extraDeploy Array of extra objects to deploy with the release +## +extraDeploy: [] +## Diagnostic mode +## @param diagnosticMode.enabled Enable diagnostic mode (all probes will be disabled and the command will be overridden) +## @param diagnosticMode.command Command to override all containers in the chart release +## @param diagnosticMode.args Args to override all containers in the chart release +## +diagnosticMode: + enabled: false + command: + - sleep + args: + - infinity + +## @param usePasswordFile Mount secrets as files +## +usePasswordFile: true + +## @section Dremio common configuration settings +## +## +dremio: + ## Bitnami Dremio image + ## ref: https://hub.docker.com/r/bitnami/dremio/tags/ + ## @param dremio.image.registry [default: REGISTRY_NAME] Dremio image registry + ## @param dremio.image.repository [default: REPOSITORY_NAME/dremio] Dremio image repository + ## @skip dremio.image.tag Dremio image tag (immutable tags are recommended) + ## @param dremio.image.digest Dremio image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag image tag (immutable tags are recommended) + ## @param dremio.image.pullPolicy Dremio image pull policy + ## @param dremio.image.pullSecrets Dremio image pull secrets + ## @param dremio.image.debug Enable Dremio image debug mode + ## + image: + registry: docker.io + repository: bitnami/dremio + tag: 25.0.0-debian-12-r0 + digest: "" + ## Specify a imagePullPolicy + ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' + ## ref: https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images + ## + pullPolicy: IfNotPresent + ## Optionally specify an array of imagePullSecrets. + ## Secrets must be manually created in the namespace. + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + debug: false + ## Auth parameters + ## @param dremio.auth.enabled Automatically bootstrap a Dremio user + ## @param dremio.auth.username Dremio bootstrap username + ## @param dremio.auth.password Dremio bootstrap password + ## @param dremio.auth.firstName Dremio bootstrap first name + ## @param dremio.auth.lastName Dremio bootstrap last name + ## @param dremio.auth.email Dremio bootstrap email + ## @param dremio.auth.existingSecret Name of a secret containing the password of the bootstrap user + ## @param dremio.auth.existingSecretKey Key inside the secret containing the password of the bootstrap user (requires setting existingSecret) + auth: + enabled: true + username: user + password: "" + firstName: User + lastName: User + email: user@example.com + existingSecret: "" + existingSecretKey: "" + ## TLS/SSL parameters + ## NOTE: Dremio OSS only supports TLS in the web frontend + ## @param dremio.tls.enabled Enable TLS in the web frontend + ## @param dremio.tls.usePemCerts Use certificates in .pem format + ## @param dremio.tls.existingSecret Name of a secret containing the certificate files + ## @param dremio.tls.certFilename Filename inside the secret of the .crt file (when usePemCerts=true) + ## @param dremio.tls.certKeyFilename Filename inside the secret of the .key file (when usePemCerts=true) + ## @param dremio.tls.keystoreFilename Filename inside the secret of the .jks file (when usePemCerts=false) + ## @param dremio.tls.password Password of the Java keystore + ## @param dremio.tls.passwordSecret Name of a secret containing the password of the Java keystore + ## + tls: + enabled: false + usePemCerts: true + existingSecret: "" + certFilename: tls.crt + certKeyFilename: tls.key + keystoreFilename: dremio.jks + password: "" + passwordSecret: "" + ## @param dremio.tls.autoGenerated.enabled Enable automatic generation of certificates for TLS + ## @param dremio.tls.autoGenerated.engine Mechanism to generate the certificates (allowed values: helm, cert-manager) + autoGenerated: + enabled: true + engine: helm + ## @param dremio.tls.autoGenerated.certManager.existingIssuer The name of an existing Issuer to use for generating the certificates (only for `cert-manager` engine) + ## @param dremio.tls.autoGenerated.certManager.existingIssuerKind Existing Issuer kind, defaults to Issuer (only for `cert-manager` engine) + ## @param dremio.tls.autoGenerated.certManager.keyAlgorithm Key algorithm for the certificates (only for `cert-manager` engine) + ## @param dremio.tls.autoGenerated.certManager.keySize Key size for the certificates (only for `cert-manager` engine) + ## @param dremio.tls.autoGenerated.certManager.duration Duration for the certificates (only for `cert-manager` engine) + ## @param dremio.tls.autoGenerated.certManager.renewBefore Renewal period for the certificates (only for `cert-manager` engine) + certManager: + existingIssuer: "" + existingIssuerKind: "" + keySize: 2048 + keyAlgorithm: RSA + duration: 2160h + renewBefore: 360h + ## @param dremio.distStorageType Dremio distributed storage type. Allowed values: "minio", "aws" and "others" ("minio" and "aws" natively supported, the rest of the types requires adding extra configuration parameters in the "dremio.dremioConf" and "dremio.coreSite" sections) + ## + distStorageType: "minio" + ## @param dremio.dremioConf.configOverrides Add configuration overrides in dremio.conf applied to all components (using YAML format) + ## @param dremio.dremioConf.secretConfigOverrides Add sensitive configuration overrides in dremio.conf applied to all components (using YAML format) + ## @param dremio.dremioConf.extraFiles Add extra configuration files + ## @param dremio.dremioConf.extraSecretFiles Add extra sensitive configuration files + ## + dremioConf: + configOverrides: {} + secretConfigOverrides: {} + extraFiles: {} + extraSecretFiles: {} + ## @param dremio.coreSite.appendConfiguration Add extra configuration in the core-site.xml file (in XML format) + ## @param dremio.coreSite.existingSecret Name of a secret containing the core-site.xml file + ## + coreSite: + appendConfiguration: "" + existingSecret: "" + ## Dremio container ports (shared amongst all the components) + ## @param dremio.containerPorts.web Dremio Web container port + ## @param dremio.containerPorts.client Dremio client container port + ## @param dremio.containerPorts.flight Dremio flight container port + ## @param dremio.containerPorts.fabric Dremio fabric container port + ## @param dremio.containerPorts.conduit Dremio conduit container port + ## @param dremio.containerPorts.jmx Dremio JMX container port + ## @param dremio.containerPorts.liveness Dremio liveness container port + ## + containerPorts: + web: 9047 + client: 31010 + flight: 32010 + fabric: 45678 + conduit: 45679 + jmx: 50000 + liveness: 44349 + +## @section Dremio Master Coordinator Parameters +## +## +masterCoordinator: + ## @param masterCoordinator.replicaCount Number of Dremio Master Coordinator replicas to deploy + ## + replicaCount: 1 + ## @param masterCoordinator.extraContainerPorts Optionally specify extra list of additional ports for Dremio Master Coordinator containers + ## e.g: + ## extraContainerPorts: + ## - name: myservice + ## containerPort: 9090 + ## + extraContainerPorts: [] + ## @param masterCoordinator.extraJavaOpts Add extra Java opts + ## + extraJavaOpts: "" + ## Configure extra options for Dremio Master Coordinator containers' liveness and readiness probes + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes + ## @param masterCoordinator.livenessProbe.enabled Enable livenessProbe on Dremio Master Coordinator containers + ## @param masterCoordinator.livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe + ## @param masterCoordinator.livenessProbe.periodSeconds Period seconds for livenessProbe + ## @param masterCoordinator.livenessProbe.timeoutSeconds Timeout seconds for livenessProbe + ## @param masterCoordinator.livenessProbe.failureThreshold Failure threshold for livenessProbe + ## @param masterCoordinator.livenessProbe.successThreshold Success threshold for livenessProbe + ## + livenessProbe: + enabled: true + initialDelaySeconds: 20 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param masterCoordinator.readinessProbe.enabled Enable readinessProbe on Dremio Master Coordinator containers + ## @param masterCoordinator.readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe + ## @param masterCoordinator.readinessProbe.periodSeconds Period seconds for readinessProbe + ## @param masterCoordinator.readinessProbe.timeoutSeconds Timeout seconds for readinessProbe + ## @param masterCoordinator.readinessProbe.failureThreshold Failure threshold for readinessProbe + ## @param masterCoordinator.readinessProbe.successThreshold Success threshold for readinessProbe + ## + readinessProbe: + enabled: true + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param masterCoordinator.startupProbe.enabled Enable startupProbe on Dremio Master Coordinator containers + ## @param masterCoordinator.startupProbe.initialDelaySeconds Initial delay seconds for startupProbe + ## @param masterCoordinator.startupProbe.periodSeconds Period seconds for startupProbe + ## @param masterCoordinator.startupProbe.timeoutSeconds Timeout seconds for startupProbe + ## @param masterCoordinator.startupProbe.failureThreshold Failure threshold for startupProbe + ## @param masterCoordinator.startupProbe.successThreshold Success threshold for startupProbe + ## + startupProbe: + enabled: false + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param masterCoordinator.customLivenessProbe Custom livenessProbe that overrides the default one + ## + customLivenessProbe: {} + ## @param masterCoordinator.customReadinessProbe Custom readinessProbe that overrides the default one + ## + customReadinessProbe: {} + ## @param masterCoordinator.customStartupProbe Custom startupProbe that overrides the default one + ## + customStartupProbe: {} + ## Dremio Master Coordinator resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param masterCoordinator.resourcesPreset Set Dremio Master Coordinator container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if masterCoordinator.resources is set (masterCoordinator.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "xlarge" + ## @param masterCoordinator.resources Set Dremio Master Coordinator container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Configure Pods Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param masterCoordinator.podSecurityContext.enabled Enable Dremio Master Coordinator pods' Security Context + ## @param masterCoordinator.podSecurityContext.fsGroupChangePolicy Set filesystem group change policy for Dremio Master Coordinator pods + ## @param masterCoordinator.podSecurityContext.sysctls Set kernel settings using the sysctl interface for Dremio Master Coordinator pods + ## @param masterCoordinator.podSecurityContext.supplementalGroups Set filesystem extra groups for Dremio Master Coordinator pods + ## @param masterCoordinator.podSecurityContext.fsGroup Set fsGroup in Dremio Master Coordinator pods' Security Context + ## + podSecurityContext: + enabled: true + fsGroupChangePolicy: Always + sysctls: [] + supplementalGroups: [] + fsGroup: 1001 + ## Configure Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param masterCoordinator.containerSecurityContext.enabled Enabled Dremio Master Coordinator container' Security Context + ## @param masterCoordinator.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Dremio Master Coordinator container + ## @param masterCoordinator.containerSecurityContext.runAsUser Set runAsUser in Dremio Master Coordinator container' Security Context + ## @param masterCoordinator.containerSecurityContext.runAsGroup Set runAsGroup in Dremio Master Coordinator container' Security Context + ## @param masterCoordinator.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Dremio Master Coordinator container' Security Context + ## @param masterCoordinator.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Dremio Master Coordinator container' Security Context + ## @param masterCoordinator.containerSecurityContext.privileged Set privileged in Dremio Master Coordinator container' Security Context + ## @param masterCoordinator.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Dremio Master Coordinator container' Security Context + ## @param masterCoordinator.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Dremio Master Coordinator container + ## @param masterCoordinator.containerSecurityContext.seccompProfile.type Set seccomp profile in Dremio Master Coordinator container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + + ## @param masterCoordinator.command Override default Dremio Master Coordinator container command (useful when using custom images) + ## + command: [] + ## @param masterCoordinator.args Override default Dremio Master Coordinator container args (useful when using custom images) + ## + args: [] + ## @param masterCoordinator.automountServiceAccountToken Mount Service Account token in Dremio Master Coordinator pods + ## + automountServiceAccountToken: false + ## @param masterCoordinator.hostAliases Dremio Master Coordinator pods host aliases + ## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ + ## + hostAliases: [] + ## @param masterCoordinator.statefulsetAnnotations Annotations for Dremio Master Coordinator statefulset + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + statefulsetAnnotations: {} + ## @param masterCoordinator.podLabels Extra labels for Dremio Master Coordinator pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + ## + podLabels: {} + ## @param masterCoordinator.podAnnotations Annotations for Dremio Master Coordinator pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + podAnnotations: {} + ## @param masterCoordinator.podAffinityPreset Pod affinity preset. Ignored if `masterCoordinator.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAffinityPreset: "" + ## @param masterCoordinator.podAntiAffinityPreset Pod anti-affinity preset. Ignored if `masterCoordinator.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAntiAffinityPreset: soft + ## @param masterCoordinator.dremioConf.configOverrides Add configuration overrides in dremio.conf applied to all master-coordinator nodes (using YAML format) + ## @param masterCoordinator.dremioConf.secretConfigOverrides Add sensitive configuration overrides in dremio.conf applied to master-coordinator nodes (using YAML format) + ## @param masterCoordinator.dremioConf.extraFiles Add extra files to the ConfigMap + ## @param masterCoordinator.dremioConf.extraSecretFiles Add extra files to the Secret + ## @param masterCoordinator.dremioConf.existingConfigmap Name of a configmap containing a dremio.conf configuration file for the master-coordinator nodes (without sensitive information) + ## @param masterCoordinator.dremioConf.existingSecret Name of a secret containing a dremio.conf configuration file for the master-coordinator nodes (with sensitive information) + dremioConf: + configOverrides: {} + secretConfigOverrides: {} + extraFiles: {} + extraSecretFiles: {} + existingConfigmap: "" + existingSecret: "" + ## Node masterCoordinator.affinity preset + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity + ## + nodeAffinityPreset: + ## @param masterCoordinator.nodeAffinityPreset.type Node affinity preset type. Ignored if `masterCoordinator.affinity` is set. Allowed values: `soft` or `hard` + ## + type: "" + ## @param masterCoordinator.nodeAffinityPreset.key Node label key to match. Ignored if `masterCoordinator.affinity` is set + ## + key: "" + ## @param masterCoordinator.nodeAffinityPreset.values Node label values to match. Ignored if `masterCoordinator.affinity` is set + ## E.g. + ## values: + ## - e2e-az1 + ## - e2e-az2 + ## + values: [] + ## @param masterCoordinator.affinity Affinity for Dremio Master Coordinator pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity + ## NOTE: `masterCoordinator.podAffinityPreset`, `masterCoordinator.podAntiAffinityPreset`, and `masterCoordinator.nodeAffinityPreset` will be ignored when it's set + ## + affinity: {} + ## @param masterCoordinator.nodeSelector Node labels for Dremio Master Coordinator pods assignment + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/ + ## + nodeSelector: {} + ## @param masterCoordinator.tolerations Tolerations for Dremio Master Coordinator pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ + ## + tolerations: [] + ## @param masterCoordinator.updateStrategy.type Dremio Master Coordinator statefulset strategy type + ## ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#update-strategies + ## + updateStrategy: + ## Can be set to RollingUpdate or OnDelete + ## + type: RollingUpdate + ## @param masterCoordinator.podManagementPolicy Pod management policy for Dremio Master Coordinator statefulset + ## Ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#pod-management-policies + ## + podManagementPolicy: OrderedReady + ## @param masterCoordinator.priorityClassName Dremio Master Coordinator pods' priorityClassName + ## + priorityClassName: "" + ## @param masterCoordinator.topologySpreadConstraints Topology Spread Constraints for Dremio Master Coordinator pod assignment spread across your cluster among failure-domains + ## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/#spread-constraints-for-pods + ## + topologySpreadConstraints: [] + ## @param masterCoordinator.schedulerName Name of the k8s scheduler (other than default) for Dremio Master Coordinator pods + ## ref: https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/ + ## + schedulerName: "" + ## @param masterCoordinator.terminationGracePeriodSeconds Seconds Dremio Master Coordinator pods need to terminate gracefully + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/pod/#termination-of-pods + ## + terminationGracePeriodSeconds: "" + ## @param masterCoordinator.lifecycleHooks for Dremio Master Coordinator containers to automate configuration before or after startup + ## + lifecycleHooks: {} + ## @param masterCoordinator.extraEnvVars Array with extra environment variables to add to Dremio Master Coordinator containers + ## e.g: + ## extraEnvVars: + ## - name: FOO + ## value: "bar" + ## + extraEnvVars: [] + ## @param masterCoordinator.extraEnvVarsCM Name of existing ConfigMap containing extra env vars for Dremio Master Coordinator containers + ## + extraEnvVarsCM: "" + ## @param masterCoordinator.extraEnvVarsSecret Name of existing Secret containing extra env vars for Dremio Master Coordinator containers + ## + extraEnvVarsSecret: "" + ## @param masterCoordinator.extraVolumes Optionally specify extra list of additional volumes for the Dremio Master Coordinator pods + ## + extraVolumes: [] + ## @param masterCoordinator.extraVolumeMounts Optionally specify extra list of additional volumeMounts for the Dremio Master Coordinator containers + ## + extraVolumeMounts: [] + ## @param masterCoordinator.sidecars Add additional sidecar containers to the Dremio Master Coordinator pods + ## e.g: + ## sidecars: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## ports: + ## - name: portname + ## containerPort: 1234 + ## + sidecars: [] + ## @param masterCoordinator.initContainers Add additional init containers to the Dremio Master Coordinator pods + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ + ## e.g: + ## initContainers: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## command: ['sh', '-c', 'echo "hello world"'] + ## + initContainers: [] + ## Pod Disruption Budget configuration + ## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb + ## @param masterCoordinator.pdb.create Enable/disable a Pod Disruption Budget creation + ## @param masterCoordinator.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled + ## @param masterCoordinator.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `masterCoordinator.pdb.minAvailable` and `masterCoordinator.pdb.maxUnavailable` are empty. + ## + pdb: + create: true + minAvailable: "" + maxUnavailable: "" + ## Autoscaling configuration + ## ref: https://kubernetes.io/docs/concepts/workloads/autoscaling/ + ## + autoscaling: + ## @param masterCoordinator.autoscaling.vpa.enabled Enable VPA for Dremio Master Coordinator pods + ## @param masterCoordinator.autoscaling.vpa.annotations Annotations for VPA resource + ## @param masterCoordinator.autoscaling.vpa.controlledResources VPA List of resources that the vertical pod autoscaler can control. Defaults to cpu and memory + ## @param masterCoordinator.autoscaling.vpa.maxAllowed VPA Max allowed resources for the pod + ## @param masterCoordinator.autoscaling.vpa.minAllowed VPA Min allowed resources for the pod + ## + vpa: + enabled: false + annotations: {} + controlledResources: [] + maxAllowed: {} + minAllowed: {} + ## @param masterCoordinator.autoscaling.vpa.updatePolicy.updateMode Autoscaling update policy + ## Specifies whether recommended updates are applied when a Pod is started and whether recommended updates are applied during the life of a Pod + ## Possible values are "Off", "Initial", "Recreate", and "Auto". + ## + updatePolicy: + updateMode: Auto + ## @param masterCoordinator.autoscaling.hpa.enabled Enable HPA for Dremio Master Coordinator pods + ## @param masterCoordinator.autoscaling.hpa.minReplicas Minimum number of replicas + ## @param masterCoordinator.autoscaling.hpa.maxReplicas Maximum number of replicas + ## @param masterCoordinator.autoscaling.hpa.targetCPU Target CPU utilization percentage + ## @param masterCoordinator.autoscaling.hpa.targetMemory Target Memory utilization percentage + ## + hpa: + enabled: false + minReplicas: "" + maxReplicas: "" + targetCPU: "" + targetMemory: "" + + ## Network Policies + ## Ref: https://kubernetes.io/docs/concepts/services-networking/network-policies/ + ## + networkPolicy: + ## @param masterCoordinator.networkPolicy.enabled Specifies whether a NetworkPolicy should be created + ## + enabled: true + ## @param masterCoordinator.networkPolicy.allowExternal Don't require server label for connections + ## The Policy model to apply. When set to false, only pods with the correct + ## server label will have network access to the ports server is listening + ## on. When true, server will accept connections from any source + ## (with the correct destination port). + ## + allowExternal: true + ## @param masterCoordinator.networkPolicy.allowExternalEgress Allow the pod to access any range of port and all destinations. + ## + allowExternalEgress: true + ## @param masterCoordinator.networkPolicy.addExternalClientAccess Allow access from pods with client label set to "true". Ignored if `networkPolicy.allowExternal` is true. + ## + addExternalClientAccess: true + ## @param masterCoordinator.networkPolicy.extraIngress [array] Add extra ingress rules to the NetworkPolicy + ## e.g: + ## extraIngress: + ## - ports: + ## - port: 1234 + ## from: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + extraIngress: [] + ## @param masterCoordinator.networkPolicy.extraEgress [array] Add extra ingress rules to the NetworkPolicy (ignored if allowExternalEgress=true) + ## e.g: + ## extraEgress: + ## - ports: + ## - port: 1234 + ## to: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + ## + extraEgress: [] + ## @param masterCoordinator.networkPolicy.ingressPodMatchLabels [object] Labels to match to allow traffic from other pods. Ignored if `networkPolicy.allowExternal` is true. + ## e.g: + ## ingressPodMatchLabels: + ## my-client: "true" + # + ingressPodMatchLabels: {} + ## @param masterCoordinator.networkPolicy.ingressNSMatchLabels [object] Labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. + ## @param masterCoordinator.networkPolicy.ingressNSPodMatchLabels [object] Pod labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. + ## + ingressNSMatchLabels: {} + ingressNSPodMatchLabels: {} + ## Enable persistence using Persistent Volume Claims + ## ref: https://kubernetes.io/docs/concepts/storage/persistent-volumes/ + ## + persistence: + ## @param masterCoordinator.persistence.enabled Enable persistence using Persistent Volume Claims + ## + enabled: true + ## @param masterCoordinator.persistence.mountPath Path to mount the volume at. + ## + mountPath: /bitnami/dremio/data + ## @param masterCoordinator.persistence.subPath The subdirectory of the volume to mount to, useful in dev environments and one PV for multiple services + ## + subPath: "" + ## @param masterCoordinator.persistence.storageClass Storage class of backing PVC + ## If defined, storageClassName: + ## If set to "-", storageClassName: "", which disables dynamic provisioning + ## If undefined (the default) or set to null, no storageClassName spec is + ## set, choosing the default provisioner. (gp2 on AWS, standard on + ## GKE, AWS & OpenStack) + ## + storageClass: "" + ## @param masterCoordinator.persistence.annotations Persistent Volume Claim annotations + ## + annotations: {} + ## @param masterCoordinator.persistence.accessModes Persistent Volume Access Modes + ## + accessModes: + - ReadWriteOnce + ## @param masterCoordinator.persistence.size Size of data volume + ## + size: 8Gi + ## @param masterCoordinator.persistence.existingClaim The name of an existing PVC to use for persistence + ## + existingClaim: "" + ## @param masterCoordinator.persistence.selector Selector to match an existing Persistent Volume for WordPress data PVC + ## If set, the PVC can't have a PV dynamically provisioned for it + ## E.g. + ## selector: + ## matchLabels: + ## app: my-app + ## + selector: {} + ## @param masterCoordinator.persistence.dataSource Custom PVC data source + ## + dataSource: {} + ## ServiceAccount configuration + ## + serviceAccount: + ## @param masterCoordinator.serviceAccount.create Specifies whether a ServiceAccount should be created + ## + create: true + ## @param masterCoordinator.serviceAccount.name The name of the ServiceAccount to use. + ## If not set and create is true, a name is generated using the common.names.fullname template + ## + name: "" + ## @param masterCoordinator.serviceAccount.annotations Additional Service Account annotations (evaluated as a template) + ## + annotations: {} + ## @param masterCoordinator.serviceAccount.automountServiceAccountToken Automount service account token for the server service account + ## + automountServiceAccountToken: false + +## @section Dremio Coordinator Parameters +## +## +coordinator: + ## @param coordinator.replicaCount Number of Dremio Coordinator replicas to deploy + ## + replicaCount: 1 + ## @param coordinator.extraContainerPorts Optionally specify extra list of additional ports for Dremio Coordinator containers + ## e.g: + ## extraContainerPorts: + ## - name: myservice + ## containerPort: 9090 + ## + extraContainerPorts: [] + ## @param coordinator.extraJavaOpts Add extra Java opts + ## + extraJavaOpts: "" + ## Configure extra options for Dremio Coordinator containers' liveness and readiness probes + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes + ## @param coordinator.livenessProbe.enabled Enable livenessProbe on Dremio Coordinator containers + ## @param coordinator.livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe + ## @param coordinator.livenessProbe.periodSeconds Period seconds for livenessProbe + ## @param coordinator.livenessProbe.timeoutSeconds Timeout seconds for livenessProbe + ## @param coordinator.livenessProbe.failureThreshold Failure threshold for livenessProbe + ## @param coordinator.livenessProbe.successThreshold Success threshold for livenessProbe + ## + livenessProbe: + enabled: true + initialDelaySeconds: 20 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param coordinator.readinessProbe.enabled Enable readinessProbe on Dremio Coordinator containers + ## @param coordinator.readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe + ## @param coordinator.readinessProbe.periodSeconds Period seconds for readinessProbe + ## @param coordinator.readinessProbe.timeoutSeconds Timeout seconds for readinessProbe + ## @param coordinator.readinessProbe.failureThreshold Failure threshold for readinessProbe + ## @param coordinator.readinessProbe.successThreshold Success threshold for readinessProbe + ## + readinessProbe: + enabled: true + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param coordinator.startupProbe.enabled Enable startupProbe on Dremio Coordinator containers + ## @param coordinator.startupProbe.initialDelaySeconds Initial delay seconds for startupProbe + ## @param coordinator.startupProbe.periodSeconds Period seconds for startupProbe + ## @param coordinator.startupProbe.timeoutSeconds Timeout seconds for startupProbe + ## @param coordinator.startupProbe.failureThreshold Failure threshold for startupProbe + ## @param coordinator.startupProbe.successThreshold Success threshold for startupProbe + ## + startupProbe: + enabled: false + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param coordinator.customLivenessProbe Custom livenessProbe that overrides the default one + ## + customLivenessProbe: {} + ## @param coordinator.customReadinessProbe Custom readinessProbe that overrides the default one + ## + customReadinessProbe: {} + ## @param coordinator.customStartupProbe Custom startupProbe that overrides the default one + ## + customStartupProbe: {} + ## Dremio Coordinator resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param coordinator.resourcesPreset Set Dremio Coordinator container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if coordinator.resources is set (coordinator.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "xlarge" + ## @param coordinator.resources Set Dremio Coordinator container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Configure Pods Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param coordinator.podSecurityContext.enabled Enable Dremio Coordinator pods' Security Context + ## @param coordinator.podSecurityContext.fsGroupChangePolicy Set filesystem group change policy for Dremio Coordinator pods + ## @param coordinator.podSecurityContext.sysctls Set kernel settings using the sysctl interface for Dremio Coordinator pods + ## @param coordinator.podSecurityContext.supplementalGroups Set filesystem extra groups for Dremio Coordinator pods + ## @param coordinator.podSecurityContext.fsGroup Set fsGroup in Dremio Coordinator pods' Security Context + ## + podSecurityContext: + enabled: true + fsGroupChangePolicy: Always + sysctls: [] + supplementalGroups: [] + fsGroup: 1001 + ## Configure Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param coordinator.containerSecurityContext.enabled Enabled Dremio Coordinator container' Security Context + ## @param coordinator.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Dremio Coordinator container + ## @param coordinator.containerSecurityContext.runAsUser Set runAsUser in Dremio Coordinator container' Security Context + ## @param coordinator.containerSecurityContext.runAsGroup Set runAsGroup in Dremio Coordinator container' Security Context + ## @param coordinator.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Dremio Coordinator container' Security Context + ## @param coordinator.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Dremio Coordinator container' Security Context + ## @param coordinator.containerSecurityContext.privileged Set privileged in Dremio Coordinator container' Security Context + ## @param coordinator.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Dremio Coordinator container' Security Context + ## @param coordinator.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Dremio Coordinator container + ## @param coordinator.containerSecurityContext.seccompProfile.type Set seccomp profile in Dremio Coordinator container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + + ## @param coordinator.command Override default Dremio Coordinator container command (useful when using custom images) + ## + command: [] + ## @param coordinator.args Override default Dremio Coordinator container args (useful when using custom images) + ## + args: [] + ## @param coordinator.automountServiceAccountToken Mount Service Account token in Dremio Coordinator pods + ## + automountServiceAccountToken: false + ## @param coordinator.hostAliases Dremio Coordinator pods host aliases + ## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ + ## + hostAliases: [] + ## @param coordinator.statefulsetAnnotations Annotations for Dremio Coordinator statefulset + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + statefulsetAnnotations: {} + ## @param coordinator.podLabels Extra labels for Dremio Coordinator pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + ## + podLabels: {} + ## @param coordinator.podAnnotations Annotations for Dremio Coordinator pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + podAnnotations: {} + ## @param coordinator.podAffinityPreset Pod affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAffinityPreset: "" + ## @param coordinator.podAntiAffinityPreset Pod anti-affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAntiAffinityPreset: soft + ## @param coordinator.dremioConf.configOverrides Add configuration overrides in dremio.conf applied to all coordinator nodes (using YAML format) + ## @param coordinator.dremioConf.secretConfigOverrides Add sensitive configuration overrides in dremio.conf applied to coordinator nodes (using YAML format) + ## @param coordinator.dremioConf.extraFiles Add extra files to the ConfigMap + ## @param coordinator.dremioConf.extraSecretFiles Add extra files to the Secret + ## @param coordinator.dremioConf.existingConfigmap Name of a configmap containing a dremio.conf configuration file for the coordinator nodes (without sensitive information) + ## @param coordinator.dremioConf.existingSecret Name of a secret containing a dremio.conf configuration file for the coordinator nodes (with sensitive information) + dremioConf: + configOverrides: {} + secretConfigOverrides: {} + extraFiles: {} + extraSecretFiles: {} + existingConfigmap: "" + existingSecret: "" + ## Node coordinator.affinity preset + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity + ## + nodeAffinityPreset: + ## @param coordinator.nodeAffinityPreset.type Node affinity preset type. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` + ## + type: "" + ## @param coordinator.nodeAffinityPreset.key Node label key to match. Ignored if `coordinator.affinity` is set + ## + key: "" + ## @param coordinator.nodeAffinityPreset.values Node label values to match. Ignored if `coordinator.affinity` is set + ## E.g. + ## values: + ## - e2e-az1 + ## - e2e-az2 + ## + values: [] + ## @param coordinator.affinity Affinity for Dremio Coordinator pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity + ## NOTE: `coordinator.podAffinityPreset`, `coordinator.podAntiAffinityPreset`, and `coordinator.nodeAffinityPreset` will be ignored when it's set + ## + affinity: {} + ## @param coordinator.nodeSelector Node labels for Dremio Coordinator pods assignment + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/ + ## + nodeSelector: {} + ## @param coordinator.tolerations Tolerations for Dremio Coordinator pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ + ## + tolerations: [] + ## @param coordinator.updateStrategy.type Dremio Coordinator statefulset strategy type + ## ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#update-strategies + ## + updateStrategy: + ## Can be set to RollingUpdate or OnDelete + ## + type: RollingUpdate + ## @param coordinator.podManagementPolicy Pod management policy for Dremio Coordinator statefulset + ## Ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#pod-management-policies + ## + podManagementPolicy: OrderedReady + ## @param coordinator.priorityClassName Dremio Coordinator pods' priorityClassName + ## + priorityClassName: "" + ## @param coordinator.topologySpreadConstraints Topology Spread Constraints for Dremio Coordinator pod assignment spread across your cluster among failure-domains + ## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/#spread-constraints-for-pods + ## + topologySpreadConstraints: [] + ## @param coordinator.schedulerName Name of the k8s scheduler (other than default) for Dremio Coordinator pods + ## ref: https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/ + ## + schedulerName: "" + ## @param coordinator.terminationGracePeriodSeconds Seconds Dremio Coordinator pods need to terminate gracefully + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/pod/#termination-of-pods + ## + terminationGracePeriodSeconds: "" + ## @param coordinator.lifecycleHooks for Dremio Coordinator containers to automate configuration before or after startup + ## + lifecycleHooks: {} + ## @param coordinator.extraEnvVars Array with extra environment variables to add to Dremio Coordinator containers + ## e.g: + ## extraEnvVars: + ## - name: FOO + ## value: "bar" + ## + extraEnvVars: [] + ## @param coordinator.extraEnvVarsCM Name of existing ConfigMap containing extra env vars for Dremio Coordinator containers + ## + extraEnvVarsCM: "" + ## @param coordinator.extraEnvVarsSecret Name of existing Secret containing extra env vars for Dremio Coordinator containers + ## + extraEnvVarsSecret: "" + ## @param coordinator.extraVolumes Optionally specify extra list of additional volumes for the Dremio Coordinator pods + ## + extraVolumes: [] + ## @param coordinator.extraVolumeMounts Optionally specify extra list of additional volumeMounts for the Dremio Coordinator containers + ## + extraVolumeMounts: [] + ## @param coordinator.sidecars Add additional sidecar containers to the Dremio Coordinator pods + ## e.g: + ## sidecars: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## ports: + ## - name: portname + ## containerPort: 1234 + ## + sidecars: [] + ## @param coordinator.initContainers Add additional init containers to the Dremio Coordinator pods + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ + ## e.g: + ## initContainers: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## command: ['sh', '-c', 'echo "hello world"'] + ## + initContainers: [] + ## Pod Disruption Budget configuration + ## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb + ## @param coordinator.pdb.create Enable/disable a Pod Disruption Budget creation + ## @param coordinator.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled + ## @param coordinator.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `coordinator.pdb.minAvailable` and `coordinator.pdb.maxUnavailable` are empty. + ## + pdb: + create: true + minAvailable: "" + maxUnavailable: "" + ## Autoscaling configuration + ## ref: https://kubernetes.io/docs/concepts/workloads/autoscaling/ + ## + autoscaling: + ## @param coordinator.autoscaling.vpa.enabled Enable VPA for Dremio Coordinator pods + ## @param coordinator.autoscaling.vpa.annotations Annotations for VPA resource + ## @param coordinator.autoscaling.vpa.controlledResources VPA List of resources that the vertical pod autoscaler can control. Defaults to cpu and memory + ## @param coordinator.autoscaling.vpa.maxAllowed VPA Max allowed resources for the pod + ## @param coordinator.autoscaling.vpa.minAllowed VPA Min allowed resources for the pod + ## + vpa: + enabled: false + annotations: {} + controlledResources: [] + maxAllowed: {} + minAllowed: {} + ## @param coordinator.autoscaling.vpa.updatePolicy.updateMode Autoscaling update policy + ## Specifies whether recommended updates are applied when a Pod is started and whether recommended updates are applied during the life of a Pod + ## Possible values are "Off", "Initial", "Recreate", and "Auto". + ## + updatePolicy: + updateMode: Auto + ## @param coordinator.autoscaling.hpa.enabled Enable HPA for Dremio Coordinator pods + ## @param coordinator.autoscaling.hpa.minReplicas Minimum number of replicas + ## @param coordinator.autoscaling.hpa.maxReplicas Maximum number of replicas + ## @param coordinator.autoscaling.hpa.targetCPU Target CPU utilization percentage + ## @param coordinator.autoscaling.hpa.targetMemory Target Memory utilization percentage + ## + hpa: + enabled: false + minReplicas: "" + maxReplicas: "" + targetCPU: "" + targetMemory: "" + + ## Network Policies + ## Ref: https://kubernetes.io/docs/concepts/services-networking/network-policies/ + ## + networkPolicy: + ## @param coordinator.networkPolicy.enabled Specifies whether a NetworkPolicy should be created + ## + enabled: true + ## @param coordinator.networkPolicy.allowExternal Don't require server label for connections + ## The Policy model to apply. When set to false, only pods with the correct + ## server label will have network access to the ports server is listening + ## on. When true, server will accept connections from any source + ## (with the correct destination port). + ## + allowExternal: true + ## @param coordinator.networkPolicy.allowExternalEgress Allow the pod to access any range of port and all destinations. + ## + allowExternalEgress: true + ## @param coordinator.networkPolicy.addExternalClientAccess Allow access from pods with client label set to "true". Ignored if `networkPolicy.allowExternal` is true. + ## + addExternalClientAccess: true + ## @param coordinator.networkPolicy.extraIngress [array] Add extra ingress rules to the NetworkPolicy + ## e.g: + ## extraIngress: + ## - ports: + ## - port: 1234 + ## from: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + extraIngress: [] + ## @param coordinator.networkPolicy.extraEgress [array] Add extra ingress rules to the NetworkPolicy (ignored if allowExternalEgress=true) + ## e.g: + ## extraEgress: + ## - ports: + ## - port: 1234 + ## to: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + ## + extraEgress: [] + ## @param coordinator.networkPolicy.ingressPodMatchLabels [object] Labels to match to allow traffic from other pods. Ignored if `networkPolicy.allowExternal` is true. + ## e.g: + ## ingressPodMatchLabels: + ## my-client: "true" + # + ingressPodMatchLabels: {} + ## @param coordinator.networkPolicy.ingressNSMatchLabels [object] Labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. + ## @param coordinator.networkPolicy.ingressNSPodMatchLabels [object] Pod labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. + ## + ingressNSMatchLabels: {} + ingressNSPodMatchLabels: {} + ## Enable persistence using Persistent Volume Claims + ## ref: https://kubernetes.io/docs/concepts/storage/persistent-volumes/ + ## + persistence: + ## @param coordinator.persistence.enabled Enable persistence using Persistent Volume Claims + ## + enabled: true + ## @param coordinator.persistence.mountPath Path to mount the volume at. + ## + mountPath: /bitnami/dremio/data + ## @param coordinator.persistence.subPath The subdirectory of the volume to mount to, useful in dev environments and one PV for multiple services + ## + subPath: "" + ## @param coordinator.persistence.storageClass Storage class of backing PVC + ## If defined, storageClassName: + ## If set to "-", storageClassName: "", which disables dynamic provisioning + ## If undefined (the default) or set to null, no storageClassName spec is + ## set, choosing the default provisioner. (gp2 on AWS, standard on + ## GKE, AWS & OpenStack) + ## + storageClass: "" + ## @param coordinator.persistence.annotations Persistent Volume Claim annotations + ## + annotations: {} + ## @param coordinator.persistence.accessModes Persistent Volume Access Modes + ## + accessModes: + - ReadWriteOnce + ## @param coordinator.persistence.size Size of data volume + ## + size: 8Gi + ## @param coordinator.persistence.existingClaim The name of an existing PVC to use for persistence + ## + existingClaim: "" + ## @param coordinator.persistence.selector Selector to match an existing Persistent Volume for WordPress data PVC + ## If set, the PVC can't have a PV dynamically provisioned for it + ## E.g. + ## selector: + ## matchLabels: + ## app: my-app + ## + selector: {} + ## @param coordinator.persistence.dataSource Custom PVC data source + ## + dataSource: {} + ## ServiceAccount configuration + ## + serviceAccount: + ## @param coordinator.serviceAccount.create Specifies whether a ServiceAccount should be created + ## + create: true + ## @param coordinator.serviceAccount.name The name of the ServiceAccount to use. + ## If not set and create is true, a name is generated using the common.names.fullname template + ## + name: "" + ## @param coordinator.serviceAccount.annotations Additional Service Account annotations (evaluated as a template) + ## + annotations: {} + ## @param coordinator.serviceAccount.automountServiceAccountToken Automount service account token for the server service account + ## + automountServiceAccountToken: false + +executor: + ## @section Dremio Executor common Parameters + ## + ## + common: + ## @param executor.common.replicaCount Number of Dremio Executor replicas to deploy + ## + replicaCount: 1 + ## @param executor.common.extraContainerPorts Optionally specify extra list of additional ports for Dremio Executor containers + ## e.g: + ## extraContainerPorts: + ## - name: myservice + ## containerPort: 9090 + ## + extraContainerPorts: [] + ## @param executor.common.extraJavaOpts Add extra Java opts + ## + extraJavaOpts: "" + ## Configure extra options for Dremio Executor containers' liveness and readiness probes + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes + ## @param executor.common.livenessProbe.enabled Enable livenessProbe on Dremio Executor containers + ## @param executor.common.livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe + ## @param executor.common.livenessProbe.periodSeconds Period seconds for livenessProbe + ## @param executor.common.livenessProbe.timeoutSeconds Timeout seconds for livenessProbe + ## @param executor.common.livenessProbe.failureThreshold Failure threshold for livenessProbe + ## @param executor.common.livenessProbe.successThreshold Success threshold for livenessProbe + ## + livenessProbe: + enabled: true + initialDelaySeconds: 20 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param executor.common.readinessProbe.enabled Enable readinessProbe on Dremio Executor containers + ## @param executor.common.readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe + ## @param executor.common.readinessProbe.periodSeconds Period seconds for readinessProbe + ## @param executor.common.readinessProbe.timeoutSeconds Timeout seconds for readinessProbe + ## @param executor.common.readinessProbe.failureThreshold Failure threshold for readinessProbe + ## @param executor.common.readinessProbe.successThreshold Success threshold for readinessProbe + ## + readinessProbe: + enabled: true + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param executor.common.startupProbe.enabled Enable startupProbe on Dremio Executor containers + ## @param executor.common.startupProbe.initialDelaySeconds Initial delay seconds for startupProbe + ## @param executor.common.startupProbe.periodSeconds Period seconds for startupProbe + ## @param executor.common.startupProbe.timeoutSeconds Timeout seconds for startupProbe + ## @param executor.common.startupProbe.failureThreshold Failure threshold for startupProbe + ## @param executor.common.startupProbe.successThreshold Success threshold for startupProbe + ## + startupProbe: + enabled: false + initialDelaySeconds: 10 + periodSeconds: 10 + timeoutSeconds: 5 + successThreshold: 1 + failureThreshold: 5 + ## @param executor.common.customLivenessProbe Custom livenessProbe that overrides the default one + ## + customLivenessProbe: {} + ## @param executor.common.customReadinessProbe Custom readinessProbe that overrides the default one + ## + customReadinessProbe: {} + ## @param executor.common.customStartupProbe Custom startupProbe that overrides the default one + ## + customStartupProbe: {} + ## Dremio Executor resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param executor.common.resourcesPreset Set Dremio Executor container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if coordinator.resources is set (coordinator.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "xlarge" + ## @param executor.common.resources Set Dremio Executor container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Configure Pods Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param executor.common.podSecurityContext.enabled Enable Dremio Executor pods' Security Context + ## @param executor.common.podSecurityContext.fsGroupChangePolicy Set filesystem group change policy for Dremio Executor pods + ## @param executor.common.podSecurityContext.sysctls Set kernel settings using the sysctl interface for Dremio Executor pods + ## @param executor.common.podSecurityContext.supplementalGroups Set filesystem extra groups for Dremio Executor pods + ## @param executor.common.podSecurityContext.fsGroup Set fsGroup in Dremio Executor pods' Security Context + ## + podSecurityContext: + enabled: true + fsGroupChangePolicy: Always + sysctls: [] + supplementalGroups: [] + fsGroup: 1001 + ## Configure Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param executor.common.containerSecurityContext.enabled Enabled Dremio Executor container' Security Context + ## @param executor.common.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Dremio Executor container + ## @param executor.common.containerSecurityContext.runAsUser Set runAsUser in Dremio Executor container' Security Context + ## @param executor.common.containerSecurityContext.runAsGroup Set runAsGroup in Dremio Executor container' Security Context + ## @param executor.common.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Dremio Executor container' Security Context + ## @param executor.common.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Dremio Executor container' Security Context + ## @param executor.common.containerSecurityContext.privileged Set privileged in Dremio Executor container' Security Context + ## @param executor.common.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Dremio Executor container' Security Context + ## @param executor.common.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Dremio Executor container + ## @param executor.common.containerSecurityContext.seccompProfile.type Set seccomp profile in Dremio Executor container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + + ## @param executor.common.command Override default Dremio Executor container command (useful when using custom images) + ## + command: [] + ## @param executor.common.args Override default Dremio Executor container args (useful when using custom images) + ## + args: [] + ## @param executor.common.automountServiceAccountToken Mount Service Account token in Dremio Executor pods + ## + automountServiceAccountToken: false + ## @param executor.common.hostAliases Dremio Executor pods host aliases + ## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ + ## + hostAliases: [] + ## @param executor.common.statefulsetAnnotations Annotations for Dremio Executor statefulset + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + statefulsetAnnotations: {} + ## @param executor.common.podLabels Extra labels for Dremio Executor pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + ## + podLabels: {} + ## @param executor.common.podAnnotations Annotations for Dremio Executor pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + podAnnotations: {} + ## @param executor.common.podAffinityPreset Pod affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAffinityPreset: "" + ## @param executor.common.podAntiAffinityPreset Pod anti-affinity preset. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAntiAffinityPreset: soft + ## @param executor.common.dremioConf.configOverrides Add configuration overrides in dremio.conf applied to all executor nodes (using YAML format) + ## @param executor.common.dremioConf.secretConfigOverrides Add sensitive configuration overrides in dremio.conf applied to executor nodes (using YAML format) + ## @param executor.common.dremioConf.extraFiles Add extra files to the ConfigMap + ## @param executor.common.dremioConf.extraSecretFiles Add extra files to the Secret + ## @param executor.common.dremioConf.existingConfigmap Name of a configmap containing a dremio.conf configuration file for the executor nodes (without sensitive information) + ## @param executor.common.dremioConf.existingSecret Name of a secret containing a dremio.conf configuration file for the executor nodes (with sensitive information) + dremioConf: + configOverrides: {} + secretConfigOverrides: {} + extraFiles: {} + extraSecretFiles: {} + existingConfigmap: "" + existingSecret: "" + ## Node coordinator.affinity preset + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity + ## + nodeAffinityPreset: + ## @param executor.common.nodeAffinityPreset.type Node affinity preset type. Ignored if `coordinator.affinity` is set. Allowed values: `soft` or `hard` + ## + type: "" + ## @param executor.common.nodeAffinityPreset.key Node label key to match. Ignored if `coordinator.affinity` is set + ## + key: "" + ## @param executor.common.nodeAffinityPreset.values Node label values to match. Ignored if `coordinator.affinity` is set + ## E.g. + ## values: + ## - e2e-az1 + ## - e2e-az2 + ## + values: [] + ## @param executor.common.affinity Affinity for Dremio Executor pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity + ## NOTE: `coordinator.podAffinityPreset`, `coordinator.podAntiAffinityPreset`, and `coordinator.nodeAffinityPreset` will be ignored when it's set + ## + affinity: {} + ## @param executor.common.nodeSelector Node labels for Dremio Executor pods assignment + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/ + ## + nodeSelector: {} + ## @param executor.common.tolerations Tolerations for Dremio Executor pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ + ## + tolerations: [] + ## @param executor.common.updateStrategy.type Dremio Executor statefulset strategy type + ## ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#update-strategies + ## + updateStrategy: + ## Can be set to RollingUpdate or OnDelete + ## + type: RollingUpdate + ## @param executor.common.podManagementPolicy Pod management policy for Dremio Executor statefulset + ## Ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#pod-management-policies + ## + podManagementPolicy: OrderedReady + ## @param executor.common.priorityClassName Dremio Executor pods' priorityClassName + ## + priorityClassName: "" + ## @param executor.common.topologySpreadConstraints Topology Spread Constraints for Dremio Executor pod assignment spread across your cluster among failure-domains + ## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/#spread-constraints-for-pods + ## + topologySpreadConstraints: [] + ## @param executor.common.schedulerName Name of the k8s scheduler (other than default) for Dremio Executor pods + ## ref: https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/ + ## + schedulerName: "" + ## @param executor.common.terminationGracePeriodSeconds Seconds Dremio Executor pods need to terminate gracefully + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/pod/#termination-of-pods + ## + terminationGracePeriodSeconds: "" + ## @param executor.common.lifecycleHooks for Dremio Executor containers to automate configuration before or after startup + ## + lifecycleHooks: {} + ## @param executor.common.extraEnvVars Array with extra environment variables to add to Dremio Executor containers + ## e.g: + ## extraEnvVars: + ## - name: FOO + ## value: "bar" + ## + extraEnvVars: [] + ## @param executor.common.extraEnvVarsCM Name of existing ConfigMap containing extra env vars for Dremio Executor containers + ## + extraEnvVarsCM: "" + ## @param executor.common.extraEnvVarsSecret Name of existing Secret containing extra env vars for Dremio Executor containers + ## + extraEnvVarsSecret: "" + ## @param executor.common.extraVolumes Optionally specify extra list of additional volumes for the Dremio Executor pods + ## + extraVolumes: [] + ## @param executor.common.extraVolumeMounts Optionally specify extra list of additional volumeMounts for the Dremio Executor containers + ## + extraVolumeMounts: [] + ## @param executor.common.sidecars Add additional sidecar containers to the Dremio Executor pods + ## e.g: + ## sidecars: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## ports: + ## - name: portname + ## containerPort: 1234 + ## + sidecars: [] + ## @param executor.common.initContainers Add additional init containers to the Dremio Executor pods + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ + ## e.g: + ## initContainers: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## command: ['sh', '-c', 'echo "hello world"'] + ## + initContainers: [] + ## Pod Disruption Budget configuration + ## ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb + ## @param executor.common.pdb.create Enable/disable a Pod Disruption Budget creation + ## @param executor.common.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled + ## @param executor.common.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable. Defaults to `1` if both `coordinator.pdb.minAvailable` and `coordinator.pdb.maxUnavailable` are empty. + ## + pdb: + create: true + minAvailable: "" + maxUnavailable: "" + ## Autoscaling configuration + ## ref: https://kubernetes.io/docs/concepts/workloads/autoscaling/ + ## + autoscaling: + ## @param executor.common.autoscaling.vpa.enabled Enable VPA for Dremio Executor pods + ## @param executor.common.autoscaling.vpa.annotations Annotations for VPA resource + ## @param executor.common.autoscaling.vpa.controlledResources VPA List of resources that the vertical pod autoscaler can control. Defaults to cpu and memory + ## @param executor.common.autoscaling.vpa.maxAllowed VPA Max allowed resources for the pod + ## @param executor.common.autoscaling.vpa.minAllowed VPA Min allowed resources for the pod + ## + vpa: + enabled: false + annotations: {} + controlledResources: [] + maxAllowed: {} + minAllowed: {} + ## @param executor.common.autoscaling.vpa.updatePolicy.updateMode Autoscaling update policy + ## Specifies whether recommended updates are applied when a Pod is started and whether recommended updates are applied during the life of a Pod + ## Possible values are "Off", "Initial", "Recreate", and "Auto". + ## + updatePolicy: + updateMode: Auto + ## @param executor.common.autoscaling.hpa.enabled Enable HPA for Dremio Executor pods + ## @param executor.common.autoscaling.hpa.minReplicas Minimum number of replicas + ## @param executor.common.autoscaling.hpa.maxReplicas Maximum number of replicas + ## @param executor.common.autoscaling.hpa.targetCPU Target CPU utilization percentage + ## @param executor.common.autoscaling.hpa.targetMemory Target Memory utilization percentage + ## + hpa: + enabled: false + minReplicas: "" + maxReplicas: "" + targetCPU: "" + targetMemory: "" + + ## Network Policies + ## Ref: https://kubernetes.io/docs/concepts/services-networking/network-policies/ + ## + networkPolicy: + ## @param executor.common.networkPolicy.enabled Specifies whether a NetworkPolicy should be created + ## + enabled: true + ## @param executor.common.networkPolicy.allowExternal Don't require server label for connections + ## The Policy model to apply. When set to false, only pods with the correct + ## server label will have network access to the ports server is listening + ## on. When true, server will accept connections from any source + ## (with the correct destination port). + ## + allowExternal: true + ## @param executor.common.networkPolicy.allowExternalEgress Allow the pod to access any range of port and all destinations. + ## + allowExternalEgress: true + ## @param executor.common.networkPolicy.addExternalClientAccess Allow access from pods with client label set to "true". Ignored if `networkPolicy.allowExternal` is true. + ## + addExternalClientAccess: true + ## @param executor.common.networkPolicy.extraIngress [array] Add extra ingress rules to the NetworkPolicy + ## e.g: + ## extraIngress: + ## - ports: + ## - port: 1234 + ## from: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + extraIngress: [] + ## @param executor.common.networkPolicy.extraEgress [array] Add extra ingress rules to the NetworkPolicy (ignored if allowExternalEgress=true) + ## e.g: + ## extraEgress: + ## - ports: + ## - port: 1234 + ## to: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + ## + extraEgress: [] + ## @param executor.common.networkPolicy.ingressPodMatchLabels [object] Labels to match to allow traffic from other pods. Ignored if `networkPolicy.allowExternal` is true. + ## e.g: + ## ingressPodMatchLabels: + ## my-client: "true" + # + ingressPodMatchLabels: {} + ## @param executor.common.networkPolicy.ingressNSMatchLabels [object] Labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. + ## @param executor.common.networkPolicy.ingressNSPodMatchLabels [object] Pod labels to match to allow traffic from other namespaces. Ignored if `networkPolicy.allowExternal` is true. + ## + ingressNSMatchLabels: {} + ingressNSPodMatchLabels: {} + ## @section Persistence Parameters + ## + + ## Enable persistence using Persistent Volume Claims + ## ref: https://kubernetes.io/docs/concepts/storage/persistent-volumes/ + ## + persistence: + ## @param executor.common.persistence.enabled Enable persistence using Persistent Volume Claims + ## + enabled: true + ## @param executor.common.persistence.mountPath Path to mount the volume at. + ## + mountPath: /bitnami/dremio/data + ## @param executor.common.persistence.subPath The subdirectory of the volume to mount to, useful in dev environments and one PV for multiple services + ## + subPath: "" + ## @param executor.common.persistence.storageClass Storage class of backing PVC + ## If defined, storageClassName: + ## If set to "-", storageClassName: "", which disables dynamic provisioning + ## If undefined (the default) or set to null, no storageClassName spec is + ## set, choosing the default provisioner. (gp2 on AWS, standard on + ## GKE, AWS & OpenStack) + ## + storageClass: "" + ## @param executor.common.persistence.annotations Persistent Volume Claim annotations + ## + annotations: {} + ## @param executor.common.persistence.accessModes Persistent Volume Access Modes + ## + accessModes: + - ReadWriteOnce + ## @param executor.common.persistence.size Size of data volume + ## + size: 8Gi + ## @param executor.common.persistence.existingClaim The name of an existing PVC to use for persistence + ## + existingClaim: "" + ## @param executor.common.persistence.selector Selector to match an existing Persistent Volume for WordPress data PVC + ## If set, the PVC can't have a PV dynamically provisioned for it + ## E.g. + ## selector: + ## matchLabels: + ## app: my-app + ## + selector: {} + ## @param executor.common.persistence.dataSource Custom PVC data source + ## + dataSource: {} + ## ServiceAccount configuration + ## + serviceAccount: + ## @param executor.common.serviceAccount.create Specifies whether a ServiceAccount should be created + ## + create: true + ## @param executor.common.serviceAccount.name The name of the ServiceAccount to use. + ## If not set and create is true, a name is generated using the common.names.fullname template + ## + name: "" + ## @param executor.common.serviceAccount.annotations Additional Service Account annotations (evaluated as a template) + ## + annotations: {} + ## @param executor.common.serviceAccount.automountServiceAccountToken Automount service account token for the server service account + ## + automountServiceAccountToken: false + ## @section Dremio Executor Engine Parameters + ## Engine configuration + ## + ## @param executor.engines[0].name Name of the engine + ## @param executor.engines[0].overrides Override configuration set in the "executor.common" section + engines: + - name: default + overrides: {} + +## @section Traffic Exposure Parameters +## + +## Dremio service parameters +## +service: + ## @param service.type Dremio service type + ## + type: LoadBalancer + ## @param service.ports.web Dremio service web port + ## @param service.ports.client Dremio service client port + ## @param service.ports.flight Dremio service flight port + ## + ports: + web: 9047 + client: 31010 + flight: 32010 + ## Node ports to expose + ## @param service.nodePorts.web Node port for web + ## @param service.nodePorts.client Node port for client + ## @param service.nodePorts.flight Node port for flight + ## NOTE: choose port between <30000-32767> + ## + nodePorts: + web: "" + client: "" + flight: "" + ## @param service.clusterIP Dremio service Cluster IP + ## e.g.: + ## clusterIP: None + ## + clusterIP: "" + ## @param service.loadBalancerIP Dremio service Load Balancer IP + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/#type-loadbalancer + ## + loadBalancerIP: "" + ## @param service.loadBalancerSourceRanges Dremio service Load Balancer sources + ## ref: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/#restrict-access-for-loadbalancer-service + ## e.g: + ## loadBalancerSourceRanges: + ## - 10.10.10.0/24 + ## + loadBalancerSourceRanges: [] + ## @param service.externalTrafficPolicy Dremio service external traffic policy + ## ref http://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip + ## + externalTrafficPolicy: Cluster + ## @param service.annotations Additional custom annotations for Dremio service + ## + annotations: {} + ## @param service.extraPorts Extra ports to expose in Dremio service (normally used with the `sidecars` value) + ## + extraPorts: [] + ## @param service.sessionAffinity Control where client requests go, to the same pod or round-robin + ## Values: ClientIP or None + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/ + ## + sessionAffinity: None + ## @param service.sessionAffinityConfig Additional settings for the sessionAffinity + ## sessionAffinityConfig: + ## clientIP: + ## timeoutSeconds: 300 + ## + sessionAffinityConfig: {} + ## + ## @param service.headless.annotations Add annotations to the headless service + ## + headless: + annotations: {} +## Dremio ingress parameters +## ref: http://kubernetes.io/docs/concepts/services-networking/ingress/ +## +ingress: + ## @param ingress.enabled Enable ingress record generation for Dremio + ## + enabled: false + ## @param ingress.pathType Ingress path type + ## + pathType: ImplementationSpecific + ## @param ingress.apiVersion Force Ingress API version (automatically detected if not set) + ## + apiVersion: "" + ## @param ingress.hostname Default host for the ingress record + ## + hostname: dremio.local + ## @param ingress.ingressClassName IngressClass that will be be used to implement the Ingress (Kubernetes 1.18+) + ## This is supported in Kubernetes 1.18+ and required if you have more than one IngressClass marked as the default for your cluster . + ## ref: https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/ + ## + ingressClassName: "" + ## @param ingress.path Default path for the ingress record + ## NOTE: You may need to set this to '/*' in order to use this with ALB ingress controllers + ## + path: / + ## @param ingress.annotations Additional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations. + ## Use this parameter to set the required annotations for cert-manager, see + ## ref: https://cert-manager.io/docs/usage/ingress/#supported-annotations + ## e.g: + ## annotations: + ## kubernetes.io/ingress.class: nginx + ## cert-manager.io/cluster-issuer: cluster-issuer-name + ## + annotations: {} + ## @param ingress.tls Enable TLS configuration for the host defined at `ingress.hostname` parameter + ## TLS certificates will be retrieved from a TLS secret with name: `{{- printf "%s-tls" .Values.ingress.hostname }}` + ## You can: + ## - Use the `ingress.secrets` parameter to create this TLS secret + ## - Rely on cert-manager to create it by setting the corresponding annotations + ## - Rely on Helm to create self-signed certificates by setting `ingress.selfSigned=true` + ## + tls: false + ## @param ingress.selfSigned Create a TLS secret for this ingress record using self-signed certificates generated by Helm + ## + selfSigned: false + ## @param ingress.extraHosts An array with additional hostname(s) to be covered with the ingress record + ## e.g: + ## extraHosts: + ## - name: dremio.local + ## path: / + ## + extraHosts: [] + ## @param ingress.extraPaths An array with additional arbitrary paths that may need to be added to the ingress under the main host + ## e.g: + ## extraPaths: + ## - path: /* + ## backend: + ## serviceName: ssl-redirect + ## servicePort: use-annotation + ## + extraPaths: [] + ## @param ingress.extraTls TLS configuration for additional hostname(s) to be covered with this ingress record + ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#tls + ## e.g: + ## extraTls: + ## - hosts: + ## - dremio.local + ## secretName: dremio.local-tls + ## + extraTls: [] + ## @param ingress.secrets Custom TLS certificates as secrets + ## NOTE: 'key' and 'certificate' are expected in PEM format + ## NOTE: 'name' should line up with a 'secretName' set further up + ## If it is not set and you're using cert-manager, this is unneeded, as it will create a secret for you with valid certificates + ## If it is not set and you're NOT using cert-manager either, self-signed certificates will be created valid for 365 days + ## It is also possible to create and manage the certificates outside of this helm chart + ## Please see README.md for more information + ## e.g: + ## secrets: + ## - name: dremio.local-tls + ## key: |- + ## -----BEGIN RSA PRIVATE KEY----- + ## ... + ## -----END RSA PRIVATE KEY----- + ## certificate: |- + ## -----BEGIN CERTIFICATE----- + ## ... + ## -----END CERTIFICATE----- + ## + secrets: [] + ## @param ingress.extraRules Additional rules to be covered with this ingress record + ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#ingress-rules + ## e.g: + ## extraRules: + ## - host: example.local + ## http: + ## path: / + ## backend: + ## service: + ## name: example-svc + ## port: + ## name: http + ## + extraRules: [] + +## @section Dremio bootstrap user job +## +bootstrapUserJob: + ## @param bootstrapUserJob.enabled Enable the bootstrap user job + ## + enabled: true + ## @param bootstrapUserJob.forceRun Force the run of the credential job + ## + forceRun: false + ## @param bootstrapUserJob.labels Add labels to the init job definition + ## + labels: {} + ## @param bootstrapUserJob.backoffLimit set backoff limit of the job + ## + backoffLimit: 10 + ## @param bootstrapUserJob.extraVolumes Optionally specify extra list of additional volumes for the credential init job + ## + extraVolumes: [] + ## @param bootstrapUserJob.extraCommands Extra commands to pass to the generation job + ## + extraCommands: "" + ## Configure Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param bootstrapUserJob.containerSecurityContext.enabled Enabled containers' Security Context + ## @param bootstrapUserJob.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in container + ## @param bootstrapUserJob.containerSecurityContext.runAsUser Set containers' Security Context runAsUser + ## @param bootstrapUserJob.containerSecurityContext.runAsGroup Set containers' Security Context runAsGroup + ## @param bootstrapUserJob.containerSecurityContext.runAsNonRoot Set container's Security Context runAsNonRoot + ## @param bootstrapUserJob.containerSecurityContext.privileged Set container's Security Context privileged + ## @param bootstrapUserJob.containerSecurityContext.readOnlyRootFilesystem Set container's Security Context readOnlyRootFilesystem + ## @param bootstrapUserJob.containerSecurityContext.allowPrivilegeEscalation Set container's Security Context allowPrivilegeEscalation + ## @param bootstrapUserJob.containerSecurityContext.capabilities.drop List of capabilities to be dropped + ## @param bootstrapUserJob.containerSecurityContext.seccompProfile.type Set container's Security Context seccomp profile + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + privileged: false + readOnlyRootFilesystem: true + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + ## Configure Pods Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param bootstrapUserJob.podSecurityContext.enabled Enabled credential init job pods' Security Context + ## @param bootstrapUserJob.podSecurityContext.fsGroupChangePolicy Set filesystem group change policy + ## @param bootstrapUserJob.podSecurityContext.sysctls Set kernel settings using the sysctl interface + ## @param bootstrapUserJob.podSecurityContext.supplementalGroups Set filesystem extra groups + ## @param bootstrapUserJob.podSecurityContext.fsGroup Set credential init job pod's Security Context fsGroup + ## + podSecurityContext: + enabled: true + fsGroupChangePolicy: Always + sysctls: [] + supplementalGroups: [] + fsGroup: 1001 + ## @param bootstrapUserJob.extraEnvVars Array containing extra env vars to configure the credential init job + ## For example: + ## extraEnvVars: + ## - name: GF_DEFAULT_INSTANCE_NAME + ## value: my-instance + ## + extraEnvVars: [] + ## @param bootstrapUserJob.extraEnvVarsCM ConfigMap containing extra env vars to configure the credential init job + ## + extraEnvVarsCM: "" + ## @param bootstrapUserJob.extraEnvVarsSecret Secret containing extra env vars to configure the credential init job (in case of sensitive data) + ## + extraEnvVarsSecret: "" + ## @param bootstrapUserJob.extraVolumeMounts Array of extra volume mounts to be added to the jwt Container (evaluated as template). Normally used with `extraVolumes`. + ## + extraVolumeMounts: [] + ## Container resource requests and limits + ## ref: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param bootstrapUserJob.resourcesPreset Set container resources according to one common preset (allowed values: none, nano, micro, small, medium, large, xlarge, 2xlarge). This is ignored if bootstrapUserJob.resources is set (bootstrapUserJob.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "micro" + ## @param bootstrapUserJob.resources Set container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Configure extra options for Data Coordinator containers' liveness, readiness and startup probes + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/#configure-probes + ## @param bootstrapUserJob.livenessProbe.enabled Enable livenessProbe on init job + ## @param bootstrapUserJob.livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe + ## @param bootstrapUserJob.livenessProbe.periodSeconds Period seconds for livenessProbe + ## @param bootstrapUserJob.livenessProbe.timeoutSeconds Timeout seconds for livenessProbe + ## @param bootstrapUserJob.livenessProbe.failureThreshold Failure threshold for livenessProbe + ## @param bootstrapUserJob.livenessProbe.successThreshold Success threshold for livenessProbe + ## + livenessProbe: + enabled: true + initialDelaySeconds: 5 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 5 + successThreshold: 1 + ## @param bootstrapUserJob.readinessProbe.enabled Enable readinessProbe on init job + ## @param bootstrapUserJob.readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe + ## @param bootstrapUserJob.readinessProbe.periodSeconds Period seconds for readinessProbe + ## @param bootstrapUserJob.readinessProbe.timeoutSeconds Timeout seconds for readinessProbe + ## @param bootstrapUserJob.readinessProbe.failureThreshold Failure threshold for readinessProbe + ## @param bootstrapUserJob.readinessProbe.successThreshold Success threshold for readinessProbe + ## + readinessProbe: + enabled: true + initialDelaySeconds: 5 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 5 + successThreshold: 1 + ## @param bootstrapUserJob.startupProbe.enabled Enable startupProbe on Data Coordinator containers + ## @param bootstrapUserJob.startupProbe.initialDelaySeconds Initial delay seconds for startupProbe + ## @param bootstrapUserJob.startupProbe.periodSeconds Period seconds for startupProbe + ## @param bootstrapUserJob.startupProbe.timeoutSeconds Timeout seconds for startupProbe + ## @param bootstrapUserJob.startupProbe.failureThreshold Failure threshold for startupProbe + ## @param bootstrapUserJob.startupProbe.successThreshold Success threshold for startupProbe + ## + startupProbe: + enabled: false + initialDelaySeconds: 5 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 5 + successThreshold: 1 + ## @param bootstrapUserJob.customLivenessProbe Custom livenessProbe that overrides the default one + ## + customLivenessProbe: {} + ## @param bootstrapUserJob.customReadinessProbe Custom readinessProbe that overrides the default one + ## + customReadinessProbe: {} + ## @param bootstrapUserJob.customStartupProbe Custom startupProbe that overrides the default one + ## + customStartupProbe: {} + ## @param bootstrapUserJob.automountServiceAccountToken Mount Service Account token in pod + ## + automountServiceAccountToken: false + ## @param bootstrapUserJob.hostAliases Add deployment host aliases + ## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ + ## + hostAliases: [] + ## @param bootstrapUserJob.annotations [object] Add annotations to the job + ## + annotations: + helm.sh/hook: post-install + helm.sh/hook-delete-policy: before-hook-creation,hook-succeeded + # This should be executed after the minio provisioning job + helm.sh/hook-weight: "10" + ## @param bootstrapUserJob.podLabels Additional pod labels + ## Ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + ## + podLabels: {} + ## @param bootstrapUserJob.podAnnotations Additional pod annotations + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + podAnnotations: {} + ## Network Policy configuration + ## ref: https://kubernetes.io/docs/concepts/services-networking/network-policies/ + ## + networkPolicy: + ## @param bootstrapUserJob.networkPolicy.enabled Enable creation of NetworkPolicy resources + ## + enabled: true + ## @param bootstrapUserJob.networkPolicy.allowExternalEgress Allow the pod to access any range of port and all destinations. + ## + allowExternalEgress: true + ## @param bootstrapUserJob.networkPolicy.extraIngress [array] Add extra ingress rules to the NetworkPolicy + ## e.g: + ## extraIngress: + ## - ports: + ## - port: 1234 + ## from: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + ## + extraIngress: [] + ## @param bootstrapUserJob.networkPolicy.extraEgress [array] Add extra ingress rules to the NetworkPolicy + ## e.g: + ## extraEgress: + ## - ports: + ## - port: 1234 + ## to: + ## - podSelector: + ## - matchLabels: + ## - role: frontend + ## - podSelector: + ## - matchExpressions: + ## - key: role + ## operator: In + ## values: + ## - frontend + ## + extraEgress: [] + ## @param bootstrapUserJob.networkPolicy.ingressNSMatchLabels [object] Labels to match to allow traffic from other namespaces + ## @param bootstrapUserJob.networkPolicy.ingressNSPodMatchLabels [object] Pod labels to match to allow traffic from other namespaces + ## + ingressNSMatchLabels: {} + ingressNSPodMatchLabels: {} + +## @section Default Init Container Parameters +## +defaultInitContainers: + ## OS Shell + Utility image + ## ref: https://hub.docker.com/r/bitnami/os-shell/tags/ + ## @param defaultInitContainers.defaultImage.registry [default: REGISTRY_NAME] OS Shell + Utility image registry + ## @param defaultInitContainers.defaultImage.repository [default: REPOSITORY_NAME/os-shell] OS Shell + Utility image repository + ## @skip defaultInitContainers.defaultImage.tag OS Shell + Utility image tag (immutable tags are recommended) + ## @param defaultInitContainers.defaultImage.pullPolicy OS Shell + Utility image pull policy + ## @param defaultInitContainers.defaultImage.pullSecrets OS Shell + Utility image pull secrets + ## + defaultImage: + registry: docker.io + repository: bitnami/os-shell + tag: 12-debian-12-r22 + pullPolicy: IfNotPresent + ## Optionally specify an array of imagePullSecrets. + ## Secrets must be manually created in the namespace. + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + ## Init container that waits for backends to be ready + ## + wait: + ## @param defaultInitContainers.wait.enabled Enable init container that waits for backends to be ready + ## + enabled: true + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param defaultInitContainers.wait.resourcesPreset Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "nano" + ## @param defaultInitContainers.wait.resources Set init container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Init container Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param defaultInitContainers.wait.containerSecurityContext.enabled Enabled Init container' Security Context + ## @param defaultInitContainers.wait.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Init container + ## @param defaultInitContainers.wait.containerSecurityContext.runAsUser Set runAsUser in Init container' Security Context + ## @param defaultInitContainers.wait.containerSecurityContext.runAsGroup Set runAsGroup in Init container' Security Context + ## @param defaultInitContainers.wait.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Init container' Security Context + ## @param defaultInitContainers.wait.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Init container' Security Context + ## @param defaultInitContainers.wait.containerSecurityContext.privileged Set privileged in Init container' Security Context + ## @param defaultInitContainers.wait.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Init container' Security Context + ## @param defaultInitContainers.wait.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Init container + ## @param defaultInitContainers.wait.containerSecurityContext.seccompProfile.type Set seccomp profile in Init container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + ## Init container that generates and merges the dremio.conf and core-site.xml configuration files + ## + generateConf: + ## @param defaultInitContainers.generateConf.enabled Enable init container that merges and renders the dremio.conf and core-site.xml configuration files + ## + enabled: true + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param defaultInitContainers.generateConf.resourcesPreset Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "nano" + ## @param defaultInitContainers.generateConf.resources Set init container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Init container Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param defaultInitContainers.generateConf.containerSecurityContext.enabled Enabled Init container' Security Context + ## @param defaultInitContainers.generateConf.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Init container + ## @param defaultInitContainers.generateConf.containerSecurityContext.runAsUser Set runAsUser in Init container' Security Context + ## @param defaultInitContainers.generateConf.containerSecurityContext.runAsGroup Set runAsGroup in Init container' Security Context + ## @param defaultInitContainers.generateConf.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Init container' Security Context + ## @param defaultInitContainers.generateConf.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Init container' Security Context + ## @param defaultInitContainers.generateConf.containerSecurityContext.privileged Set privileged in Init container' Security Context + ## @param defaultInitContainers.generateConf.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Init container' Security Context + ## @param defaultInitContainers.generateConf.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Init container + ## @param defaultInitContainers.generateConf.containerSecurityContext.seccompProfile.type Set seccomp profile in Init container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + ## @param defaultInitContainers.generateConf.extraEnvVars Array with extra environment variables to add to Dremio containers + ## e.g: + ## extraEnvVars: + ## - name: FOO + ## value: "bar" + ## + extraEnvVars: [] + ## @param defaultInitContainers.generateConf.extraEnvVarsCM Name of existing ConfigMap containing extra env vars for Dremio containers + ## + extraEnvVarsCM: "" + ## @param defaultInitContainers.generateConf.extraEnvVarsSecret Name of existing Secret containing extra env vars for Dremio containers + ## + extraEnvVarsSecret: "" + ## @param defaultInitContainers.generateConf.extraVolumeMounts Optionally specify extra list of additional volumeMounts for the Dremio containers + ## + extraVolumeMounts: [] + ## Init container that initializes the Java keystore with the TLS certificates (requires dremio.tls.enabled=true) + ## + initCerts: + ## @param defaultInitContainers.initCerts.enabled Enable init container that initializes the Java keystore with the TLS certificates (requires dremio.tls.enabled=true) + ## + enabled: true + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param defaultInitContainers.initCerts.resourcesPreset Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "nano" + ## @param defaultInitContainers.initCerts.resources Set init container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Init container Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param defaultInitContainers.initCerts.containerSecurityContext.enabled Enabled Init container' Security Context + ## @param defaultInitContainers.initCerts.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Init container + ## @param defaultInitContainers.initCerts.containerSecurityContext.runAsUser Set runAsUser in Init container' Security Context + ## @param defaultInitContainers.initCerts.containerSecurityContext.runAsGroup Set runAsGroup in Init container' Security Context + ## @param defaultInitContainers.initCerts.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Init container' Security Context + ## @param defaultInitContainers.initCerts.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Init container' Security Context + ## @param defaultInitContainers.initCerts.containerSecurityContext.privileged Set privileged in Init container' Security Context + ## @param defaultInitContainers.initCerts.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Init container' Security Context + ## @param defaultInitContainers.initCerts.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Init container + ## @param defaultInitContainers.initCerts.containerSecurityContext.seccompProfile.type Set seccomp profile in Init container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + ## Init container that copies the default Dremio configuration to an empty-dir volume + ## + copyDefaultConf: + ## @param defaultInitContainers.copyDefaultConf.enabled Enable init container that copies the default dremio configuration to an empty-dir volume + ## + enabled: true + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param defaultInitContainers.copyDefaultConf.resourcesPreset Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "nano" + ## @param defaultInitContainers.copyDefaultConf.resources Set init container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Init container Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.enabled Enabled Init container' Security Context + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Init container + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.runAsUser Set runAsUser in Init container' Security Context + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.runAsGroup Set runAsGroup in Init container' Security Context + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Init container' Security Context + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Init container' Security Context + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.privileged Set privileged in Init container' Security Context + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Init container' Security Context + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Init container + ## @param defaultInitContainers.copyDefaultConf.containerSecurityContext.seccompProfile.type Set seccomp profile in Init container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + ## Init container that upgrades the metadata KV store + ## + upgradeKeystore: + ## @param defaultInitContainers.upgradeKeystore.enabled Enable init container that upgrades the metadata KV store + ## + enabled: true + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param defaultInitContainers.upgradeKeystore.resourcesPreset Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "large" + ## @param defaultInitContainers.upgradeKeystore.resources Set init container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Init container Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.enabled Enabled Init container' Security Context + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in Init container + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.runAsUser Set runAsUser in Init container' Security Context + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.runAsGroup Set runAsGroup in Init container' Security Context + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.runAsNonRoot Set runAsNonRoot in Init container' Security Context + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.readOnlyRootFilesystem Set readOnlyRootFilesystem in Init container' Security Context + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.privileged Set privileged in Init container' Security Context + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.allowPrivilegeEscalation Set allowPrivilegeEscalation in Init container' Security Context + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.capabilities.drop List of capabilities to be dropped in Init container + ## @param defaultInitContainers.upgradeKeystore.containerSecurityContext.seccompProfile.type Set seccomp profile in Init container + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + runAsNonRoot: true + readOnlyRootFilesystem: true + privileged: false + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + ## Init container that changes the owner and group of the persistent volume mount point to runAsUser:fsGroup values based on the *podSecurityContext/*containerSecurityContext parameters + ## + volumePermissions: + ## @param defaultInitContainers.volumePermissions.enabled Enable init container that changes the owner/group of the PV mount point to `runAsUser:fsGroup` + ## + enabled: false + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param defaultInitContainers.volumePermissions.resourcesPreset Set init container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if volumePermissions.resources is set (volumePermissions.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "nano" + ## @param defaultInitContainers.volumePermissions.resources Set init container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Init container Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param defaultInitContainers.volumePermissions.containerSecurityContext.enabled Enabled init container' Security Context + ## @param defaultInitContainers.volumePermissions.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in init container + ## @param defaultInitContainers.volumePermissions.containerSecurityContext.runAsUser Set init container's Security Context runAsUser + ## NOTE: when runAsUser is set to special value "auto", init container will try to chown the + ## data folder to auto-determined user&group, using commands: `id -u`:`id -G | cut -d" " -f2` + ## "auto" is especially useful for OpenShift which has scc with dynamic user ids (and 0 is not allowed) + ## + containerSecurityContext: + enabled: true + seLinuxOptions: {} + runAsUser: 0 + +## @section MinIO® chart parameters +## @extra minio For full list of MinIO® values configurations please refere [here](https://github.com/bitnami/charts/tree/main/bitnami/minio) +## +minio: + ## @param minio.enabled Enable/disable MinIO® chart installation + ## to be used as an objstore for Dremio + ## + enabled: true + ## @param minio.containerPorts.api MinIO® container port to open for MinIO® API + ## + containerPorts: + api: 9000 + ## MinIO® authentication parameters + ## + auth: + ## @param minio.auth.rootUser MinIO® root username + ## + rootUser: admin + ## @param minio.auth.rootPassword Password for MinIO® root user + ## + rootPassword: "" + ## @param minio.auth.existingSecret Name of an existing secret containing the MinIO® credentials + ## + existingSecret: "" + ## @param minio.defaultBuckets Comma, semi-colon or space separated list of MinIO® buckets to create + ## + defaultBuckets: "dremio" + ## @param minio.provisioning.enabled Enable/disable MinIO® provisioning job + ## @param minio.provisioning.extraCommands Extra commands to run on MinIO® provisioning job + ## + provisioning: + enabled: true + # We need to allow downloads in order for the UI to work + extraCommands: ["mc anonymous set download provisioning/dremio"] + ## @param minio.tls.enabled Enable/disable MinIO® TLS support + ## @param minio.tls.autoGenerated Autogenerate TLS certificates + ## + tls: + enabled: true + autoGenerated: true + ## @param minio.service.type MinIO® service type + ## @param minio.service.loadBalancerIP MinIO® service LoadBalancer IP + ## @param minio.service.ports.api MinIO® service port + ## + service: + type: ClusterIP + loadBalancerIP: "" + ports: + api: 9000 + +## @section Prometheus metrics +## +metrics: + ## @param metrics.enabled Enable the export of Prometheus metrics + ## + enabled: false + ## Bitnami JMX exporter image + ## ref: https://hub.docker.com/r/bitnami/jmx-exporter/tags/ + ## @param metrics.image.registry [default: REGISTRY_NAME] JMX exporter image registry + ## @param metrics.image.repository [default: REPOSITORY_NAME/jmx-exporter] JMX exporter image repository + ## @skip metrics.image.tag JMX exporter image tag (immutable tags are recommended) + ## @param metrics.image.digest JMX exporter image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag + ## @param metrics.image.pullPolicy JMX exporter image pull policy + ## @param metrics.image.pullSecrets Specify docker-registry secret names as an array + ## + image: + registry: docker.io + repository: bitnami/jmx-exporter + tag: 1.0.1-debian-12-r1 + digest: "" + ## Specify a imagePullPolicy + ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' + ## ref: https://kubernetes.io/docs/concepts/containers/images/#pre-pulled-images + ## + pullPolicy: IfNotPresent + ## Optionally specify an array of imagePullSecrets (secrets must be manually created in the namespace) + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + ## @param metrics.extraArgs Add extra arguments to the default container args section + ## + extraArgs: [] + ## Prometheus JMX exporter containers' Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container + ## @param metrics.containerSecurityContext.enabled Enable Prometheus JMX exporter containers' Security Context + ## @param metrics.containerSecurityContext.seLinuxOptions [object,nullable] Set SELinux options in container + ## @param metrics.containerSecurityContext.runAsUser Set Prometheus JMX exporter containers' Security Context runAsUser + ## @param metrics.containerSecurityContext.runAsGroup Group ID for the Prometheus JMX exporter container + ## @param metrics.containerSecurityContext.runAsNonRoot Set Prometheus JMX exporter containers' Security Context runAsNonRoot + ## @param metrics.containerSecurityContext.privileged Set Prometheus JMX exporter container's Security Context privileged + ## @param metrics.containerSecurityContext.allowPrivilegeEscalation Set Prometheus JMX exporter containers' Security Context allowPrivilegeEscalation + ## @param metrics.containerSecurityContext.readOnlyRootFilesystem Set Prometheus JMX exporter containers' Security Context readOnlyRootFilesystem + ## @param metrics.containerSecurityContext.capabilities.drop Set Prometheus JMX exporter containers' Security Context capabilities to be dropped + ## @param metrics.containerSecurityContext.seccompProfile.type Set Prometheus JMX exporter container's Security Context seccomp profile + ## e.g: + ## containerSecurityContext: + ## enabled: true + ## capabilities: + ## drop: ["NET_RAW"] + ## readOnlyRootFilesystem: true + ## + containerSecurityContext: + enabled: true + privileged: false + runAsNonRoot: true + seLinuxOptions: {} + runAsUser: 1001 + runAsGroup: 1001 + readOnlyRootFilesystem: true + allowPrivilegeEscalation: false + capabilities: + drop: ["ALL"] + seccompProfile: + type: "RuntimeDefault" + ## @param metrics.containerPorts.metrics Prometheus JMX exporter metrics container port + ## + containerPorts: + metrics: 5556 + ## Prometheus JMX exporter resource requests and limits + ## ref: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param metrics.resourcesPreset Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if metrics.resources is set (metrics.resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "micro" + ## @param metrics.resources Set container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {} + ## Configure extra options for liveness probe + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes + ## @param metrics.livenessProbe.enabled Enable livenessProbe + ## @param metrics.livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe + ## @param metrics.livenessProbe.periodSeconds Period seconds for livenessProbe + ## @param metrics.livenessProbe.timeoutSeconds Timeout seconds for livenessProbe + ## @param metrics.livenessProbe.failureThreshold Failure threshold for livenessProbe + ## @param metrics.livenessProbe.successThreshold Success threshold for livenessProbe + ## + livenessProbe: + enabled: true + initialDelaySeconds: 60 + periodSeconds: 10 + timeoutSeconds: 30 + successThreshold: 1 + failureThreshold: 3 + ## Configure extra options for readiness probe + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes + ## @param metrics.readinessProbe.enabled Enable readinessProbe + ## @param metrics.readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe + ## @param metrics.readinessProbe.periodSeconds Period seconds for readinessProbe + ## @param metrics.readinessProbe.timeoutSeconds Timeout seconds for readinessProbe + ## @param metrics.readinessProbe.failureThreshold Failure threshold for readinessProbe + ## @param metrics.readinessProbe.successThreshold Success threshold for readinessProbe + ## + readinessProbe: + enabled: true + initialDelaySeconds: 30 + periodSeconds: 10 + timeoutSeconds: 30 + successThreshold: 1 + failureThreshold: 3 + ## Configure extra options for startup probe + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-startup-probes/#configure-probes + ## @param metrics.startupProbe.enabled Enable startupProbe + ## @param metrics.startupProbe.initialDelaySeconds Initial delay seconds for startupProbe + ## @param metrics.startupProbe.periodSeconds Period seconds for startupProbe + ## @param metrics.startupProbe.timeoutSeconds Timeout seconds for startupProbe + ## @param metrics.startupProbe.failureThreshold Failure threshold for startupProbe + ## @param metrics.startupProbe.successThreshold Success threshold for startupProbe + ## + startupProbe: + enabled: true + initialDelaySeconds: 30 + periodSeconds: 10 + timeoutSeconds: 30 + successThreshold: 1 + failureThreshold: 3 + ## Prometheus JMX exporter service configuration + ## + service: + ## @param metrics.service.ports.metrics Prometheus JMX exporter metrics service port + ## + ports: + metrics: 5556 + ## @param metrics.service.clusterIP Static clusterIP or None for headless services + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/#choosing-your-own-ip-address + ## + clusterIP: "" + ## @param metrics.service.sessionAffinity Control where client requests go, to the same pod or round-robin + ## Values: ClientIP or None + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/ + ## + sessionAffinity: None + ## @param metrics.service.annotations [object] Annotations for the Prometheus JMX exporter service + ## + annotations: {} + ## @param metrics.configOverrides [string] Configuration file for JMX exporter + ## Specify content for jmx-prometheus.yml. Evaluated as a template + ## + configOverrides: {} + ## @param metrics.existingConfigmap Name of existing ConfigMap with JMX exporter configuration + ## NOTE: This will override metrics.config + ## + existingConfigmap: "" + ## Prometheus Operator ServiceMonitor configuration + ## + serviceMonitor: + ## @param metrics.serviceMonitor.enabled if `true`, creates a Prometheus Operator ServiceMonitor (also requires `metrics.enabled` to be `true`) + ## + enabled: false + ## @param metrics.serviceMonitor.namespace Namespace in which Prometheus is running + ## + namespace: "" + ## @param metrics.serviceMonitor.annotations Additional custom annotations for the ServiceMonitor + ## + annotations: {} + ## @param metrics.serviceMonitor.labels Extra labels for the ServiceMonitor + ## + labels: {} + ## @param metrics.serviceMonitor.jobLabel The name of the label on the target service to use as the job name in Prometheus + ## + jobLabel: "" + ## @param metrics.serviceMonitor.honorLabels honorLabels chooses the metric's labels on collisions with target labels + ## + honorLabels: false + ## @param metrics.serviceMonitor.interval Interval at which metrics should be scraped. + ## ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint + ## e.g: + ## interval: 10s + ## + interval: "" + ## @param metrics.serviceMonitor.scrapeTimeout Timeout after which the scrape is ended + ## ref: https://github.com/coreos/prometheus-operator/blob/master/Documentation/api.md#endpoint + ## e.g: + ## scrapeTimeout: 10s + ## + scrapeTimeout: "" + ## @param metrics.serviceMonitor.metricRelabelings Specify additional relabeling of metrics + ## + metricRelabelings: [] + ## @param metrics.serviceMonitor.relabelings Specify general relabeling + ## + relabelings: [] + ## @param metrics.serviceMonitor.selector Prometheus instance selector labels + ## ref: https://github.com/bitnami/charts/tree/main/bitnami/prometheus-operator#prometheus-configuration + ## selector: + ## prometheus: my-prometheus + ## + selector: {} + +## @section External S3 parameters +## All of these values are only used when redis.enabled is set to false +## @param externalS3.host External S3 host +## @param externalS3.port External S3 port number +## @param externalS3.accessKeyID External S3 access key ID +## @param externalS3.accessKeySecret External S3 access key secret +## @param externalS3.existingSecret Name of an existing secret resource containing the S3 credentials +## @param externalS3.existingSecretAccessKeyIDKey Name of an existing secret key containing the S3 access key ID +## @param externalS3.existingSecretKeySecretKey Name of an existing secret key containing the S3 access key secret +## @param externalS3.protocol External S3 protocol +## @param externalS3.bucket External S3 bucket +## @param externalS3.path External S3 path inside the bucket +## @param externalS3.region External S3 region +## @param externalS3.authentication External S3 authentication type +## @param externalS3.disableCertChecking Disable certificate checking on external S3 (necessary if it uses ) +## +externalS3: + host: "" + port: 443 + accessKeyID: "" + accessKeySecret: "" + existingSecret: "" + existingSecretAccessKeyIDKey: "root-user" + existingSecretKeySecretKey: "root-password" + bucket: "dremio" + path: "" + region: "us-east-1" + authentication: "accesskey" + protocol: "https" + disableCertChecking: false + +## @section External Zookeeper paramaters +## +externalZookeeper: + ## @param externalZookeeper.servers List of external zookeeper servers to use + ## @param externalZookeeper.port Port of the Zookeeper servers + ## + servers: [] + port: 2888 +## @section Zookeeper subchart parameters +## +## @param zookeeper.enabled Deploy Zookeeper subchart +## @param zookeeper.replicaCount Number of Zookeeper instances +## @param zookeeper.containerPorts.client Zookeeper container port +## +zookeeper: + enabled: true + replicaCount: 1 + containerPorts: + client: 2181 + ## ZooKeeper resource requests and limits + ## ref: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ + ## @param zookeeper.resourcesPreset Set container resources according to one common preset (allowed values: none, nano, small, medium, large, xlarge, 2xlarge). This is ignored if resources is set (resources is recommended for production). + ## More information: https://github.com/bitnami/charts/blob/main/bitnami/common/templates/_resources.tpl#L15 + ## + resourcesPreset: "micro" + ## @param zookeeper.resources Set container requests and limits for different resources like CPU or memory (essential for production workloads) + ## Example: + ## resources: + ## requests: + ## cpu: 2 + ## memory: 512Mi + ## limits: + ## cpu: 3 + ## memory: 1024Mi + ## + resources: {}