terraform-provider-talos icon indicating copy to clipboard operation
terraform-provider-talos copied to clipboard

wrong talos version after cluster deploy

Open ingvarrwvw opened this issue 8 months ago • 2 comments

HI! Provider version 0.7.1

Booting vm with talos iso 1.9.5 After cluster deploy vm rebooted and talos version - 1.9.2. In tf code image_factory not used.

ingvarrwvw avatar Mar 28 '25 10:03 ingvarrwvw

It's the common issue with understanding how Talos installation process work when booting from an ISO/PXE/...

When you boot an ISO, Talos runs in memory and doesn't (yet) install itself to the disk. The Talos version at this point is whatever the version is on the ISO.

When you apply the machine configuration, it contains the machine.install section which tells both where to install Talos (which disk to use) and the installer image, which is specific for any version of Talos.

The final version which is installed to disk is the version of the installer image.

Notes:

  • if you don't eject the ISO (or change the boot order), and Talos boots from an ISO while it's installed to disk, it would halt on boot
  • you can boot ISO of one version and install Talos of another version, which also includes a set of system extensions being used (when using an Image Factory).

For your specific question, you might need to ensure that you properly patch in the machine.install section with the installer image reference you need use.

smira avatar Mar 28 '25 14:03 smira

thanks for the detailed explanation!

When installing a cluster using talosctl (with default values), from the same iso 1.9.5 - I get a cluster 1.9.5. Therefore, I rightly expected that when installing by the provider, the result would be the same.

ingvarrwvw avatar Mar 28 '25 16:03 ingvarrwvw

It's the common issue with understanding how Talos installation process work when booting from an ISO/PXE/...

When you boot an ISO, Talos runs in memory and doesn't (yet) install itself to the disk. The Talos version at this point is whatever the version is on the ISO.

When you apply the machine configuration, it contains the machine.install section which tells both where to install Talos (which disk to use) and the installer image, which is specific for any version of Talos.

The final version which is installed to disk is the version of the installer image.

Notes:

  • if you don't eject the ISO (or change the boot order), and Talos boots from an ISO while it's installed to disk, it would halt on boot
  • you can boot ISO of one version and install Talos of another version, which also includes a set of system extensions being used (when using an Image Factory).

For your specific question, you might need to ensure that you properly patch in the machine.install section with the installer image reference you need use.

I also have this issue and I think I know what the problem is.

data "talos_machine_configuration" "controlplane" {
  cluster_name     = var.cluster_name
  machine_type     = "controlplane"
  cluster_endpoint = "https://1.2.3.4:6443"
  machine_secrets  = talos_machine_secrets.this.machine_secrets
  talos_version    = "1.10.6"
  kubernetes_version = "1.33.4"
}

Ends in "talos_version" = "1.10.6" and image: ghcr.io/siderolabs/installer:v1.11.0-alpha.0 when I output data.talos_machine_configuration.controlplane also with missing schematic hash by the way

Syntax3rror404 avatar Aug 29 '25 13:08 Syntax3rror404