@@ -26,27 +26,27 @@ def main():
2626 aToken = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
2727
2828 # Create a configuration object
29- configuration = client .Configuration ()
29+ aConfiguration = client .Configuration ()
3030
3131 # Specify the endpoint of your Kube cluster
32- configuration .host = "https://XXX.XXX.XXX.XXX:443"
32+ aConfiguration .host = "https://XXX.XXX.XXX.XXX:443"
3333
3434 # Security part.
3535 # In this simple example we are not going to verify the SSL certificate of
3636 # the remote cluster (for simplicity reason)
37- configuration .verify_ssl = False
37+ aConfiguration .verify_ssl = False
3838 # Nevertheless if you want to do it you can with these 2 parameters
3939 # configuration.verify_ssl=True
4040 # ssl_ca_cert is the filepath to the file that contains the certificate.
4141 # configuration.ssl_ca_cert="certificate"
4242
43- configuration .api_key = {"authorization" : "Bearer " + aToken }
43+ aConfiguration .api_key = {"authorization" : "Bearer " + aToken }
4444
45- # Use our configuration
46- client .Configuration . set_default ( configuration )
45+ # Create a ApiClient with our config
46+ aApiClient = client .ApiClient ( aConfiguration )
4747
4848 # Do calls
49- v1 = client .CoreV1Api ()
49+ v1 = client .CoreV1Api (aApiClient )
5050 print ("Listing pods with their IPs:" )
5151 ret = v1 .list_pod_for_all_namespaces (watch = False )
5252 for i in ret .items :
0 commit comments