-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[installer]: correct the starts_with validation on the config #7206
Conversation
The validation was just being printed to terminal, not passed into the validation result.
Codecov Report
@@ Coverage Diff @@
## main #7206 +/- ##
=====================================
Coverage 5.76% 5.76%
=====================================
Files 13 13
Lines 1162 1162
=====================================
Hits 67 67
Misses 1094 1094
Partials 1 1
Flags with carried forward coverage won't be shown. Click here to find out more. Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test passed:
gitpod /workspace/gitpod/installer $ installer validate config -c config
{
"valid": false,
"fatal": [
"Field 'Config.Workspace.Runtime.ContainerDRuntimeDir' must start with '/'"
]
}
Error: configuration invalid
Usage:
gitpod-installer validate config [flags]
Flags:
-h, --help help for config
Global Flags:
-c, --config string path to the config file
--debug-version-file string path to a version manifest - not intended for production use
Error: configuration invalid
gitpod /workspace/gitpod/installer $ echo $?
1
gitpod /workspace/gitpod/installer $
LGTM label has been added. Git tree hash: c33d780bd0748f78045ce7674e731af85805d825
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: princerachit Associated issue: #7205 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Description
The validation was just being printed to terminal, not passed into the validation result. This corrects the mistake
Related Issue(s)
Fixes #7205
How to test
installer init > config.yaml
/
at the start ofworkspace.runtime.containerdRuntimeDir
installer validate config -c config.yaml
This should now bring the validation error out and exit with non-zero
Release Notes
Documentation