Skip to content
Daniel Hiepler edited this page Aug 31, 2023 · 18 revisions

/bootstrap-plugins/ssh - configure ssh

Config parameters

Name Description Default Value
RPI_SSH_KEY_TYPE key type to generate ed25519
RPI_SSH_KEY_ROUNDS KDF rounds for generated key 100
RPI_SSH_KEYGEN use local ssh-keygen to generate a key for the pi user false
RPI_SSH_KEYGEN_SERVER (re)generate server keys on the pi false
RPI_SSH_AUTHORIZE array of public keys to add to authorized_keys for the pi user
RPI_SSH_ON setup on first "login" or "boot" login

Distfiles

  • /etc/ssh/sshd_config
  • /home/pi/.ssh/authorized_keys
  • /home/pi/.ssh/config
  • /home/pi/.ssh/known_hosts

Examples

RPI_BOOTSTRAP_PLUGINS+=("ssh") to append the plugin or RPI_BOOTSTRAP_PLUGINS=( ... "ssh" ... ) to place at some position in the current list.

just generate new ssh key for pi user

RPI_SSH_KEYGEN="true"
RPI_SSH_KEY_ROUNDS=500

authorize key and trigger regeneration of server keys

RPI_SSH_KEYGEN_SERVER="true"
RPI_SSH_AUTHORIZE="ssh-rsa AAAA... user@host"

Tests

TODO

Clone this wiki locally