Skip to content

API can be streamlined: assume same key for some EnvVarSource #132195

@thockin

Description

@thockin

https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/api/core/v1/types.go#L2376

All EnvVarSource must specify name in the parent, but the ConfigMapKeyRef and SecretKeyRef fields both require a key to be specified. kubernetes/enhancements#5384 introduces another case.

It seems like we could assume the env var's name if the key is not specified. One less line of YAML in many cases.

It would require a feature gate which means a (small) KEP.

Impl is in pkg/kubelet/kubelet_pods.go

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/apiIndicates an issue on api area.help wantedDenotes an issue that needs help from a contributor. Must meet "help wanted" guidelines.kind/featureCategorizes issue or PR as related to a new feature.needs-triageIndicates an issue or PR lacks a `triage/foo` label and requires one.priority/backlogHigher priority than priority/awaiting-more-evidence.sig/nodeCategorizes an issue or PR as relevant to SIG Node.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions