From a3cf4164755609e80de5dafa2c49bfaa0fc655fd Mon Sep 17 00:00:00 2001 From: Dzerom Dzenkins Date: Tue, 28 Feb 2023 22:57:28 +0100 Subject: [PATCH] docs: add InstallConfig ignored notice to doc Mention that `.machine.install` gets ignored on pre-installed images. Signed-off-by: Dzerom Dzenkins Signed-off-by: Andrey Smirnov --- .../types/v1alpha1/schemas/v1alpha1_config.schema.json | 6 +++--- pkg/machinery/config/types/v1alpha1/v1alpha1_types.go | 3 +++ pkg/machinery/config/types/v1alpha1/v1alpha1_types_doc.go | 2 +- website/content/v1.4/reference/configuration.md | 2 +- website/content/v1.4/schemas/v1alpha1_config.schema.json | 6 +++--- 5 files changed, 11 insertions(+), 8 deletions(-) diff --git a/pkg/machinery/config/types/v1alpha1/schemas/v1alpha1_config.schema.json b/pkg/machinery/config/types/v1alpha1/schemas/v1alpha1_config.schema.json index 8a32037ff..097a5f0a0 100644 --- a/pkg/machinery/config/types/v1alpha1/schemas/v1alpha1_config.schema.json +++ b/pkg/machinery/config/types/v1alpha1/schemas/v1alpha1_config.schema.json @@ -1808,9 +1808,9 @@ "install": { "$ref": "#/$defs/InstallConfig", "title": "install", - "description": "Used to provide instructions for installations.\n", - "markdownDescription": "Used to provide instructions for installations.", - "x-intellij-html-description": "\u003cp\u003eUsed to provide instructions for installations.\u003c/p\u003e\n" + "description": "Used to provide instructions for installations.\n\nNote that this configuration section gets silently ignored by Talos images that are considered pre-installed.\nTo make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted.\n", + "markdownDescription": "Used to provide instructions for installations.\n\nNote that this configuration section gets silently ignored by Talos images that are considered pre-installed.\nTo make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted.", + "x-intellij-html-description": "\u003cp\u003eUsed to provide instructions for installations.\u003c/p\u003e\n\n\u003cp\u003eNote that this configuration section gets silently ignored by Talos images that are considered pre-installed.\nTo make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted.\u003c/p\u003e\n" }, "files": { "items": { diff --git a/pkg/machinery/config/types/v1alpha1/v1alpha1_types.go b/pkg/machinery/config/types/v1alpha1/v1alpha1_types.go index 26aaec3a8..347201112 100644 --- a/pkg/machinery/config/types/v1alpha1/v1alpha1_types.go +++ b/pkg/machinery/config/types/v1alpha1/v1alpha1_types.go @@ -747,6 +747,9 @@ type MachineConfig struct { MachineDisks []*MachineDisk `yaml:"disks,omitempty"` // Note: `size` is in units of bytes. // description: | // Used to provide instructions for installations. + // + // Note that this configuration section gets silently ignored by Talos images that are considered pre-installed. + // To make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted. // examples: // - name: MachineInstall config usage example. // value: machineInstallExample diff --git a/pkg/machinery/config/types/v1alpha1/v1alpha1_types_doc.go b/pkg/machinery/config/types/v1alpha1/v1alpha1_types_doc.go index dc811ec80..886325c1f 100644 --- a/pkg/machinery/config/types/v1alpha1/v1alpha1_types_doc.go +++ b/pkg/machinery/config/types/v1alpha1/v1alpha1_types_doc.go @@ -215,7 +215,7 @@ func init() { MachineConfigDoc.Fields[9].Name = "install" MachineConfigDoc.Fields[9].Type = "InstallConfig" MachineConfigDoc.Fields[9].Note = "" - MachineConfigDoc.Fields[9].Description = "Used to provide instructions for installations." + MachineConfigDoc.Fields[9].Description = "Used to provide instructions for installations.\n\nNote that this configuration section gets silently ignored by Talos images that are considered pre-installed.\nTo make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted." MachineConfigDoc.Fields[9].Comments[encoder.LineComment] = "Used to provide instructions for installations." MachineConfigDoc.Fields[9].AddExample("MachineInstall config usage example.", machineInstallExample) diff --git a/website/content/v1.4/reference/configuration.md b/website/content/v1.4/reference/configuration.md index e6552293f..0220e3cc5 100644 --- a/website/content/v1.4/reference/configuration.md +++ b/website/content/v1.4/reference/configuration.md @@ -258,7 +258,7 @@ disks: # # Precise value in bytes. # size: 1073741824 {{< /highlight >}} | | -|`install` |InstallConfig |Used to provide instructions for installations.
Show example(s){{< highlight yaml >}} +|`install` |InstallConfig |
Used to provide instructions for installations.
Note that this configuration section gets silently ignored by Talos images that are considered pre-installed.
To make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted.
Show example(s){{< highlight yaml >}} install: disk: /dev/sda # The disk used for installations. # Allows for supplying extra kernel args via the bootloader. diff --git a/website/content/v1.4/schemas/v1alpha1_config.schema.json b/website/content/v1.4/schemas/v1alpha1_config.schema.json index 8a32037ff..097a5f0a0 100644 --- a/website/content/v1.4/schemas/v1alpha1_config.schema.json +++ b/website/content/v1.4/schemas/v1alpha1_config.schema.json @@ -1808,9 +1808,9 @@ "install": { "$ref": "#/$defs/InstallConfig", "title": "install", - "description": "Used to provide instructions for installations.\n", - "markdownDescription": "Used to provide instructions for installations.", - "x-intellij-html-description": "\u003cp\u003eUsed to provide instructions for installations.\u003c/p\u003e\n" + "description": "Used to provide instructions for installations.\n\nNote that this configuration section gets silently ignored by Talos images that are considered pre-installed.\nTo make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted.\n", + "markdownDescription": "Used to provide instructions for installations.\n\nNote that this configuration section gets silently ignored by Talos images that are considered pre-installed.\nTo make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted.", + "x-intellij-html-description": "\u003cp\u003eUsed to provide instructions for installations.\u003c/p\u003e\n\n\u003cp\u003eNote that this configuration section gets silently ignored by Talos images that are considered pre-installed.\nTo make sure Talos installs according to the provided configuration, Talos should be booted with ISO or PXE-booted.\u003c/p\u003e\n" }, "files": { "items": {