Revision 23956,
1017 bytes
checked in by broder, 15 years ago
(diff) |
Try again to use d-i-utils' chroot setup.
This re-implements r23944, hopefully fixing the issues with
policy-rc.d collision noted in r23948 by diverting any policy-rc.d
file installed by dpkg for the duration of the install.
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | |
---|
3 | # This is only invoked when the relevant preseed entry is passed in |
---|
4 | # during the preinstall questioning. (Thus, not for vanilla installs.) |
---|
5 | |
---|
6 | cp /debathena-jaunty/preseed /target/root/debathena.preseed |
---|
7 | cp /debathena-jaunty/install-debathena.sh /target/root |
---|
8 | if test -f /debathena-jaunty/pxe-install-flag ; then |
---|
9 | cp /debathena-jaunty/pxe-install-flag /target/root/pxe-install-flag |
---|
10 | fi |
---|
11 | |
---|
12 | . /lib/chroot-setup.sh |
---|
13 | |
---|
14 | chroot /target dpkg-divert --rename --add /usr/sbin/policy-rc.d |
---|
15 | if ! chroot_setup; then |
---|
16 | logger -t postinstall.sh -- "Target system not usable. Can't install Debathena." |
---|
17 | exit 1 |
---|
18 | fi |
---|
19 | |
---|
20 | chvt 5 |
---|
21 | chroot /target sh /root/install-debathena.sh < /dev/tty5 > /dev/tty5 2>&1 |
---|
22 | # This approach fails due to lingering processes keeping the |
---|
23 | # pipeline open and the script hung. |
---|
24 | # chroot /target sh /root/install-debathena.sh < /dev/tty5 2>&1 \ |
---|
25 | # | chroot /target tee /var/log/athena-install.log > /dev/tty5 |
---|
26 | sleep 5 |
---|
27 | |
---|
28 | chroot_cleanup |
---|
29 | chroot /target dpkg-divert --rename --remove /usr/sbin/policy-rc.d |
---|
30 | |
---|
31 | chvt 1 |
---|
Note: See
TracBrowser
for help on using the repository browser.