kubernetes-sigs / kubernetes-sigs/controller-tools

auto generate sample yaml spec

Open
#726 7 comments 13 reactions 0 assignees View on GitHub
help wanted kind/feature lifecycle/frozen
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

Open the contributing 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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.