"options" generates unnecessary values on TektonConfig CR
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 608
- Forks
- 263
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 125
Description
we have options under all the components.
User can update or create a resources with options as mentioned in https://tekton.dev/docs/operator/tektonconfig/#additional-fields-as-options
It is not mandatory to update all the fields, however GoLang struct[1] generates default data type values on TektonConfig CR.
This leads confusion on user point of view.
Expected:
Should not add struct default values on TektonConfig CR. keep only what user added.
Current Behavior:
Entered:
options:
disabled: false
horizontalPodAutoscalers:
tekton-pipelines-webhook:
spec:
minReplicas: 2
Generated:
options:
disabled: false
horizontalPodAutoscalers:
tekton-pipelines-webhook:
metadata:
creationTimestamp: null
spec:
maxReplicas: 0
minReplicas: 2
scaleTargetRef:
kind: ""
name: ""
status:
currentMetrics: null
desiredReplicas: 0
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with pkg/apis/operator/v1alpha1/additional_options.go at the linked options structs, then trace how TektonConfig resources are serialized and generated. Reproduce the YAML example and verify that omitted option fields are not written to the resulting TektonConfig CR while explicitly provided values remain.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- devops
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100