Skip to content
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

A better way to generate default status #2

Open
1 task
liubog2008 opened this issue Jan 23, 2020 · 0 comments
Open
1 task

A better way to generate default status #2

liubog2008 opened this issue Jan 23, 2020 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@liubog2008
Copy link
Owner

liubog2008 commented Jan 23, 2020

Summary

Now we use kubebuilder:default to generate default value. However, it is not suitable for a complex type which needs a long comment.

It's not clear and hard to check and test.

Example

type Status struct {
    // +kubebuilder:default={{type:"A"},{type:"B"},{type:"C"},...}
    Conditions []Condition
}

Expected

  • Auto generate default field in CRD by writing an initialize function.
@liubog2008 liubog2008 added the enhancement New feature or request label Jan 23, 2020
@liubog2008 liubog2008 self-assigned this Jan 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant