Skip to content

[Feature Request] Create extra objects with this chart #858

@koeberlue

Description

@koeberlue

Is your feature request related to a problem? Please describe.

To get this chart running, I am required to provide my own databases. A common way to provide databases in Kubernetes is using Operators, which use Custom Resources to create databases, users, grants, etc.

If I want to create a Temporal database user, I currently have to somehow get the Custom Resource into Kubernetes using a secondary mechanism (like another helm chart, running kubectl apply manually, ...). This causes my whole setup to be scattered across multiple files

Describe the solution you'd like

It would be great if this chart would allow me to create any kind of Kubernetes resource, if I want to. The values.yml might look something like this (contrived example with no explicit operator in mind):

---
server:
  config:
    persistence:
      datastores:
        default:
          sql:
            createDatabase: false
            manageSchema: true
            databaseName: my-custom-db
            connectAddr: "my-custom-db.temporal.svc.cluster.local:5432"
            user: my-custom-user
            existingSecret: my-custom-user-credentials
# ...
extraObjects:
      - apiVersion: databaseOperator/v1beta
        kind: Database
        spec:
            name: my-custom-db
      - apiVersion: databaseOperator/v1beta
        kind: DatabaseUser
        spec:
            name: my-custom-user
            database: my-custom-db
            credentials: 
              generate: true
              secretName: my-custom-user-credentials

Additional context

This would also allow for other use cases, like:

  • Creating NetworkPolicies
  • Creating ConfigMaps to mount them in an init container
  • Creating Kyverno PolicyExceptions
  • ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions