From 8be68422f36be39368a9e76703eeb43dcacd3c53 Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Thu, 6 Dec 2018 02:39:47 +0100 Subject: [PATCH] Make sure plom has rights to own ~/.ssh dir. --- all_new_2018/init_user_and_keybased_login.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/all_new_2018/init_user_and_keybased_login.sh b/all_new_2018/init_user_and_keybased_login.sh index dbce7f8..fc9dd96 100755 --- a/all_new_2018/init_user_and_keybased_login.sh +++ b/all_new_2018/init_user_and_keybased_login.sh @@ -43,6 +43,7 @@ sshpass -e scp ~/.ssh/id_rsa.pub root@"${server}":/tmp/authorized_keys sshpass -e ssh root@"${server}" \ 'useradd -m plom && '\ 'mkdir /home/plom/.ssh && '\ + 'chown plom:plom /home/plom/.ssh && '\ 'chown plom:plom /tmp/authorized_keys && '\ 'chmod u=rw,go= /tmp/authorized_keys && '\ 'mv /tmp/authorized_keys /home/plom/.ssh/' -- 2.30.2