cannot copy authorized_keys if hard linked so only copy if home dirs not preserved
This commit is contained in:
parent
d014a2433e
commit
0207a5f330
|
@ -393,8 +393,8 @@ postbootstrap_configuration() {
|
||||||
cp -al /{home,root} /archroot/
|
cp -al /{home,root} /archroot/
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# authorized_keys of root will be copied anyway
|
# just authorized_keys of root will be copied otherwise
|
||||||
if [ -e /root/.ssh/authorized_keys ]; then
|
if ! ${preserve_home_directories} && [ -e /root/.ssh/authorized_keys ]; then
|
||||||
mkdir -p /archroot/root/.ssh/
|
mkdir -p /archroot/root/.ssh/
|
||||||
chmod 700 /archroot/root/.ssh/
|
chmod 700 /archroot/root/.ssh/
|
||||||
cp -p /root/.ssh/authorized_keys /archroot/root/.ssh/authorized_keys
|
cp -p /root/.ssh/authorized_keys /archroot/root/.ssh/authorized_keys
|
||||||
|
|
Loading…
Reference in New Issue