我正在尝试连接到Hyperkit以检查在此VM上运行的容器。
我现在得到的是[screen is terminating]
这是我的工作:
MacBook-Pro-Karol: ~
→ minikube start --driver=hyperkit
? minikube v1.12.3 na Darwin 10.15.6
✨ Using the hyperkit driver based on user configuration
? Starting control plane node minikube in cluster minikube
? Creating hyperkit VM (CPUs=2, Memory=4000MB, Disk=20000MB) ...
? preparing Kubernetes v1.18.3 on Docker 19.03.12...
? Verifying Kubernetes components...
? Enabled addons: default-storageclass, storage-provisioner
? Ready! kubectl is configured to be used with "minikube".
MacBook-Pro-Karol: ~
→ sudo screen /Users/karol/.minikube/machines/minikube/tty
Password:
[screen is terminating]
MacBook-Pro-Karol: ~
→ screen ~/Library/Containers/com.docker.docker/Data/vms/0/tty
[screen is terminating]
Cannot exec '/Users/karol/Library/Containers/com.docker.docker/Data/vms/0/tty': Permission denied
→ sudo screen ~/Library/Containers/com.docker.docker/Data/vms/0/tty
Password:
[screen is terminating]
Cannot exec '/Users/karol/Library/Containers/com.docker.docker/Data/vms/0/tty': Operation not permitted
任何帮助将不胜感激。
答案 0 :(得分:2)
您可以使用minikube ssh
到login到运行minikube的VM:
使用SSH登录或在计算机上运行命令;如同 “ docker-machine ssh”。
minikube ssh [flags]
,然后使用docker ps
检查此VM中正在运行的容器:
$ docker ps | grep kube-api
f53aebd26287 7e28efa976bd "kube-apiserver --ad…" 16 minutes ago k8s_kube-apiserver_kube-apiserver-minikube_kube-system_8009646ba816631d0677c2668886baad_1
12188a523d12 k8s.gcr.io/pause:3.2 "/pause" 16 minutes ago k8s_POD_kube-apiserver-minikube_kube-system_8009646ba816631d0677c2668886baad_1