From 6689537563b5115f0fbd9088fe8ff8c91e5c6b14 Mon Sep 17 00:00:00 2001 From: nl6720 Date: Fri, 17 Jul 2020 09:04:29 +0300 Subject: Set root user's shell and password with custom /etc/passwd and /etc/shadow Correct shadow file permissions from build.sh. --- configs/releng/build.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'configs/releng/build.sh') diff --git a/configs/releng/build.sh b/configs/releng/build.sh index 7e8321e..327a193 100755 --- a/configs/releng/build.sh +++ b/configs/releng/build.sh @@ -125,7 +125,8 @@ make_customize_airootfs() { fi rm "${work_dir}/x86_64/airootfs/root/customize_airootfs.sh" - chmod -f 750 "${work_dir}/x86_64/airootfs/root" + [[ -e "${work_dir}/x86_64/airootfs/etc/shadow" ]] && chmod -f 0400 -- "${work_dir}/x86_64/airootfs/etc/shadow" + [[ -e "${work_dir}/x86_64/airootfs/root" ]] && chmod -f 0750 -- "${work_dir}/x86_64/airootfs/root" } # Prepare kernel/initramfs ${install_dir}/boot/ -- cgit v1.2.3-54-g00ecf