我们的场景下用 k8s 启动容器校验用户的 sql 是否正确,每个用户一个容器,可能同时有成百上千个用户在线,都通过 kubectl 在不同容器中执行脚本,偶发出现如下问题,困扰了许久没找到解决方案,请教 v 友们有没有熟悉这块的?不胜感激!
command:
kubectl exec mysql-8140296 bash run_sql.sh
output:
error: unable to upgrade connection: <head>
<title>Error response</title>
</head>
<body>
<h1>Error response</h1>
<p>Error code 501.
<p>Message: Unsupported method ('POST').
<p>Error code explanation: 501 = Server does not support this operation.
</body>