Revision 25486,
1.5 KB
checked in by jdreed, 13 years ago
(diff) |
Initial checkin of precise installer.
netconfig and related code has been removed.
clusteraddr command-line argument has been de-supported.
|
Rev | Line | |
---|
[25486] | 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/preseed /target/root/debathena.preseed |
---|
| 7 | cp /debathena/install-debathena.sh /target/root |
---|
| 8 | if test -f /debathena/pxe-install-flag ; then |
---|
| 9 | cp /debathena/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 | |
---|
| 22 | # Something like this approach was once said to fail due to lingering |
---|
| 23 | # processes keeping the pipeline open and the script hung. According to |
---|
| 24 | # trac#225 this doesn't happen any more. |
---|
| 25 | (chroot /target sh /root/install-debathena.sh < /dev/tty5 2>&1 \ |
---|
| 26 | && touch /debathena/install-succeeded) \ |
---|
| 27 | | chroot /target tee /var/log/athena-install.log > /dev/tty5 |
---|
| 28 | |
---|
| 29 | if ! [ -e /debathena/install-succeeded ]; then |
---|
| 30 | echo "WARNING: your debathena postinstall has returned an error;" > /dev/tty5 |
---|
| 31 | echo "see above for details." > /dev/tty5 |
---|
| 32 | echo > /dev/tty5 |
---|
| 33 | echo "This shell is provided for debugging purposes. When you exit" > /dev/tty5 |
---|
| 34 | echo "the shell, your system will reboot into the newly-installed" > /dev/tty5 |
---|
| 35 | echo "system, though depending on the failure you may see continuing issues." > /dev/tty5 |
---|
| 36 | /bin/sh < /dev/tty5 > /dev/tty5 2>&1 |
---|
| 37 | fi |
---|
| 38 | |
---|
| 39 | sleep 5 |
---|
| 40 | |
---|
| 41 | chroot_cleanup |
---|
| 42 | chroot /target dpkg-divert --rename --remove /usr/sbin/policy-rc.d |
---|
| 43 | |
---|
| 44 | chvt 1 |
---|
Note: See
TracBrowser
for help on using the repository browser.