Skip to content

Recieving Status Code 415: Unsupported Media Type when calling patchNamespacedIngress #440

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
SeanM96 opened this issue Apr 30, 2020 · 3 comments

Comments

@SeanM96
Copy link

SeanM96 commented Apr 30, 2020

I am trying to update an existing ingress with new parameters using the above mentioned method. Everytime I call it though, I hit line 758 in networkingV1beta1Api.js. I am calling the method with the ingress name, namespace, config and pretty print.

k8sIngressApi.patchNamespacedIngress('myingressname', 'myingressnamespace, config, true).then(result => { return console.log(JSON.stringify(result, null, 2)); });

I am able to create ingresses fine, it's just updating them that is causing issues.

@brendandburns
Copy link
Contributor

The content type is likely not correct. you need it to be something like application/merge-patch+json

@SeanM96 SeanM96 closed this as completed May 1, 2020
@SeanM96
Copy link
Author

SeanM96 commented May 1, 2020

Applied custom headers to the options parameter of { 'content-type': 'application/strategic-merge-patch+json' };

@Morriz
Copy link

Morriz commented May 25, 2020

Why is this not inferred?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants