siderolabs / talos

Talos Linux is a modern Linux distribution built for Kubernetes.
https://www.talos.dev
Mozilla Public License 2.0
6k stars 488 forks source link

Use values from documentation for validation #4435

Closed AlekSi closed 1 week ago

AlekSi commented 2 years ago

Our docgen tool allows us to document valid values like that:

    //   values:
    //     - "init"
    //     - "controlplane"
    //     - "worker"
    MachineType string `yaml:"type"`

Those values are accumulated there:

// Doc represents a struct documentation rendered from comments by docgen.
type Doc struct {
    // Values is only used to render valid values list in the documentation.
    Values []string

I wonder if we could use those values not only in the documentation but also in config validation.

github-actions[bot] commented 2 weeks ago

This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] commented 1 week ago

This issue was closed because it has been stalled for 7 days with no activity.