minikube setup based on ubuntu-20.04-arm64 running as a Vagrant Virtual Machine with the Parallels provider.
- Docker
- Docker Compose
- minikube
vagrant up
vagrant ssh
minikube start --kubernetes-version=v1.25.3
curl -LO https://dl.k8s.io/release/v1.25.3/bin/linux/arm64/kubectl
curl -LO https://dl.k8s.io/release/v1.25.3/bin/linux/arm64/kubectl.sha256
echo "$(cat kubectl.sha256) kubectl" | sha256sum --check
sudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl
kubectl get pods -A
kubectl create job hello --image nixery.dev/arm64/shell -- echo "Hello World"
kubectl proxy --port=8080 --address=0.0.0.0 --accept-hosts='.+'
curl http://localhost:8080/apis
The src directory contains an simple program using the client-go library, to talk with the Kubernetes API and list the existing jobs in the default namespace.
To create the program binary run (from the src
directory):
GOOS=linux go build -o jobs main.go
in the host machine and execute the following in the guess one:
/vagrant/src/jobs
the output should be similar to:
hello
the name of the Job created before in the default
namespace.