Closed g3rzi closed 5 years ago
Currently KubiScan is running on the current context (kubectl config current-context) but sometimes there are more contexts. For example, when using minishift:
kubectl config current-context
root@ubuntu:~/KubiScan# kubectl config get-contexts CURRENT NAME CLUSTER AUTHINFO NAMESPACE minikube minikube minikube * minishift 192-168-42-132:8443 developer/192-168-42-132:8443 myproject myproject/192-168-42-132:8443/developer 192-168-42-132:8443 developer/192-168-42-132:8443 myproject myproject/192-168-42-132:8443/system:admin 192-168-42-132:8443 system:admin/192-168-42-132:8443 myproject
The current workaround is to set a new current context with use-context: kubectl config use-context minikube
use-context
kubectl config use-context minikube
We want to give kubiscan an option to do it without changed the current context.
Tested the changes, works fine. Example: root@ubuntu:~/KubiScan# python3 KubiScan.py -ctx myproject/192-168-42-132:8443/system:admin -rs
root@ubuntu:~/KubiScan# python3 KubiScan.py -ctx myproject/192-168-42-132:8443/system:admin -rs
Currently KubiScan is running on the current context (
kubectl config current-context
) but sometimes there are more contexts.For example, when using minishift:
The current workaround is to set a new current context with
use-context
:kubectl config use-context minikube
We want to give kubiscan an option to do it without changed the current context.