Generate a kubernetes cluster without/before using gcloud/aws or other cloud providers.
For educational purposes only, not meant to be used on production.
Based on (all credits to) https://github.com/kelseyhightower/kubernetes-the-hard-way
Optionally, also install and proxy the Kubernetes Dashboard, and add use a certbot certificate on the load balancer.
A two controllers and two workers deployment result:
Slightly modified from the original docs
- ./scripts/01-tools.sh
- ./scripts/02-certificates.sh
- ./scripts/03-configs.sh
- ./scripts/04-etcd.sh
- ./scripts/05-controllers.sh
- ./scripts/06-workers.sh
- ./scripts/07-net.sh
- ./scripts/08-smoke_tests.sh
- ./scripts/09-dashboard.sh
- Generate 2 controllers, 2 workers, 1 load-balancer and 1 client to generate the cluster:
vagrant up --provider=libvirt --no-parallel`
- Just generate vms (controllers, workers, load-balancer), in order to manually create the cluster:
EXCLUDE_CLIENT=true vagrant up --provider=libvirt --no-parallel
- Modify if needed ./.env.template (either as env vars, or
cp .env.template .env
):- the number of controllers and workers
- skip vagrant's provision step (manually generate the cluster using the ./scripts)
- ...