diff --git a/README-iso.md b/README-iso.md index 7b481ed..06478c2 100644 --- a/README-iso.md +++ b/README-iso.md @@ -102,7 +102,7 @@ Work to reproduce install.img * missing files: - [x] /opt/xensource/installer/version.py - [x] installer.service getty@tty2.service - - [ ] sshd.service.d/installer.conf (disables sshd by default, enables with sshpassword=xxxx) + - [x] sshd.service.d/installer.conf (disables sshd by default, enables with sshpassword=xxxx) - [ ] ldconfig.service xenstored.service etc. links to /dev/null (those two at least seem unneeded) - [ ] /etc/udev/rules.d/: 11-dm-mpath.rules 62-multipath.rules 69-dm-lvm-metad.rules links to /dev/null diff --git a/installimg/8.2/etc/systemd/system/sshd.service.d/installer.conf b/installimg/8.2/etc/systemd/system/sshd.service.d/installer.conf new file mode 100644 index 0000000..a68ce22 --- /dev/null +++ b/installimg/8.2/etc/systemd/system/sshd.service.d/installer.conf @@ -0,0 +1,5 @@ +[Unit] +ConditionKernelCommandLine=sshpassword + +[Service] +ExecStartPre=/bin/sh -c '/bin/sed -e "s/.*sshpassword=\([^ ]*\).*/root:\1/" /proc/cmdline | /sbin/chpasswd' diff --git a/installimg/8.3/etc/systemd/system/sshd.service.d/sshd_installer.conf b/installimg/8.3/etc/systemd/system/sshd.service.d/sshd_installer.conf new file mode 100644 index 0000000..a68ce22 --- /dev/null +++ b/installimg/8.3/etc/systemd/system/sshd.service.d/sshd_installer.conf @@ -0,0 +1,5 @@ +[Unit] +ConditionKernelCommandLine=sshpassword + +[Service] +ExecStartPre=/bin/sh -c '/bin/sed -e "s/.*sshpassword=\([^ ]*\).*/root:\1/" /proc/cmdline | /sbin/chpasswd'