-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
🐛 Don't return error if cannot find default config #2951
🐛 Don't return error if cannot find default config #2951
Conversation
/assign @fabriziopandini |
f94809d
to
11e0d6f
Compare
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.
@wfernandes thanks for fixing this!
just a question to see if we can avoid the workaround for spf13/viper#900 ...
73889aa
to
9aae26a
Compare
9aae26a
to
a2848eb
Compare
If clusterctl default config under $HOME/.cluster-api/clusterctl.yaml doesn't exist, commands like clusterctl init should still work. However, it should still return errors if the contents of the config file is unparsable. If no path is specified and if there is no default config available, just skip reading in the config
a2848eb
to
13272a8
Compare
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.
/approve
Thanks for all this improvements @wfernandes
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: fabriziopandini, wfernandes 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 |
/milestone v0.3.4 |
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.
/lgtm
What this PR does / why we need it:
If clusterctl default config under $HOME/.cluster-api/clusterctl.yaml
doesn't exist, commands like clusterctl init should still work.
However, it should still return errors if the contents of the config file is unparsable.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #2947