Multi env support and Kube client integration
Kube friendly Beta
Package versions supports Kube env
Added:
- Env type detection
- New option: --use-env, for selecting env
when function supports multiple detected envs
- Updated config loading
- Each module and command type has supported env check
and stops execution if it is on unsupported env
- Functions can support multiple envs
- Kubernetes dependency
- Kubenernetes API detection: local and remote
- Package checking class hierachy for using Salt or Kube
- Remote pod execution routine
- Flexible SSH/SSH Forwarder classes: with, ssh,do(), etc
- Multithreaded SSH script execution
- Number of workers parameter, default 5
Fixed:
- Config dependency
- Command loading with supported envs list
- Unittests structure and execution flow updated
- Unittests fixes
- Fixed debug mode handling
- Unified command type/support routine
- Nested attrs getter/setter
Change-Id: I3ade693ac21536e2b5dcee4b24d511749dc72759
Related-PROD: PROD-35811
diff --git a/tests/res/_fake_kube_config.yaml b/tests/res/_fake_kube_config.yaml
new file mode 100644
index 0000000..5311671
--- /dev/null
+++ b/tests/res/_fake_kube_config.yaml
@@ -0,0 +1,19 @@
+apiVersion: v1
+clusters:
+- cluster:
+ certificate-authority-data: U3VwZXIgc2VjcmV0IGZha2UgY2VydGlmaWNhdGUgYXV0aG9yaXR5IQo=
+ server: https://192.168.0.1:6443
+ name: ucp_192.168.0.1:6443_admin
+contexts:
+- context:
+ cluster: ucp_192.168.0.1:6443_admin
+ user: ucp_192.168.0.1:6443_admin
+ name: ucp_192.168.0.1:6443_admin
+current-context: ucp_192.168.0.1:6443_admin
+kind: Config
+preferences: {}
+users:
+- name: ucp_192.168.0.1:6443_admin
+ user:
+ client-certificate-data: U3VwZXIgc2VjcmV0IGZha2UgY2VydGlmaWNhdGUhCg==
+ client-key-data: U3VwZXIgc2VjcmV0IGZha2Uga2V5IQo=
\ No newline at end of file