X-Git-Url: https://iankelling.org/git/?a=blobdiff_plain;f=fai%2Fconfig%2Fhooks%2Finstsoft.DEFAULT;h=9d8f0b77fbd51b1be686c97aeab206fe9d27034b;hb=14f283f82afc48d6cec1bb7498ec34ac2b0da77c;hp=2d0c9058c9b8c2b52f5751e8e9c5159ecc08e1e5;hpb=f67d4b719356595b424aa3cd358abc79426583c5;p=automated-distro-installer diff --git a/fai/config/hooks/instsoft.DEFAULT b/fai/config/hooks/instsoft.DEFAULT index 2d0c905..9d8f0b7 100755 --- a/fai/config/hooks/instsoft.DEFAULT +++ b/fai/config/hooks/instsoft.DEFAULT @@ -7,6 +7,10 @@ if ifclass VM && ! ifclass demohost || ifclass VOL_BULLSEYE_BOOTSTRAP || [[ ! $F exit 0 fi +if ifclass FSF; then + exit 0 +fi + keyfile=/var/lib/fai/config/distro-install-common/luks/host-$HOSTNAME f=$target/root/keyscript cat > $f </dev/null; then + mkdir -p $d/root/.ssh /etc/dropbear-initramfs + chmod 700 $d/root $d/root/.ssh + cp -p /root/.ssh/authorized_keys $d/root/.ssh/authorized_keys + cp -p /root/.ssh/authorized_keys /etc/dropbear-initramfs + if [[ -e /root/.ssh/authorized_keys2 ]]; then + cat /root/.ssh/authorized_keys2 >>/etc/dropbear-initramfs + fi +fi