Skip to content

Latest commit

 

History

History
49 lines (35 loc) · 1.52 KB

README.md

File metadata and controls

49 lines (35 loc) · 1.52 KB

Ansible Role : Raspberry Pi4 Kubenetes install

This role will install a master and multiple workers joined in a cluster to Raspberry Pi4s.

Before using the role:

  • each pi must have a newly flashed sd card with raspbian buster lite from image >= 2019-09-26
  • the file /boot/ssh must be created on the first partition of each sd card to allow ssh login
  • the pi should ideally get its ip address from a static DHCP lease
    • if not ip addresses will have to be manually configured using either sudo raspi-config or by following an online guide
  • boot the pi from the sd card and perform initial login using login pi:raspberry, adding key to known hosts

Hosts file

An example hosts file is provided in this directory, uncomment and edit for ip addresses and number of workers.

Example Playbook

An example playbook pi-k8s_playbook.yml is provided in this directory.

To use, run:

ansible-playbook pi-k8s_playbook.yml

To limit to certain hosts use e.g.

ansible-playbook pi-k8s_playbook.yml -l k8s-pi-master

Once all workers joined, to delete join token on master, use:

ansible-playbook pi-k8s_playbook.yml --tags=delete_token

Reset

To reset the cluster and remove kubernetes & docker see this role

License

GPL v3.0