Adopt an agent
Adoption keeps the agent’s identity, history and credentials. If the result is the same as what runs, no pod restarts; if not, the pods roll, and a new pod starts before an old one stops. Koperator reports the values you set on each release, but never the inline worker token or LLM key. A value set inline inenv that looks like a secret, for example GITHUB_TOKEN, is sent as
<redacted-by-koperator>, and KAOP refuses to adopt that agent until you move the value to a
Secret. To adopt it without a Secret, set discovery.reportInlineSecrets: true; koperator then sends
those values, and KAOP stores them with the agent.
What adoption does to Helm
Koperator takes the agent over from its Helm release so that the two never fight over it. It removes Helm’s ownership annotations and labels from the agent’s objects, and it relabels each release Secret fromowner=helm to owner=koperator-adopted, which it keeps as a backup. After the
adoption:
helm listdoes not show the release.helm uninstallfails withrelease: not foundand deletes nothing.helm upgrade --installfails withinvalid ownership metadataand changes nothing.
Give an agent back to Helm
First make sure koperator no longer manages the agent, for example by uninstalling koperator withuninstall.policy: keep (see Uninstall koperator).
Then restore the release Secrets and Helm’s ownership:
helm list and helm history show the release again. The other two let
helm upgrade change the objects again. With Helm 4, add --force-conflicts to the first
helm upgrade if you stopped koperator some other way than a keep uninstall.
Next steps
Argo CD and Flux
Run koperator under a GitOps tool, and handle drift.
Uninstall koperator
Choose what happens to the agents when koperator goes away.