Instead I’d recommend telling
ssh-keygen
to store its generated ID file in/config/.ssh
. You don’t have to put it in a folder called.ssh
if you don’t want to, I just like the consistency. But you should put it in/config
so it is preserved over updates.
For anyone getting “no such file or directory” error at this point: Automated SSH commands from HA - #13 by CentralCommand