diff options
author | Mikael Magnusson <mikma@users.sourceforge.net> | 2018-02-28 00:32:21 +0100 |
---|---|---|
committer | Mikael Magnusson <mikma@users.sourceforge.net> | 2018-02-28 00:32:21 +0100 |
commit | be73c7abc4762807e7b36a70efdd0ac428c98c12 (patch) | |
tree | d6f2c9f8d1f5542e3ffbe05d7b5c30bad3631c95 | |
parent | 40bffd9fce4002b48149bf690b0275d2e7e0aca1 (diff) |
Disable root password
-rwxr-xr-x | build_rootfs.sh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/build_rootfs.sh b/build_rootfs.sh index 2c1a7ce..5262f43 100755 --- a/build_rootfs.sh +++ b/build_rootfs.sh @@ -57,6 +57,10 @@ pack_squashfs() { mksquashfs $dir $dst_file } +disable_root() { + sed -i -e 's/^root::/root:*:/' $instroot/etc/shadow +} + add_file() { file=$1 src_dir=$2 @@ -118,6 +122,7 @@ install_packages() { } unpack +disable_root add_files $files_dir $instroot if test -n "$files"; then add_files $files $instroot |