Skip to content

Commit

Permalink
[CLN] Dupe of #2082 (#2085)
Browse files Browse the repository at this point in the history
This is a dupe of #2082 targeted at main because it was accidentally
merged into the stacked PR.
  • Loading branch information
HammadB authored Apr 30, 2024
1 parent 4b6a958 commit b15928e
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 51 deletions.
19 changes: 9 additions & 10 deletions Tiltfile
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,12 @@ docker_build(
target='compaction_service'
)

k8s_resource(
objects=['chroma:Namespace'],
new_name='namespace',
labels=["infrastructure"],
)

k8s_yaml(
helm(
'k8s/distributed-chroma',
Expand All @@ -78,22 +84,14 @@ k8s_yaml([

# Extra stuff to make debugging and testing easier
k8s_yaml([
'k8s/test/sysdb-service.yaml',
'k8s/test/jaeger-service.yaml',
'k8s/test/jaeger.yaml',
'k8s/test/logservice-service.yaml',
'k8s/test/minio.yaml',
'k8s/test/query-service-service.yaml',
'k8s/test/test-memberlist-cr.yaml',
])

# Lots of things assume the cluster is in a basic state. Get it into a basic
# state before deploying anything else.
k8s_resource(
objects=['chroma:Namespace'],
new_name='namespace',
labels=["infrastructure"],
)
k8s_resource(
objects=[
'pod-watcher:Role',
Expand All @@ -104,6 +102,7 @@ k8s_resource(
'sysdb-serviceaccount:serviceaccount',
'sysdb-serviceaccount-rolebinding:RoleBinding',
'sysdb-query-service-memberlist-binding:clusterrolebinding',
'sysdb-compaction-service-memberlist-binding:clusterrolebinding',

'logservice-serviceaccount:serviceaccount',

Expand All @@ -112,6 +111,7 @@ k8s_resource(
'query-service-memberlist-readerwriter:ClusterRole',
'query-service-query-service-memberlist-binding:clusterrolebinding',
'query-service-memberlist-readerwriter-binding:clusterrolebinding',
'query-service:service',

'compaction-service-memberlist-readerwriter:ClusterRole',
'compaction-service-compaction-service-memberlist-binding:clusterrolebinding',
Expand All @@ -135,11 +135,10 @@ k8s_resource('logservice-migration', resource_deps=['postgres', 'namespace'], la
k8s_resource('logservice', resource_deps=['sysdb-migration'], labels=["chroma"], port_forwards='50052:50051')
k8s_resource('sysdb', resource_deps=['sysdb-migration'], labels=["chroma"], port_forwards='50051:50051')
k8s_resource('frontend-service', resource_deps=['sysdb', 'logservice'],labels=["chroma"], port_forwards='8000:8000')
k8s_resource('query-service', resource_deps=['sysdb'], labels=["chroma"])
k8s_resource('query-service', resource_deps=['sysdb'], labels=["chroma"], port_forwards='50053:50051')
k8s_resource('compaction-service', resource_deps=['sysdb'], labels=["chroma"])

# I have no idea why these need their own lines but the others don't.
k8s_resource(objects=['query-service:service'], new_name='query-service-service', resource_deps=['query-service'], labels=["chroma"])
k8s_resource('jaeger', resource_deps=['k8s_setup'], labels=["debug"])

# Local S3
Expand Down
9 changes: 7 additions & 2 deletions bin/cluster-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,13 @@ export CHROMA_COORDINATOR_HOST=localhost
echo "Chroma Server is running at port $CHROMA_SERVER_HOST"
echo "Chroma Coordinator is running at port $CHROMA_COORDINATOR_HOST"

kubectl -n chroma port-forward svc/sysdb-lb 50051:50051 &
kubectl -n chroma port-forward svc/logservice-lb 50052:50051 &
# Despite the fact that tilt forwards the ports
# We need the ports forwarded since tilt ci will
# not keep them forwarded
# https://github.com/tilt-dev/tilt/issues/5964
kubectl -n chroma port-forward svc/sysdb 50051:50051 &
kubectl -n chroma port-forward svc/logservice 50052:50051 &
kubectl -n chroma port-forward svc/query-service 50053:50051 &
kubectl -n chroma port-forward svc/frontend-service 8000:8000 &

"$@"
13 changes: 0 additions & 13 deletions k8s/test/logservice-service.yaml

This file was deleted.

13 changes: 0 additions & 13 deletions k8s/test/query-service-service.yaml

This file was deleted.

13 changes: 0 additions & 13 deletions k8s/test/sysdb-service.yaml

This file was deleted.

0 comments on commit b15928e

Please sign in to comment.