Repository navigation
executors: set EXECUTOR_DEPLOY_TYPE in both executor charts - #1032
Draft
marcleblanc2 wants to merge 2 commits into
Draft
marcleblanc2 wants to merge 2 commits into
marcleblanc2 wants to merge 2 commits into
Conversation
This was referenced Nov 25, 2026
The k8s chart sets helm-k8s and the dind chart sets helm-dind, so pings report which chart deployed the executors.
The chart sets it, so a user env entry would add a duplicate key. Amp-Thread-ID: https://ampcode.com/threads/T-01a214e9-44e3-7480-898c-b3ec8d72df68 Co-authored-by: Amp <amp@ampcode.com>
marcleblanc2
force-pushed
the
marc/executor-deploy-type
branch
from
November 25, 2026 23:10
1487fc1 to
01623a8
Compare
This branch has not been deployed
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
We can't tell which customers deploy which kind of executor. Pings report only each executor's runtime mode (
docker,firecracker,kubernetes), so the Helm and Kustomize Docker-in-Docker charts, Docker Compose, and manual Docker installs all reportdocker, and Helm vs Kustomize or Terraform vs manual installs can't be told apart.Solution
Set
EXECUTOR_DEPLOY_TYPEon the executor container in both executor charts:sourcegraph-executor-k8s:helm-k8s, in the executor ConfigMapsourcegraph-executor-dind:helm-dind, in the executor container's envThe executor sends it to its Sourcegraph instance, and pings report it (sourcegraph#19875). Older executors ignore the variable. Not exposed as a value: it identifies the chart, so users have no reason to change it. The dind chart's
executor.validateEnvnow rejects it inexecutor.envandqueues[].env, like the other variables the chart sets, so a user entry can't add a duplicate key.Checklist
Test plan
helm unittestpasses for both charts; each now asserts the variable's value, and a dind test asserts thatexecutor.envcan't set it (it fails without thevalidateEnventry).helm lintpasses for both charts../scripts/helm-docs.shmakes no change (novalues.yamlchange).executor_heartbeatsstoredhelm-k8sandhelm-dind, and the instance's ping reported them asexecutorDeployType(details in sourcegraph#19875). The dind chart ran in a namespace with theprivilegedPod Security level, since m5 enforcesrestricted.Linked PRs
Each executor deployment method sets
EXECUTOR_DEPLOY_TYPE, the executor sends it to its Sourcegraph instance, and pings report it. Merge in this order:update_checksschema field; merge and apply to the live table before #19875 mergesEXECUTOR_DEPLOY_TYPE, instance stores it and reports it in pings; product docshelm-k8s,helm-dindkustomize-k8s,kustomize-dinddocker-composeterraform-awsterraform-gcpsourcegraph-cloud, for Sourcegraph Cloud-managed executorsbinary,binary-offlinein the Linux binary install examples; merge after the release that ships #198753 to 8 can merge in any order once #19875 has merged; older executors ignore the variable.
Amp threads
Changelog
Set
EXECUTOR_DEPLOY_TYPEtohelm-k8sin thesourcegraph-executor-k8schart andhelm-dindin thesourcegraph-executor-dindchart, so pings report which chart deployed the executors.