I'm working on Apple Silicon M1 Max and I'm trying to access service through web browser, but minikube service nginx
opens blank web browser tab with some address (for example http://192.168.49.2:31542/
) which fails to load. In log below you can notice output from minikube service list
has no URL in URL
column. Command minikube service nginx --url
does not return any URL as well.
$ minikube start --driver=docker
π minikube v1.25.2 on Darwin 12.3 (arm64)
βͺ MINIKUBE_ACTIVE_DOCKERD=minikube
β¨ Using the docker driver based on user configuration
π Starting control plane node minikube in cluster minikube
π Pulling base image ...
πΎ Downloading Kubernetes v1.23.3 preload ...
> preloaded-images-k8s-v17-v1...: 419.07 MiB / 419.07 MiB 100.00% 22.15 Mi
π₯ Creating docker container (CPUs=2, Memory=7903MB) ...
π³ Preparing Kubernetes v1.23.3 on Docker 20.10.12 ...
βͺ kubelet.housekeeping-interval=5m
βͺ Generating certificates and keys ...
βͺ Booting up control plane ...
βͺ Configuring RBAC rules ...
π Verifying Kubernetes components...
βͺ Using image gcr.io/k8s-minikube/storage-provisioner:v5
π Enabled addons: storage-provisioner, default-storageclass
π Done! kubectl is now configured to use "minikube" cluster and "default" namespace by default
$ kubectl create deployment nginx --image=nginx && kubectl create service nodeport nginx --tcp=80:80
deployment.apps/nginx created
service/nginx created
$ kubectl get service
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
kubernetes ClusterIP 10.96.0.1 <none> 443/TCP 12m
nginx NodePort 10.104.191.210 <none> 80:31542/TCP 12m
$ minikube service list
|-------------|------------|--------------|-----|
| NAMESPACE | NAME | TARGET PORT | URL |
|-------------|------------|--------------|-----|
| default | kubernetes | No node port |
| default | nginx | 80-80/80 | |
| kube-system | kube-dns | No node port |
|-------------|------------|--------------|-----|
$ minikube service nginx --url
π Starting tunnel for service nginx.
β Because you are using a Docker driver on darwin, the terminal needs to be open to run it.
Any ideas why there is no service URL and I am not able to access service from web browser?
Enable Kubernetes
option in Docker Desktop inSettings>Kubernetes
. Cluster will be created automatically and you will be able usekubectl
commands in few minutes in terminal. After your Deployment will be created, you will be able to open web browser and check using URLlocalhost:port_number
. Let me know if it will solve your issue! β Veracruz