Spaces:
Running
Running
# These kubernetes manifests are UNDER ACTIVE DEVELOPMENT and are not yet ready for production use. | |
# They will be used for the upcoming distributed version of chroma. They are not even ready | |
# for testing yet. Please do not use them unless you are working on the distributed version of chroma. | |
apiVersion: v1 | |
kind: Namespace | |
metadata: | |
name: chroma | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: pulsar | |
namespace: chroma | |
spec: | |
ports: | |
- name: pulsar-port | |
port: 6650 | |
targetPort: 6650 | |
- name: admin-port | |
port: 8080 | |
targetPort: 8080 | |
selector: | |
app: pulsar | |
type: ClusterIP | |
# TODO: Should be stateful set locally or managed via terraform into streamnative for cloud deployment | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: pulsar | |
namespace: chroma | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: pulsar | |
template: | |
metadata: | |
labels: | |
app: pulsar | |
spec: | |
containers: | |
- name: pulsar | |
image: apachepulsar/pulsar | |
command: [ "/pulsar/bin/pulsar", "standalone" ] | |
env: | |
# This is needed by github actions. We force this to be lower everywehre for now. | |
# Since real deployments will configure/use pulsar this way. | |
- name: PULSAR_MEM | |
value: "-Xms128m -Xmx512m" | |
ports: | |
- containerPort: 6650 | |
- containerPort: 8080 | |
volumeMounts: | |
- name: pulsardata | |
mountPath: /pulsar/data | |
# readinessProbe: | |
# httpGet: | |
# path: /admin/v2/brokers/health | |
# port: 8080 | |
# initialDelaySeconds: 10 | |
# periodSeconds: 5 | |
# livenessProbe: | |
# httpGet: | |
# path: /admin/v2/brokers/health | |
# port: 8080 | |
# initialDelaySeconds: 20 | |
# periodSeconds: 10 | |
volumes: | |
- name: pulsardata | |
emptyDir: {} | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: server | |
namespace: chroma | |
spec: | |
ports: | |
- name: server | |
port: 8000 | |
targetPort: 8000 | |
selector: | |
app: server | |
type: LoadBalancer | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: server | |
namespace: chroma | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: server | |
template: | |
metadata: | |
labels: | |
app: server | |
spec: | |
containers: | |
- name: server | |
image: server | |
imagePullPolicy: IfNotPresent | |
ports: | |
- containerPort: 8000 | |
volumeMounts: | |
- name: chroma | |
mountPath: /test | |
env: | |
- name: IS_PERSISTENT | |
value: "TRUE" | |
- name: CHROMA_PRODUCER_IMPL | |
value: "chromadb.ingest.impl.pulsar.PulsarProducer" | |
- name: CHROMA_CONSUMER_IMPL | |
value: "chromadb.ingest.impl.pulsar.PulsarConsumer" | |
- name: CHROMA_SEGMENT_MANAGER_IMPL | |
value: "chromadb.segment.impl.manager.distributed.DistributedSegmentManager" | |
- name: PULSAR_BROKER_URL | |
value: "pulsar.chroma" | |
- name: PULSAR_BROKER_PORT | |
value: "6650" | |
- name: PULSAR_ADMIN_PORT | |
value: "8080" | |
- name: ALLOW_RESET | |
value: "TRUE" | |
- name: CHROMA_SYSDB_IMPL | |
value: "chromadb.db.impl.grpc.client.GrpcSysDB" | |
- name: CHROMA_SERVER_GRPC_PORT | |
value: "50051" | |
- name: CHROMA_COORDINATOR_HOST | |
value: "coordinator.chroma" | |
readinessProbe: | |
httpGet: | |
path: /api/v1/heartbeat | |
port: 8000 | |
initialDelaySeconds: 10 | |
periodSeconds: 5 | |
# livenessProbe: | |
# httpGet: | |
# path: /healthz | |
# port: 8000 | |
# initialDelaySeconds: 20 | |
# periodSeconds: 10 | |
# Ephemeral for now | |
volumes: | |
- name: chroma | |
emptyDir: {} | |
# apiVersion: v1 | |
# kind: PersistentVolumeClaim | |
# metadata: | |
# name: index-data | |
# namespace: chroma | |
# spec: | |
# accessModes: | |
# - ReadWriteOnce | |
# resources: | |
# requests: | |
# storage: 1Gi | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
name: coordinator | |
namespace: chroma | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
app: coordinator | |
template: | |
metadata: | |
labels: | |
app: coordinator | |
spec: | |
containers: | |
- command: | |
- "chroma" | |
- "coordinator" | |
- "--pulsar-admin-url=http://pulsar.chroma:8080" | |
- "--pulsar-url=pulsar://pulsar.chroma:6650" | |
- "--notifier-provider=pulsar" | |
image: chroma-coordinator | |
imagePullPolicy: IfNotPresent | |
name: coordinator | |
ports: | |
- containerPort: 50051 | |
name: grpc | |
resources: | |
limits: | |
cpu: 100m | |
memory: 128Mi | |
apiVersion: v1 | |
kind: Service | |
metadata: | |
name: coordinator | |
namespace: chroma | |
spec: | |
ports: | |
- name: grpc | |
port: 50051 | |
targetPort: grpc | |
selector: | |
app: coordinator | |
type: ClusterIP | |