Skip to content

[Bug]: kubernetes.config.config_exception.ConfigException: File does not exist: /root/.minikube/ca.crt #135

@Bhithashri385

Description

@Bhithashri385

Description

uv run krkn_ai run -vv -r krknhub -c ./krkn-ai.yaml -o ./results -p HOST=$HOST
/root/krkn-ai/.venv/lib64/python3.9/site-packages/google/auth/init.py:54: FutureWarning: You are using a Python version 3.9 past its end of life. Google will update google-auth with critical bug fixes on a best-effort basis, but not with any other fixes or features. Please upgrade your Python version, and then update google-auth.
warnings.warn(eol_message.format("3.9"), FutureWarning)
/root/krkn-ai/.venv/lib64/python3.9/site-packages/google/oauth2/init.py:40: FutureWarning: You are using a Python version 3.9 past its end of life. Google will update google-auth with critical bug fixes on a best-effort basis, but not with any other fixes or features. Please upgrade your Python version, and then update google-auth.
warnings.warn(eol_message.format("3.9"), FutureWarning)
[INFO] Initialized config: ./krkn-ai.yaml
[DEBUG] Initializing Prometheus client: http://192.168.49.2:30900
[DEBUG] Using user provided runner type: KrknRunnerType.HUB_RUNNER
[DEBUG] Identified 4 valid scenarios: ['pod_scenarios', 'application_outages', 'container_scenarios', 'dns_outage']
[INFO] Elasticsearch indexing is disabled
[INFO] Krkn-AI run UUID: b58b3f2b-9cf2-4bd3-8c36-85dcb58bfde7
[INFO] Saving config file to config.yaml
[DEBUG] Elasticsearch indexing is disabled. Skipping indexing of test configuration info.
[INFO] Creating population of size 2
[INFO] | Population |
[INFO] --------------------------------------------------------
[INFO] application-outages(robot-shop, 60, {service: redis}, [Egress]),
[INFO] container-scenarios(robot-shop, service=mongodb, 1, .*, 9, 60),
[INFO] --------------------------------------------------------
[INFO] | Generation 1 |
[INFO] --------------------------------------------------------
[INFO] Running scenario: application-outages(robot-shop, 60, {service: redis}, [Egress])
[DEBUG] Starting health check watcher for 0 applications
[DEBUG] Running command: podman
[DEBUG] 30-01-2026T20:22:44 Checking if OpenShift client is installed
[DEBUG] /usr/bin/oc
[DEBUG] 2026-01-30 20:22:45,548 [INFO] Starting kraken
[DEBUG] 2026-01-30 20:22:45,562 [INFO] Initializing client to talk to the Kubernetes cluster
[DEBUG] 2026-01-30 20:22:45,562 [INFO] Generated a uuid for the run: 07fcd8ff-6d5c-4e74-9a1e-cc1e591d85fe
[DEBUG] _ _
[DEBUG] | | ___ __ __ | | _____ _ __
[DEBUG] | |/ / '__/ ` | |/ / _ \ '
[DEBUG] | <| | | (
| | < / | | |
[DEBUG] ||__| _,||__
|| ||
[DEBUG]
[DEBUG]
[DEBUG] Traceback (most recent call last):
[DEBUG] File "/home/krkn/kraken/run_kraken.py", line 171, in main
[DEBUG] kubecli = KrknKubernetes(kubeconfig_path=kubeconfig_path)
[DEBUG] File "/usr/local/lib/python3.9/site-packages/krkn_lib/k8s/krkn_kubernetes.py", line 113, in init
[DEBUG] self.__initialize_config(kubeconfig_path)
[DEBUG] File "/usr/local/lib/python3.9/site-packages/krkn_lib/k8s/krkn_kubernetes.py", line 154, in __initialize_config
[DEBUG] config.load_kube_config(kubeconfig_path)
[DEBUG] File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 826, in load_kube_config
[DEBUG] loader.load_and_set(config)
[DEBUG] File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 590, in load_and_set
[DEBUG] self._load_cluster_info()
[DEBUG] File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 552, in _load_cluster_info
[DEBUG] self.ssl_ca_cert = FileOrData(
[DEBUG] File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 129, in as_file
[DEBUG] raise ConfigException("File does not exist: %s" % self._file)
[DEBUG] kubernetes.config.config_exception.ConfigException: File does not exist: /root/.minikube/ca.crt

Background and Context

No response

Current Problematic Code

Issues Identified

No response

Steps to Reproduce

Run krkn_ai on minikube

Impact

No response

Expected Behavior

No response

Proposed Solution

Had to embedd certificates to fix it:

kubectl config view --flatten > kubeconfig.yaml

Implementation Steps

No response

Acceptance Criteria

No response

Testing Checklist

No response

Environment

minikube

Logs

uv run krkn_ai run -vv     -r krknhub     -c ./krkn-ai.yaml     -o ./results     -p HOST=$HOST
/root/krkn-ai/.venv/lib64/python3.9/site-packages/google/auth/__init__.py:54: FutureWarning: You are using a Python version 3.9 past its end of life. Google will update google-auth with critical bug fixes on a best-effort basis, but not with any other fixes or features. Please upgrade your Python version, and then update google-auth.
  warnings.warn(eol_message.format("3.9"), FutureWarning)
/root/krkn-ai/.venv/lib64/python3.9/site-packages/google/oauth2/__init__.py:40: FutureWarning: You are using a Python version 3.9 past its end of life. Google will update google-auth with critical bug fixes on a best-effort basis, but not with any other fixes or features. Please upgrade your Python version, and then update google-auth.
  warnings.warn(eol_message.format("3.9"), FutureWarning)
[INFO] Initialized config: ./krkn-ai.yaml
[DEBUG] Initializing Prometheus client: http://192.168.49.2:30900
[DEBUG] Using user provided runner type: KrknRunnerType.HUB_RUNNER
[DEBUG] Identified 4 valid scenarios: ['pod_scenarios', 'application_outages', 'container_scenarios', 'dns_outage']
[INFO] Elasticsearch indexing is disabled
[INFO] Krkn-AI run UUID: b58b3f2b-9cf2-4bd3-8c36-85dcb58bfde7
[INFO] Saving config file to config.yaml
[DEBUG] Elasticsearch indexing is disabled. Skipping indexing of test configuration info.
[INFO] Creating population of size 2
[INFO] | Population |
[INFO] --------------------------------------------------------
[INFO] application-outages(robot-shop, 60, {service: redis}, [Egress]), 
[INFO] container-scenarios(robot-shop, service=mongodb, 1, .*, 9, 60), 
[INFO] --------------------------------------------------------
[INFO] | Generation 1 |
[INFO] --------------------------------------------------------
[INFO] Running scenario: application-outages(robot-shop, 60, {service: redis}, [Egress])
[DEBUG] Starting health check watcher for 0 applications
[DEBUG] Running command: podman
[DEBUG] 30-01-2026T20:22:44 Checking if OpenShift client is installed
[DEBUG] /usr/bin/oc
[DEBUG] 2026-01-30 20:22:45,548 [INFO] Starting kraken
[DEBUG] 2026-01-30 20:22:45,562 [INFO] Initializing client to talk to the Kubernetes cluster
[DEBUG] 2026-01-30 20:22:45,562 [INFO] Generated a uuid for the run: 07fcd8ff-6d5c-4e74-9a1e-cc1e591d85fe
[DEBUG]  _              _
[DEBUG] | | ___ __ __ _| | _____ _ __
[DEBUG] | |/ / '__/ _` | |/ / _ \ '_ \
[DEBUG] |   <| | | (_| |   <  __/ | | |
[DEBUG] |_|\_\_|  \__,_|_|\_\___|_| |_|
[DEBUG] 
[DEBUG] 
[DEBUG] Traceback (most recent call last):
[DEBUG]   File "/home/krkn/kraken/run_kraken.py", line 171, in main
[DEBUG]     kubecli = KrknKubernetes(kubeconfig_path=kubeconfig_path)
[DEBUG]   File "/usr/local/lib/python3.9/site-packages/krkn_lib/k8s/krkn_kubernetes.py", line 113, in __init__
[DEBUG]     self.__initialize_config(kubeconfig_path)
[DEBUG]   File "/usr/local/lib/python3.9/site-packages/krkn_lib/k8s/krkn_kubernetes.py", line 154, in __initialize_config
[DEBUG]     config.load_kube_config(kubeconfig_path)
[DEBUG]   File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 826, in load_kube_config
[DEBUG]     loader.load_and_set(config)
[DEBUG]   File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 590, in load_and_set
[DEBUG]     self._load_cluster_info()
[DEBUG]   File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 552, in _load_cluster_info
[DEBUG]     self.ssl_ca_cert = FileOrData(
[DEBUG]   File "/usr/local/lib/python3.9/site-packages/kubernetes/config/kube_config.py", line 129, in as_file
[DEBUG]     raise ConfigException("File does not exist: %s" % self._file)
[DEBUG] kubernetes.config.config_exception.ConfigException: File does not exist: /root/.minikube/ca.crt

Related Documentation

No response

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions