#!/bin/ash
# Bismark management post-install script


mkdir -p /root/.ssh
cat /etc/bismark/authorized_keys >> /etc/dropbear/authorized_keys
cat /etc/bismark/known_hosts >> /root/.ssh/known_hosts

# Set rc.local
grep -v exit /etc/rc.local > /tmp/rc.local
echo "bismark-bootstrap" >> /tmp/rc.local
echo "exit 0" >> /tmp/rc.local
mv /tmp/rc.local /etc/rc.local

