talosctl apply full replacement in Talos OS v1.6.0 limits repeatable development environments
0 reputation · 15 Nov 2022, 03:22 UTC
0 reputation · 15 Nov 2022, 03:22 UTC
Goal is a repeatable development environment on Talos OS v1.6.0 where cluster configuration can be reapplied consistently with minimal side effects.
talosctl apply is documented as performing a full replacement of the cluster configuration in v1.6.0. The command does not merge incremental changes, and the official documentation does not list a --patch or --merge option. talosctl generate scaffolds configuration files but provides no diff or merge assistance for identifying changed sections.
With full replacement as the only documented behavior, it is unclear how safe repeatable applies are for small edits and whether future releases will introduce incremental update support.
Will Talos introduce a flag or mechanism to apply only differences between current and new configuration? Is there documented guidance for repeatable applies that avoids unnecessary reconfiguration in v1.6.0? Does the full-replace behavior apply uniformly across all configuration sections in this version?
35275 reputation · 15 Nov 2022, 12:13 UTC
In Talos OS v1.6.0, talosctl apply pushes a full configuration state to the node. There is no documented --patch or --merge flag in v1.6.0, and talosctl generate provides scaffolding without diff or merge assistance. The reception behavior is a full replacement; the execution impact is selective based on what changed. There is no confirmed public guidance that a delta-only apply flag will be introduced, and future release plans are not verified in this context. Full-replace reception is uniform, but impact varies by section.
talosctl apply in v1.6.0 transmits the entire desired configuration file rather than YAML key deltas. The Talos API compares the incoming state to the running state and decides which components need updates. Repeatable applies are supported by maintaining a single source of truth and reapplying the complete file. Some changes are applied dynamically, others require service restarts or node reboots. No native --patch flag exists in v1.6.0, so external diffing is required before apply.
The system is state-based. A full file is expected so the node can converge to the declared state. Because the API performs value comparison internally, reapplying an unchanged file is expected to be a no-op for most sections, but applying a file that contains defaults different from the running state can trigger restarts. This is a likely behavior pattern, not a verified guarantee for all sections.
talosctl get machineconfig -n <node-ip> > current_config.yamldiff current_config.yaml desired_config.yamltalosctl apply-config -n <node-ip> -f desired_config.yamltalosctl logs -n <node-ip> -fReception is uniform: the whole config is replaced. Impact is not uniform. Network and cluster settings often update dynamically or via service restart. Kernel arguments and boot settings typically require a node reboot. Disk and partitioning changes may require destructive actions. Behavior may vary slightly between control plane and worker schemas in v1.6.0.
Missing diagnostic detail: which configuration sections are edited most frequently in your workflow, e.g., machine.network, cluster.apiServer, machine.kernel. That changes the risk assessment for reboots and restart frequency.
Use comments to ask for clarification. Post a solution as an answer.
35,275 reputation · 15 Nov 2022, 14:31 UTC
In Talos OS v1.6.0, “full replacement” means talosctl apply submits the complete configuration document as the desired state; it does not necessarily rewrite every field or restart every service. The Talos agent compares the submitted document against the running machine config and converges only differing sections, though changes to boot, network, or kernel parameters can still force a node reboot. Because there is no built-in --patch or --diff flag, keep configuration files in version control and compare talosctl get machineconfig output before and after each apply to verify which sections actually changed.