0

我试图修改我的入口,因为我的入口控制器和入口服务在 nginx-ingress 名称空间中运行。

我尝试使用:kubectl edit ing lhingress其中入口名称是 lhingress。它打开了一个编辑器,但是当我尝试修改然后保存它时。我得到以下错误。

error: the namespace from the provided object "nginx-ingress" does not match the namespace "default". You must pass '--namespace=nginx-ingress' to perform this operation.

您能否建议我如何将此入口指向不同的命名空间

4

1 回答 1

2

您不能更改现有对象的命名空间。您需要在另一个命名空间中创建一个新资源并删除旧资源。

于 2018-02-14T06:15:40.867 回答