add env vars for searching in worker (#773)

This adds the necessary environment variables to execute searches from
worker directly. These variables are copied from the corresponding
frontend configurations.
This commit is contained in:
Camden Cheek authored and GitHub committed 2022-03-02 11:23:25 -07:00
1 parent 85d1b86888
commit b507173c1d
2 files changed
+8

No files matched your search

+4
View File
@@ -371,6 +371,10 @@ services:
environment:
- 'SRC_FRONTEND_INTERNAL=sourcegraph-frontend-internal:3090'
- JAEGER_AGENT_HOST=jaeger
- 'SRC_GIT_SERVERS=gitserver-0:3178'
- 'SEARCHER_URL=http://searcher-0:3181'
- 'SYMBOLS_URL=http://symbols-0:3184'
- 'INDEXED_SEARCH_SERVERS=zoekt-webserver-0:6070'
volumes:
- 'worker:/mnt/cache'
networks:
+4
View File
@@ -21,6 +21,10 @@ docker run --detach \
-e GOMAXPROCS=1 \
-e SRC_FRONTEND_INTERNAL=sourcegraph-frontend-internal:3090 \
-e JAEGER_AGENT_HOST=jaeger \
-e INDEXED_SEARCH_SERVERS="$(addresses "zoekt-webserver-" $NUM_INDEXED_SEARCH ":6070")" \
-e SEARCHER_URL="$(addresses "http://searcher-" $NUM_SEARCHER ":3181")" \
-e SRC_GIT_SERVERS="$(addresses "gitserver-" $NUM_GITSERVER ":3178")" \
-e SYMBOLS_URL="$(addresses "http://symbols-" $NUM_SYMBOLS ":3184")" \
-v $VOLUME:/mnt/cache \
index.docker.io/sourcegraph/worker:3.36.3@sha256:b4e56f9f2b1dc6c603463b743aca7da9dfeff83677aa271ace5eacf9e70181b4