blob: 76f620e04f8f22e5bb9a4d2fb480cdfb5ba239b4 [file] [log] [blame]
[Unit]
Description=Store SSH host keys into /cfg
After=netopeer2-keystored-init-keys.service cfg.mount
Requires=netopeer2-keystored-init-keys.service cfg.mount
ConditionPathExists=!/cfg/etc/keystored/keys
[Service]
Type=oneshot
ExecStartPre=/bin/mkdir -p /cfg/etc/ssh
ExecStart=/bin/sh -c 'cp -a /etc/ssh/ssh_host_*_key* /cfg/etc/ssh/'
ExecStart=/bin/cp -a /etc/keystored /cfg/etc/
[Install]
WantedBy=multi-user.target