Fixing PEP8 issues
This commit is contained in:
parent
ec2cb57d96
commit
d687562608
1 changed files with 8 additions and 18 deletions
|
@ -105,22 +105,10 @@ def get_client(kubeconfig, context):
|
||||||
|
|
||||||
|
|
||||||
k8s_types = {
|
k8s_types = {
|
||||||
"deployments": {
|
"deployments": {"function": get_deployments, "api": get_extensions},
|
||||||
"function": get_deployments,
|
"services": {"function": get_services, "api": get_core_api_v1},
|
||||||
"api": get_extensions
|
"pods": {"function": get_pods, "api": get_core_api_v1},
|
||||||
},
|
"ingresses": {"function": get_ingresses, "api": get_extensions},
|
||||||
"services": {
|
|
||||||
"function": get_services,
|
|
||||||
"api": get_core_api_v1
|
|
||||||
},
|
|
||||||
"pods": {
|
|
||||||
"function": get_pods,
|
|
||||||
"api": get_core_api_v1
|
|
||||||
},
|
|
||||||
"ingresses": {
|
|
||||||
"function": get_ingresses,
|
|
||||||
"api": get_extensions
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -130,7 +118,9 @@ def main():
|
||||||
api = None
|
api = None
|
||||||
if parser.type in k8s_types.keys():
|
if parser.type in k8s_types.keys():
|
||||||
api = k8s_types[parser.type]["api"](_client)
|
api = k8s_types[parser.type]["api"](_client)
|
||||||
k8s_object_list = k8s_types[parser.type]["function"](api, parser.namespace)
|
k8s_object_list = k8s_types[parser.type]["function"](
|
||||||
|
api, parser.namespace
|
||||||
|
)
|
||||||
print_list(k8s_object_list)
|
print_list(k8s_object_list)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue