Open nergalex opened 3 years ago
@nergalex What version of this collection are you using? Is it the latest stable, v1.2?
Sorry, please find attached error ouput with community.kubernetes version: 1.2.0 (and not 1.1.1 in the previous message)
"msg": "Failed to load kubeconfig due to Invalid kube-config file. No configuration found."
@nergalex I am unable to reproduce this. Specifying the path to the kubeconfig file works for me.
I have this issue too. It's solved when I patched common.py in /usr/local/lib/python3.8/dist-packages/ansible_collections/community/kubernetes/plugins/module_utils/common.py on line 263.
#return DynamicClient(kubernetes.client.ApiClient(configuration))
return DynamicClient(kubernetes.config.new_client_from_config())
I don't know how to watch version, and have not time for this anymore. I can give more info, if needed and if someone tell me how to obtain it )
thx @belenot . I would not prefer to modify kubernetes ansible collection because it's loaded for each job by Tower (collections/requirements.yml is used).
@gravesm using a config.yaml file located in a AWX project, the module invocation differs:
Did you reproduced this behavior?
thx @belenot . I would not prefer to modify kubernetes ansible collection because it's loaded for each job by Tower (collections/requirements.yml is used).
I know @nergalex , that's why I just specified previous version of package for pip3 installation on remote host, namely openshift==0.11.0. This fixed my issue.
thx @belenot, same workaround :)
SUMMARY
Error encounter when using openshift 0.12 package and community.kubernetes.k8s. See attached file: error_with_openshift_0.12.json.txt community.kubernetes.k8s works well with openshift 0.11.2 pakage. See attached file: ok_with_openshift_0.11.2.json.txt error_with_openshift_0.12.json.txt ok_with_openshift_0.11.2.json.txt
ISSUE TYPE
COMPONENT NAME
community.kubernetes.k8s
ANSIBLE VERSION
Virtual Env with openshift 0.11.2 and 0.12.0 run both:
CONFIGURATION
OS / ENVIRONMENT
STEPS TO REPRODUCE
https://github.com/nergalex/f5-aks-nginx_ingress_app_protect/blob/master/playbooks/roles/poc-k8s/tasks/create_nap_log_format.yaml
EXPECTED RESULTS
See attached file: ok_with_openshift_0.11.2.json.txt
ACTUAL RESULTS
See attached file: ok_with_openshift_0.11.2.json.txt