Introduction
Update and install minikube
- make sure that you have the most up-to-date version installed:
minikube update-check
. At the time of writing it’sv1.29.0
- delete any previous minikube config:
minikube delete
- install minikube in docker on the stable version:
minikube start --driver=docker --kubernetes-version=v1.26.1
. Note after the initial install you only need to runminikube start
since the config is sticky - check that minikube is up-and-running:
kubectl get nodes
The output should look like this:
NAME STATUS ROLES AGE VERSION
minikube Ready control-plane 29s v1.26.1
Enable the ingress controller addon
Run minikube addons enable ingress
. Note the following mention:
After the addon is enabled, please run "minikube tunnel" and your ingress resources would be available at "127.0.0.1"
This is the main difference between running minikube on linux and on the mac: on linux the ingress controller gets expose under its own IP (minikube ip
). Since the docker bridge behaves differently on the mac the ingress controller listens on localhost and needs to be tunneled to, by running minikube tunnel
in a separate terminal.
Deploy a simple app
-
Edit your
/etc/hosts
file and add127.0.0.1 status.asksven.local
(or any other URL you go for) -
Download this gist, to let’s say
~/statuspage
-
Change the hostname in
ingress.yaml
depending on your choice in 1, and deploy:kubectl create ns statuspage && kubectl -n statuspage apply -f <directory-where-you-unzipped-the-gist>
-
Point your browser at `https://
Voila!