summaryrefslogtreecommitdiffstats
path: root/hosts/nas1/postinst
diff options
context:
space:
mode:
authorP. J. McDermott <pj@pehjota.net>2020-10-20 11:34:10 (EDT)
committer P. J. McDermott <pj@pehjota.net>2020-10-20 11:35:48 (EDT)
commitad2cbc0237842628ab337ce1dc13d9b14b856062 (patch)
tree154a7936fdcf63ad4ca552fbc7351a31ebcdf317 /hosts/nas1/postinst
parente137a98ef96a47c7e520f8b14d9e98e338c98839 (diff)
downloadpc-inst-ad2cbc0237842628ab337ce1dc13d9b14b856062.zip
pc-inst-ad2cbc0237842628ab337ce1dc13d9b14b856062.tar.gz
pc-inst-ad2cbc0237842628ab337ce1dc13d9b14b856062.tar.bz2
nas1: Fix booting
Diffstat (limited to 'hosts/nas1/postinst')
-rw-r--r--hosts/nas1/postinst6
1 files changed, 5 insertions, 1 deletions
diff --git a/hosts/nas1/postinst b/hosts/nas1/postinst
index 82888aa..deb9438 100644
--- a/hosts/nas1/postinst
+++ b/hosts/nas1/postinst
@@ -7,7 +7,11 @@ in_target apt-get -q -y --purge autoremove || return 1
# Remove packages from APT cache.
in_target apt-get clean || return 1
-# Install GRUB.
+# Fix booting and install GRUB.
+mv "${target}/etc/default/grub" "${target}/etc/default/grub.dist"
+sed \
+ -e '^s/\(GRUB_CMDLINE_LINUX=".*\)"$/\1nomodeset"/'
+ "${target}/etc/default/grub.dist" 1>"${target}/etc/default/grub"
in_target update-grub
in_target grub-install "${dev}"