Talos uses declarative configuration for clusters, but upgrades can cause drift between the declared machine configuration (files you keep in Git) and the deployed configuration (what’s actually running on your nodes). To prevent this drift, we recommend discarding full declared configuration files and instead using a patch-based workflow to regenerate machine configuration whenever you need them. To reliably regenerate reproducible machine configurations, that is, configurations that can be recreated consistently from the same source inputs, you’ll need the following inputs:Documentation Index
Fetch the complete documentation index at: https://docs.siderolabs.com/llms.txt
Use this file to discover all available pages before exploring further.
secrets.yaml: The cluster secrets generated once at cluster creation.- Patch files: Patches that describe the configuration differences you want from the defaults (e.g. custom networking, node labels, additional arguments). See Configuration Patches for more information.
- Cluster name and Kubernetes controlplane endpoint.
- Kubernetes version (
--kubernetes-version): The version your cluster runs right now. - Talos version (
--talos-version) contract: The Talos version you originally used to generate the machine configs. Keep this value fixed to ensure reproducibility.
Note: If you leave the Talos version contract unset, or change it to a newer version,With these inputs ready, follow the workflow below:talosctl gen configmay generate a different machine configuration that introduces new fields or defaults that did not exist in your original config. This can silently change cluster behavior and break reproducibility. Only update--talos-versionwhen you explicitly want to upgrade Talos.
Regenerate your machine configuration
To regenerate your machine configuration:-
Create new configs using your inputs (
secrets.yaml, patches, cluster name, and endpoint): - Apply the generated configs to your nodes.
- Discard the generated configs. Do not commit them, instead, regenerate them when needed.