-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(rel): add syntactic code intel worker service
- Loading branch information
1 parent
4b92ae7
commit 288972f
Showing
4 changed files
with
106 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,5 +13,6 @@ resources: | |
- repo-updater | ||
- searcher | ||
- symbols | ||
- syntactic-code-intel-worker | ||
- syntect-server | ||
- worker |
5 changes: 5 additions & 0 deletions
5
base/sourcegraph/syntactic-code-intel-worker/kustomization.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
resources: | ||
- worker.Deployment.yaml | ||
- worker.Service.yaml |
77 changes: 77 additions & 0 deletions
77
base/sourcegraph/syntactic-code-intel-worker/worker.Deployment.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
annotations: | ||
description: High level syntax analysis | ||
labels: | ||
deploy: sourcegraph | ||
sourcegraph-resource-requires: no-cluster-admin | ||
app.kubernetes.io/component: syntactic-code-intel-worker | ||
name: syntactic-code-intel-worker | ||
spec: | ||
minReadySeconds: 10 | ||
replicas: 2 | ||
revisionHistoryLimit: 10 | ||
selector: | ||
matchLabels: | ||
app: syntactic-code-intel-worker | ||
strategy: | ||
rollingUpdate: | ||
maxSurge: 1 | ||
maxUnavailable: 1 | ||
type: RollingUpdate | ||
template: | ||
metadata: | ||
labels: | ||
deploy: sourcegraph | ||
app: syntactic-code-intel-worker | ||
spec: | ||
containers: | ||
- name: syntactic-code-intel-worker | ||
env: | ||
- name: SYNTACTIC_CODE_INTEL_BACKEND | ||
value: blobstore | ||
- name: SYNTACTIC_CODE_INTEL_UPLOAD_AWS_ENDPOINT | ||
value: http://blobstore:9000 | ||
- name: SYNTACTIC_CODE_INTEL_WORKER_ADDR | ||
value: ":3188" | ||
- name: POD_NAME | ||
valueFrom: | ||
fieldRef: | ||
fieldPath: metadata.name | ||
image: index.docker.io/sourcegraph/syntactic-code-intel-worker:6.0.0@sha256:50bdeb38b196f0fc21404969016bf8263f78144292e905867e93480f66c8251c | ||
terminationMessagePath: FallbackToLogsOnError | ||
livenessProbe: | ||
httpGet: | ||
path: /healthz | ||
port: debug | ||
scheme: HTTP | ||
initialDelaySeconds: 60 | ||
timeoutSeconds: 5 | ||
readinessProbe: | ||
httpGet: | ||
path: /ready | ||
port: debug | ||
scheme: HTTP | ||
periodSeconds: 5 | ||
timeoutSeconds: 5 | ||
ports: | ||
- containerPort: 3188 | ||
name: http | ||
- containerPort: 6060 | ||
name: debug | ||
resources: | ||
limits: | ||
cpu: "2" | ||
memory: 4G | ||
requests: | ||
cpu: 500m | ||
memory: 2G | ||
securityContext: | ||
allowPrivilegeEscalation: false | ||
runAsGroup: 101 | ||
runAsUser: 100 | ||
securityContext: | ||
fsGroup: 101 | ||
runAsUser: 100 | ||
fsGroupChangePolicy: OnRootMismatch |
23 changes: 23 additions & 0 deletions
23
base/sourcegraph/syntactic-code-intel-worker/worker.Service.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
annotations: | ||
prometheus.io/port: "6060" | ||
sourcegraph.prometheus/scrape: "true" | ||
labels: | ||
app: syntactic-code-intel-worker | ||
app.kubernetes.io/component: syntactic-code-intel-worker | ||
deploy: sourcegraph | ||
sourcegraph-resource-requires: no-cluster-admin | ||
name: syntactic-code-intel-worker | ||
spec: | ||
ports: | ||
- name: http | ||
port: 3188 | ||
targetPort: http | ||
- name: debug | ||
port: 6060 | ||
targetPort: debug | ||
selector: | ||
app: syntactic-code-intel-worker | ||
type: ClusterIP |