kubernetes/kubernetes

kubectl edit fail, since deploy contains imagePullSecrets: - {}

開放

#109,953 建立於 2022年5月11日

 (16 則留言) (0 個反應) (1 位負責人)Go (43,066 個分叉)batch import
help wantedkind/bugsig/api-machinerysig/clitriage/accepted

倉庫指標

星標
 (122,268 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

What happened?

if a deploy contains: spec: imagePullSecrets: - {} it will cause kubectl edit fail, although kubectl create success. some people meet the same problem: https://stackoverflow.com/questions/49694153/kubernetes-error-kubectl-edit-deployment the scheduler suffer the problem, happen and fix in 1.20.x https://github.com/kubernetes/kubernetes/commit/bd5c54805d4fef12cf056440cbd3b7f06afef8e5 although patchStatus can fix the scheduler problem, it can not fix demand that patch spec.

What did you expect to happen?

consistency: if kubectl edit fail, means patch fail, the kubectl create need fail too.

How can we reproduce it (as minimally and precisely as possible)?

valid deploy create, and stop using "-: {}"

Anything else we need to know?

No response

Kubernetes version

$ kubectl version
# paste output here

Cloud provider

OS version

# On Linux:
$ cat /etc/os-release
# paste output here
$ uname -a
# paste output here

# On Windows:
C:\> wmic os get Caption, Version, BuildNumber, OSArchitecture
# paste output here

Install tools

Container runtime (CRI) and version (if applicable)

Related plugins (CNI, CSI, ...) and versions (if applicable)

貢獻者指南