Open HarikrishnanBalagopal opened 3 years ago
This might be helpful: https://kubernetes.io/docs/reference/kubectl/overview/#operations https://www.mankier.com/1/kubectl-cluster-info-dump It outputs a lot of information and the format can be chosen (json, yaml, etc.).
Steps to reproduce
Note: This bug only occurs when collecting use the CLI. By default it will use the CLI only if the API fails.
move2kube collect -a k8s
Expected behaviour
Cluster metadata yaml should have:
Actual behaviour
Cluster metadata yaml has:
This also happens with
Pod
andNetworkPolicy
.This is an old bug that was never fixed.
Proposed Fix
The code that parses the CLI output needs to be looked at closely.
kubectl
returns human readable output, so the parsing code is fragile.