Skip to content

Set of ansible playbooks and roles to create and manage a kubernetes cluster on raspberry pi.

Notifications You must be signed in to change notification settings

sylvanld/kubernetes-on-raspberry

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Raspberry PI / Kubernetes cluster

Grant SSH access to a new key

  • Generate an SSH key if required
ssh-keygen -t rsa -b 4096 -f ~/.ssh/id_raspberry_osadmin
  • Copy value of SSH public key (in our example ~/.ssh/id_raspberry_osadmin.pub) in the list of public keys located in variables/ssh_authorized_keys.yml.

  • Run playbook to update SSH keys on all nodes

# only works from private network
make update-ssh-authorized-keys

NOTE: To run this from the Internet, use public inventory

Access nodes from the Internet

Add cluster hosts to your ~/.ssh/config

Host k3s-master
   HostName sylvan.ovh
   User osadmin
   Port 2220

Host k3s-worker1
   HostName sylvan.ovh
   User osadmin
   Port 2221

Host k3s-worker2
   HostName sylvan.ovh
   User osadmin
   Port 2222

Use public inventory when running ansible playbooks

export ANSIBLE_INVENTORY="inventory/public.yml"

NOTE: this is required to avoid using nodes' private IP addresses.

About

Set of ansible playbooks and roles to create and manage a kubernetes cluster on raspberry pi.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published