database

by joaquinito2051

Helm chartv0.21.3App 0.1.0

OSC database service Helm Chart

About this chart

database

OSC database service Helm Chart

Maintainers

NameEmailUrl
treydock

Requirements

RepositoryNameVersion
https://charts.bitnami.com/bitnamimariadb21.0.8
https://charts.bitnami.com/bitnamipostgresql16.7.27
https://charts.bitnami.com/bitnamiredis23.2.12
https://osc.github.io/osc-helm-charts/osc-common0.16.0
oci://registry-1.docker.io/bitnamichartsmongodb18.5.0

Usage

Allow access using Ingress

Enable Ingress access:

global:
  database:
    allowIngress: true

Allow access using Port Forwarding

Allow groups to do port Forwarding

global:
  portforwardGroups:
    - group1
    - group2

MariaDB

Enable MariaDB:

mariadb:
  enable: true
  auth:
    rootPassword: secret
    database: name
    username: name
    password: secret

MongoDB

global:
  dataDir:
    base: /fs/ess/<PROJECT>
    subPath: myapp
mongodb:
  enable: true

PostgreSQL

Enable PostgreSQL:

postgresql:
  enable: true
  auth:
    postgresPassword: secret
    database: name
    username: name
    password: secret

Redis

Enable Redis

redis:
  enable: true
  auth:
    password: secret

Values

KeyDescriptionDefault
global.oscServiceAccountThe service account used by OSC deployments. Also pulled from global.env..serviceAccount""
global.environmentThe deployment's OSC environment"production"
global.nodeSelectorRoleThe nodeSelector role"webservices"
global.imagePullSecret.createCreate the image pull secrettrue
global.imagePullSecret.nameimage pull secret name"osc-registry"
global.imagePullSecret.registryOSC registry address"docker-registry.osc.edu"
global.imagePullSecret.passwordThe image pull secret password for database imagesrequired
global.networkPolicy.createCreate the network policyfalse
global.networkPolicy.podSelectorLabels for NetworkPolicy podSelector. Defaults to "osc.common.selectorLabels"nil
global.networkPolicy.ingressAllowedPodsLabels of pods allowed to Ingress from the same namespace[]
global.storageClassThe persistent storage class"webservices-nfs-client"
global.filesetThe fileset for local-ess or local-scratch storage""
global.imageRegistryGlobal value to pass down to database charts to set registry to pull images from"docker-registry.osc.edu"
global.imagePullSecretsThe OSC image pull secret name to use to pull images["osc-registry"]
global.debugGroupsGroups that debug pods[]
global.maintenanceGroupsGroups that can perform maintenance operations[]
global.portforwardGroupsGroups that are allowed to perform port forwarding[]
global.webservicesDeploy.createCreate webservices deployment rolebindingtrue
global.alert.receiverThe alert receiver name""
global.backup.keepNumber of backups to keep7
global.postgresql.auth.postgresPasswordThe postgres user admin passwordnil
global.postgresql.auth.databaseThe database namenil
global.postgresql.auth.usernameThe database usernamenil
global.postgresql.auth.passwordThe database passwordnil
global.mongodb.auth.rootPasswordThe MongoDB root passwordnil
imagePullSecret.enableManage the image pull secret from osc-common. Disable if this chart is used as a subchart.true
mariadb.enableEnable MariaDB subchart by setting to truefalse
mariadb.image.repositoryThe OSC registry path to mariadb replicated image. This value should not need to be changed."webservices/mariadb"
mariadb.image.tagThe version of MariaDB image. This version of must built by this repo"11.8.3-debian-12-r0"
mariadb.primary.resourcesSet limits for primary MariaDB pod{"limits":{"cpu":4,"memory":"4Gi"},"requests":{"cpu":1,"memory":"256Mi"}}
mariadb.volumePermissions.image.repositoryThe OSC registry path to replicated image. This value should not need to be changed."kubernetes/bitnami/os-shell"
mariadb.volumePermissions.image.tagThe version of replicated image. This version of must replicated to OSC registry"12-debian-12-r51"
mariadb.metrics.image.repositoryThe OSC registry path to replicated image. This value should not need to be changed."kubernetes/bitnami/mysqld-exporter"
mariadb.metrics.image.tagThe version of replicated image. This version of must replicated to OSC registry"0.17.2-debian-12-r16"
mongodb.enableEnable MongoDB subchart by setting to truefalse
mongodb.auth.usernamesThe MongoDB usernames[]
mongodb.auth.passwordsThe MongoDB passwords[]
mongodb.auth.databasesThe MongoDB databases[]
mongodb.image.repositoryThe OSC registry path to mongodb replicated image. This value should not need to be changed."kubernetes/bitnami/mongodb"
mongodb.image.tagThe version of MongoDB image. This tag should be replicated into the OSC registry"8.0.13-debian-12-r0"
mongodb.resourcesSet limits for the MongoDB pod{"limits":{"cpu":4,"memory":"4Gi"},"requests":{"cpu":1,"memory":"256Mi"}}
mongodb.backup.cronjob.scheduleMongoDB cron backup schedule"@daily"
mongodb.metrics.image.repositoryThe OSC registry path to replicated image. This value should not need to be changed."kubernetes/bitnami/mongodb-exporter"
mongodb.metrics.image.tagThe version of replicated image. This version of must replicated to OSC registry"0.47.0-debian-12-r1"
mongodb.metrics.passwordMongoDB metrics passwordnil
postgresql.enableEnable PostgreSQL subchart by setting to truefalse
postgresql.image.repositoryThe OSC registry path to postgresql replicated image. This value should not need to be changed."webservices/postgresql"
postgresql.image.tagThe version of MariaDB image. This version of must built by this repo"17.6.0-debian-12-r4"
postgresql.auth.postgresPasswordThe postgres user admin passwordrequired
postgresql.auth.databaseThe database namerequired
postgresql.auth.usernameThe database usernamerequired
postgresql.auth.passwordThe database passwordrequired
postgresql.primary.resourcesSet limits for primary PostgreSQL pod{"limits":{"cpu":"4","memory":"4Gi"},"requests":{"cpu":"1","memory":"256Mi"}}
postgresql.backup.cronjob.schedulePostgreSQL cron backup schedule"@daily"
postgresql.backup.cronjob.storage{}
postgresql.volumePermissions.image.repositoryThe OSC registry path to replicated image. This value should not need to be changed."kubernetes/bitnami/os-shell"
postgresql.volumePermissions.image.tagThe version of replicated image. This version of must replicated to OSC registry"12-debian-12-r51"
postgresql.metrics.enabledtrue
postgresql.metrics.image.repositoryThe OSC registry path to replicated image. This value should not need to be changed."kubernetes/bitnami/postgres-exporter"
postgresql.metrics.image.tagThe version of replicated image. This version of must replicated to OSC registry"0.17.1-debian-12-r16"
redis.enableEnable Redis subchart by setting to truefalse
redis.image.repositoryThe OSC registry path to redis replicated image. This value should not need to be changed."kubernetes/bitnami/redis"
redis.image.tagThe version of Redis image. This version of must built by this repo"8.2.1-debian-12-r0"
redis.auth.passwordThe Redis passwordrequired
redis.architecture"standalone"
redis.master.resourcesSet limits for master Redis pod{"limits":{"cpu":"4","memory":"4Gi"},"requests":{"cpu":"1","memory":"256Mi"}}
redis.metrics.enabledtrue
redis.metrics.image.repositoryThe OSC registry path to replicated image. This value should not need to be changed."kubernetes/bitnami/redis-exporter"
redis.metrics.image.tagThe version of replicated image. This version of must replicated to OSC registry"1.76.0-debian-12-r0"
oscCommon.enableEnable the osc-common dependencytrue

Deploy database with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has database on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartdatabase is pinned at v0.21.3 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply