Kubernetes verison: 1.02
PATCH /api/v1/namespaces/default/replicationcontrollers/test
body
{"spec":
{"replicas": 3}
}
response
'{
"kind": "Status",
"apiVersion": "v1",
"metadata": {},
"status": "Failure",
"message": "the server responded with the status code 415 but did not return more information",
"details": {},
"code": 415
}'
Is this a bug for API?
For PATCH to work you need to send one of the accepted content-type header values.
Your example uses a merge patch, so you should send:
Content-Type: application/merge-patch+json