mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-09-26 11:34:20 -04:00
config: detailed validation errors for k8s version (#1018)
These extended error messages help users in understanding what is wrong with the current configuration and how to remediate the issue.
This commit is contained in:
parent
03154c6e64
commit
3b59ebfd53
2 changed files with 41 additions and 0 deletions
|
@ -489,6 +489,10 @@ func (c *Config) Validate() error {
|
|||
return err
|
||||
}
|
||||
|
||||
if err := validate.RegisterTranslation("supported_k8s_version", trans, registerInvalidK8sVersionError, translateInvalidK8sVersionError); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if err := validate.RegisterValidation("no_placeholders", validateNoPlaceholder); err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue