gpt4 book ai didi

macos - 错误 : there was a problem with the editor "vi" -- while trying to edit a deployment file in a cluster

转载 作者:行者123 更新时间:2023-12-02 16:06:04 27 4
gpt4 key购买 nike

遇到这个错误error: there was a problem with the editor "vi" when trying to change a deployment file in the Kubernetes cluster (AKS)

kubectl edit deploy xxxxx -o yaml

退出文件后,抛出以下错误且未应用任何更改。

此问题仅在尝试编辑此特定部署时出现。似乎对其他文件更改工作正常

几张截图...

enter image description here

enter image description here

最佳答案

问题是 kubectl 使用的是 vi 而不是 vim。

解析运行(或添加到您的 .bashrc 或 .bash_profile):

export EDITOR=vim

然后运行您的 kubectl edit 命令。

享受吧。

关于macos - 错误 : there was a problem with the editor "vi" -- while trying to edit a deployment file in a cluster,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/69363317/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com