docker-sshd icon indicating copy to clipboard operation
docker-sshd copied to clipboard

sshd is not reading authorized_keys file or the HostKeys

Open m247support opened this issue 7 years ago • 0 comments

Hi,

Thanks a lot for this example! Very useful.. Except that the the the sshd is not reading authorized_keys file or the HostKeys when they mounted as a secret. I have a version k8s v1.8.4 cluster deployed using kubeadm. cating /root/.ssh/authorized_keys seems to follow symlinks to the volume correctly and the file does seem to have the relevant permissions for reading. However, sshd does not seem to be following the symlinks or reading the files at all. Maybe this is a security feature? Thanks in advance!

[12:05:23] root:sc-fd98d84bc-2skhg ~/.ssh > 
>   ls -lah
total 4.0K
drwxrwxrwt 3 root root  100 Dec 19 12:37 .
drwx------ 1 root root 4.0K Dec 19 12:43 ..
drwxr-xr-x 2 root root   60 Dec 19 12:37 ..129812_19_12_12_37_44.161025944
lrwxrwxrwx 1 root root   33 Dec 19 12:37 ..data -> ..129812_19_12_12_37_44.161025944
lrwxrwxrwx 1 root root   22 Dec 19 12:37 authorized_keys -> ..data/authorized_keys

[12:05:23] root:sc-fd98d84bc-2skhg ~/.ssh >   ls -lah
total 12K
drwxr-xr-x 1 root root 4.0K Dec 19 12:01 .
drwx------ 1 root root 4.0K Dec 19 12:05 ..
-rw-r--r-- 1 root root  721 Dec 19 12:01 authorized_keys

m247support avatar Jan 08 '18 06:01 m247support