Closed wfernandes closed 3 years ago
/milestone v0.3.x
/milestone v0.4.0
@wfernandes Hi, I would like to work on this.
/assign
Thanks @prankul88 ! /lifecycle active
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale
.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close
.
Send feedback to sig-testing, kubernetes/test-infra and/or fejta. /lifecycle stale
/remove-lifecycle stale
@prankul88 Are you still interested in tackling this issue?
@vincepri Yes, had left it due to some issues. Would like to give it a shot once this week.
@wfernandes Hi, I wanted a suggestion from you, if you can help. To fetch the default values from the template should I prefer making a separate function (Eg, func DefaultValues) and use it here or rather make Variables a map instead of a string to allow it to store default values.
I am facing some doubt on how to fetch the "Param" from envsubst package after traversing. Working on it..
@prankul88 Changing the Variables() []string
definition would mean a change in the interface and which is not ideal but it may not be a non-blocker for v0.4.x since the main clusterctl API wouldn't be affected (I think).
I suggest moving towards the first option for now and see what the reviewers think. Some points to also think about is ensuring the list of variables is ordered so it's easier for users to look at. That is, iterating through a map is unordered and it could be difficult for users to see a different ordered list every time they print out the list.
FYI, I'm currently no longer on this project and won't be involved in further PR reviews. I suggest reaching out to other maintainers/reviewers (e.g. @fabriziopandini) to get their opinion.
Again, thanks for working on this 🙂
@wfernandes Thanks for the feedback !! :)
@prankul88 are you working to this issue? @CecileRobertMichon recently filed with an interesting variation of this request. do you mind if I close this issue in favour of the new one?
Ah sorry, I searched for existing issues but didn't see this issue before opening mine. I'm fine with copying my proposal here as a comment too if we want to keep history.
/close
@CecileRobertMichon: Closing this issue.
User Story
As a developer/user/operator I would like to see more details when I list the variables of a template yaml using clusterctl so that I know what values will be used and what values I need to specify.
Detailed Description Currently, This is the output of a clusterctl command with
--list-variables
:This is great. But now that we have support for default values
${VAR:=defaultValue}
it would be nice to also view the default values that may be specified in the template.Anything else you would like to add: Extra bonus: It would also be nice to know which variables I may need to yet specify. That is, out of these variables,
AWS_CONTROL_PLANE_MACHINE_TYPE
,AWS_NODE_MACHINE_TYPE
,AWS_SSH_KEY_NAME
I may only have setupAWS_SSH_KEY_NAME
in myclusterctl.yaml
config.A suggestion could be simply to display a table format such that the blank/empty values are the ones that may be required. This way we could gain insight into what default values are being used and also what values are missing that I may still need to configure.
/kind feature /area clusterctl