Closed marcincuber closed 4 years ago
This is an issue where lambda doesn't support Kubernetes 1.16+.
I was just about to ask, what version you were using. I'll look into what's required to support the new version but I think this might be a better solution the problem now:
Hi, I was using the latest code in this repo.
With regards to aws-node-termination-handler, I am already using for spot interruption. However, feature that I need only exists in feature request https://github.com/aws/aws-node-termination-handler/issues/141.
Basically with the current code the issue is that api.create_namespaced_pod_eviction(pod.metadata.name + '-eviction', pod.metadata.namespace, body)
doesn't work for EKS 1.16. It should simply be api.create_namespaced_pod_eviction(pod.metadata.name, pod.metadata.namespace, body)
Oh that's interesting, I didn't realise it had that constraint. Thank you for bringing it to my attention.
@svozza if you have any influence on the priorities for feature requests around aws-node-termination-handler then the above mentioned one is an absolute must for me.
Has there been a resolution to this or otherwise could we re-open the issue? Currently this lambda handles events that the NTH doesn't and it seems their current plan failed and is delayed so this is still our best bet.
Would it be OK to just release the current version as 0.1.0
, make the change @marcincuber suggested and release as 0.2.0
with a README clarifying it (sorry, I'm unclear whether this is breaking from k8s 1.15 or not)?
@mitom it is not a breaking change. Function just requires to check what version of kubernetes is used and then make an appropriate call based on that.
Reopening an issue
I'd be happy to accept a pull request if it's just a small change.
I believe this is fixed in https://github.com/aws-samples/amazon-k8s-node-drainer/pull/30 so closing this issue.
I am getting following error. Any ideas how to fix it? Currently, lambda can't evict any pods.