kubectl – update manifest of a kubernetes object

I have a k8s cluster and I have to update metrics-server (in the kube-system) namespace. I’ve tried to:

kubectl apply -n kube-system -f my-updated-metrics-server.yaml

and

kubectl replace -n kube-system -f my-updated-metrics-server.yaml

without success. What happens is that the deployment gets updated but then after a while (10-15 min), it gets to the previous status (before the apply/replace commands).

any thoughts?

UPDATED (as requested)

$ kubectl get ns |grep -iE 'argo|flux'
$

Read more here: Source link