Manage secrets
RunSpecs and bundles contain Secret names, never values.
Prerequisites
Section titled “Prerequisites”- Permission to create Secrets in the runs namespace, or access to the Targets page.
Name a Secret you manage
Section titled “Name a Secret you manage”Create it in the runs namespace, then reference it:
kubectl -n servtuner create secret generic gateway-key --from-file=token=./tokenauth: secretRef: { name: gateway-key, key: token }The Kubernetes runner mounts each named Secret into the Job. With the subprocess runner in a cluster, list it in subprocess.secrets. For local bench, use --secrets-dir.
Save a key in servtuner
Section titled “Save a key in servtuner”Set a key on a saved target or host managed target. The route is write-only. servtuner stores it in a Kubernetes Secret and shows a masked preview.
secretStore |
Where keys live |
|---|---|
kubernetes |
Secrets in the runs namespace (chart default) |
none |
Nowhere. Saved targets cannot hold keys |
file |
Files in the data directory, for local development through SERVTUNER_SECRET_STORE only |
You can also record an external Secret by name, so your own tooling keeps managing its value.
Protect them
Section titled “Protect them”- Enable encryption at rest for Kubernetes Secrets.
- Limit who can reach the UI, because anyone who can may use a saved key.
- Do not put keys in labels, knobs, names, base flags or
engine.options. Those are recorded as written.
Run tokens are scoped to one run and expire. They are required in every transport mode.
Verify
Section titled “Verify”Run a connection check on the target. Its auth step confirms the key without showing it.
Next steps
Section titled “Next steps”Return to targets.