在 Azure 容器实例上执行命令时,错误“...websocket/_app.py”,第 345 行,在 _callback 中
Error "...websocket/_app.py", line 345, in _callback" when executing command on Azure Container Instance
当我在德国中西部创建容器实例时
az container create -n aci-hello-world -g myRG -l germanywestcentral --image mcr.microsoft.com/azuredocs/aci-helloworld
然后尝试执行任何命令
az container exec -n aci-hello-world -g myRG --exec-command "ls"
命令未执行并记录了这些错误:
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\websocket/_app.py", line 345, in _callback
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/container/custom.py", line 644, in _on_ws_msg
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\websocket/_app.py", line 345, in _callback
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/container/custom.py", line 644, in _on_ws_msg
在另一个区域启动同一个容器实例
az container create -n aci-hello-world -g myRG -l westeurope --image mcr.microsoft.com/azuredocs/aci-helloworld
有效。
挣扎了一段时间后,我打开了一个支持案例,ACI 似乎有两种部署模式:k8s 和 Atlas。如果容器实例是在 Atlas 背板上创建的,az container exec
不工作。
这是官方声明:
"The issue is seen on Atlas deployments, germanywestcentral is an Atlas-only region. And the issue is a failed exec command that only occurs when the deployment is on Atlas, it works in other regions on k8s.
If you want to need to mitigate the issue then we could blacklist your subscription to prevent deployments from landing on Atlas. However, germanycentralwest is an Atlas only region, so you would no longer be able to deploy container groups to this region."
当我在德国中西部创建容器实例时
az container create -n aci-hello-world -g myRG -l germanywestcentral --image mcr.microsoft.com/azuredocs/aci-helloworld
然后尝试执行任何命令
az container exec -n aci-hello-world -g myRG --exec-command "ls"
命令未执行并记录了这些错误:
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\websocket/_app.py", line 345, in _callback
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/container/custom.py", line 644, in _on_ws_msg
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\websocket/_app.py", line 345, in _callback
File "D:\a\s\build_scripts\windows\artifacts\cli\Lib\site-packages\azure/cli/command_modules/container/custom.py", line 644, in _on_ws_msg
在另一个区域启动同一个容器实例
az container create -n aci-hello-world -g myRG -l westeurope --image mcr.microsoft.com/azuredocs/aci-helloworld
有效。
挣扎了一段时间后,我打开了一个支持案例,ACI 似乎有两种部署模式:k8s 和 Atlas。如果容器实例是在 Atlas 背板上创建的,az container exec
不工作。
这是官方声明:
"The issue is seen on Atlas deployments, germanywestcentral is an Atlas-only region. And the issue is a failed exec command that only occurs when the deployment is on Atlas, it works in other regions on k8s. If you want to need to mitigate the issue then we could blacklist your subscription to prevent deployments from landing on Atlas. However, germanycentralwest is an Atlas only region, so you would no longer be able to deploy container groups to this region."