kubernetes-sigs / kubernetes-sigs/controller-tools
auto generate sample yaml spec
- Dominant language
- Go
- Stars
- 868
- Forks
- 482
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 8
Description
/kind feature
This this my api type:
```
// BridgeSpec defines the desired state of Bridge
type BridgeSpec struct {
// INSERT ADDITIONAL SPEC FIELDS - desired state of cluster
// Important: Run "make" to regenerate code after modifying this file
VpcName string `json:"vpcname"`
// ovn-nbctl set Logical_Switch vpc1 other_config:subnet=172.66.1.10/24
Subnet string `json:"subnet"`
Gateway string `json:"gateway"`
}
```
After generating yamls:
```
make && make install && make run
```
```
apiVersion: infra.genos.io/v1
kind: Bridge
metadata:
name: bridge-sample
spec:
# Add fields here
foo: bar
```
The spec is `foo:bar`, auto-generate spec may be more convenience
Contributor guide
Research direction
Start by reading the BridgeSpec example and the repository's existing generation workflow referenced by the `make` command. Determine how generated sample YAML is currently produced and what output should be derived from the spec fields rather than the placeholder `foo: bar`. Done means the requested sample spec is generated consistently and the documented `make && make install && make run` workflow still works.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100