From 30be8ddd88f617f21b874e623f2da8643fe2699c Mon Sep 17 00:00:00 2001 From: davidovski Date: Mon, 11 Apr 2022 15:27:40 +0100 Subject: added preserve to tar command --- scripts/install.sh | 14 +++++++++++--- src/bootstrap.sh | 1 + src/install.sh | 2 +- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/scripts/install.sh b/scripts/install.sh index f31d487..d342281 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -66,7 +66,7 @@ EOF generating_fstab () { echo "Generating fstab..." - xichroot $SYSCONFIG genfstab -U / > $SYSROOT/etc/fstab + xichroot $SYSROOT genfstab -U / > $SYSROOT/etc/fstab } building_initramfs () { @@ -95,20 +95,28 @@ installing_bootloader () { } } +fixing_permissions () { + xichroot $SYSROOT chmod 755 / + xichroot $SYSROOT chmod 755 /usr + xichroot $SYSROOT chmod 755 /usr/bin + xichroot $SYSROOT chmod 755 /usr/lib +} + downloading_additional_packages () { echo "Syncing repos..." xichroot $SYSROOT xi sync echo "Downloading additional packages..." - xichroot $SYSROOT xi $XIFLAGS install $additional_packages + xi -r $SYSROOT $XIFLAGS install $additional_packages } steps=" +configuring_nameservers generating_fstab building_initramfs configuring_system installing_bootloader configuring_users -configuring_nameservers +fixing_permissions downloading_additional_packages " diff --git a/src/bootstrap.sh b/src/bootstrap.sh index 02d8434..55060b3 100644 --- a/src/bootstrap.sh +++ b/src/bootstrap.sh @@ -32,6 +32,7 @@ create_directories () { chmod 0750 ${SYSROOT}/root chmod 0755 ${SYSROOT}/usr/bin chmod 0755 ${SYSROOT}/usr/lib + chmod 0755 ${SYSROOT}/ } import_keys () { diff --git a/src/install.sh b/src/install.sh index 3cab32f..a251820 100644 --- a/src/install.sh +++ b/src/install.sh @@ -1,7 +1,7 @@ #!/bin/sh extract () { - tar -h --no-overwrite-dir -vvxf $1 -C ${SYSROOT} 2>/dev/null | grep ^- | tr -s " " | cut -d" " -f6 | cut -c2- + tar -h -p --no-overwrite-dir -vvxf $1 -C ${SYSROOT} 2>/dev/null | grep ^- | tr -s " " | cut -d" " -f6 | cut -c2- } install_package () { -- cgit v1.2.1