Hi,
kubectl -n awx logs -f deployments/awx-operator-controller-manager -c awx-manager
Error from server: Get "https://x.x.x.x:10250/…
Is your K3s installed on pocans
?
If so, the default URL for Kubernetes API for K3s is [https://127.0.0.1:6443](https://127.0.0.1:6443)
, so I think your kubectl
tries to connect different Kubernetes cluster other than K3s,
I guess you’ve installed kubectl manually before installing K3s (K3s skips installing kubectl if it already exists), or environment variable KUBECONFIG specifies different config file other than /etc/rancher/k3s/k3s.yaml
.
Suggestions;
Make sure your kubectl
is symbolic link to k3s
(this is designed by K3s)
$ ls -l $(which kubectl)
lrwxrwxrwx. 1 root root 3 Oct 11 07:25 /usr/local/bin/kubectl → k3s
Or, append k3s
before your kubectl
command for every time e.g.:
$ k3s kubectl -n awx logs -f deployments/awx-operator-controller-manager -c awx-manager
Or, export KUBECONFIG to make kubectl
use /etc/rancher/k3s/k3s.yaml