substratusai / kubeai

Private Open AI on Kubernetes
https://www.kubeai.org
Apache License 2.0
347 stars 33 forks source link

Support multi-tenancy in the Chat UI #136

Open nstogner opened 1 month ago

nstogner commented 1 month ago

Currently we have authentication explicitly disabled and are missing data persistence (needed for tracking users) on Open WebUI. This means that any user can view chat threads. Also Pod restarts cause any thread history to be lost.

Short term it probably makes sense to expose a way to enable user logins and add a PVC to Open WebUI. I don't think we want KubeAI to rely on dependencies like NFS storage so we might want to switch the OpenWeb UI Pod to be managed by a StatefulSet and set replicas: 1 (& a replacement upgrade strategy) with a standard PVC today.

Longer term, we need to consider how we are going to tackle AuthN/AuthZ in a consistent way across all UIs for KubeAI (assuming we will be adding a platform UI for building assistants, etc).

gentoorax commented 5 days ago

Could you maybe have the helm chart allow you to specify an existing PVC, or a storage class? Maybe take a look at the immich helm chart; this does something similar. That way you are not dependent on a specific storage implementation. I use OpenEBS Mayastor for example, but it could just as easily be an NFS or Longhorn PVC.

...
    immich:
      image:
        tag: "0.7.2"
      persistence:
        enabled: true  # Ensure persistence is explicitly enabled
        library:
          existingClaim: immich-pvc