
How to Install Kubernetes in Apple Mac M Chip
Sep 2, 2024
2 min read
0
54
In this blog post, I will explain the most efficient method How to Install Kubernetes in Apple Mac M Chip based on my experience. I've tried Kubernetes on Docker, and Minikube but I always encounter issues. In my opinion, utilizing Rancher Kubernetes Desktop is the most straightforward approach. Here is an overview of the necessary steps.
Install Docker
Install Home Brew
Install Rancher Desktop
Install Kubectl
Test Kubernetes

Step 1: Install Docker
Download Docker image installer in their official website.
Install the Docker package that you've downloaded. See video below.
Step 2: Install Homebrew
Homebrew or simply brew is a Mac package manager. Having this tool allows you to easily install packages in Mac command line and its dependencies. The step by step guide can be found in their web site. In case you needed assistance, here is the video.
Install Xcode. Download Xcode in this link.
Install Homebrew. See video below or you may run this command in your Mac terminal:
$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"Step 3: Install Rancher Kubernetes Desktop
Download Rancher Kubernetes Desktop for Mac here. Make sure to choose Apple Silicon chipset.
Install Rancher Kubernetes Desktop. See video installation below.
Step 4: Install Kubectl
Go to the official Kubernetes website for installation guide of kubectl. You may follow my installation command below which is the same.
Option 1: Using Brew
Install using brew.
# brew install kubectlOption 2: Using Curl
Download the latest release.
 curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/darwin/arm64/kubectl"Download the checksum file.
 curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/darwin/arm64/kubectl.sha256"Validate the kubectl binary against the checksum file.
echo "$(cat kubectl.sha256)  kubectl" | shasum -a 256 --checkThe output should show ok.
kubectl: OKStep 5: Test Kubernetes
Check kubectl version
If this command run successfully. You must likely have a successful installation.
$ kubectl version
Launch HTTPD Pod
Below is the command to launch sample HTTPD pod. Attached also is the video for the complete command and viewing of pod.
Launch a HTTPD pod
$ kubectl run httpd --image=httpdCheck pod status
$ kubectl get podsHere is the complete video demo.
Conclusion: Install Kubernetes in Apple Mac M Chip
Here is the comprehensive guide for installing Kubernetes on an Apple Mac with an M Chip. If you already have Kubernetes installed on your Mac, you might need to remove the old .kube folder and then restart Rancher if you encounter a connection error. If you have any questions or face any issues, please don't hesitate to contact us or leave a comment on the post. In our upcoming blog post, we will publish an article that distinguishes between containers, pods, deployments, and services. Additionally, we will provide a demonstration.