-
Notifications
You must be signed in to change notification settings - Fork 136
SSH_USER_HOME on mapped host directory does not work #906
Comments
https://github.com/jdeathe/centos-ssh/blob/2.6.1/src/usr/sbin/sshd-bootstrap#L1238-L1246
|
@daniel-es6 Thanks for your interest in the project and for reporting this issue. The current release (2.6.1) is not able to support mapping a user's home directory that already contains an It should be possible to resolve this issue but please be aware that, if mapping the host's ${HOME} directory, it will replace the contents of |
Steps to replicate on OSX:
|
Thanks for responding quickly. Look forward to version 2.7.0! |
Proof-of-concept work-around on OSX:
|
@daniel-es6 Instructions on how to patch until 2.7.0 is released ☝️ |
Cool! |
just tried, got an error: |
@daniel-es6 There was a missing |
It's working now. So nice being able to persist user settings. |
I mounted the host directory to the container using /some/host/directory:/host
and set SSH_USER_HOME to /host/%u
The container boot up for the first time, and then will fail to start with error message like below:
2021-03-21 03:28:24,033 INFO exited: system-timezone-wrapper (exit status 0; expected)
useradd: warning: the home directory already exists.
Not copying any file from skel directory into it.
mkdir: cannot create directory '/host/userxx/.ssh': File exists
2021-03-21 03:28:24,261 INFO exited: sshd-bootstrap (exit status 1; not expected)
2021-03-21 03:28:24,268 INFO reaped unknown pid 112
2021-03-21 03:28:24,607 INFO reaped unknown pid 96
ERROR: sshd-wrapper timed out waiting on sshd-bootstrap
2021-03-21 03:28:28,041 INFO exited: sshd-wrapper (exit status 1; not expected)
2021-03-21 03:28:29,042 INFO gave up: sshd-wrapper entered FATAL state, too many start retries too quickly
The text was updated successfully, but these errors were encountered: