diff options
author | Andoni Morales Alastruey <ylatuya@gmail.com> | 2012-11-15 13:56:07 +0100 |
---|---|---|
committer | Andoni Morales Alastruey <ylatuya@gmail.com> | 2012-11-15 13:56:07 +0100 |
commit | 89a52ae739ef777b32d0e0be7632aa537706315b (patch) | |
tree | 7af6ea7632ce2fdda399582b33c999b1f3b7e7d5 | |
parent | 46fdea60f2f9871b31be48a71d9035c2761392e1 (diff) |
build-release: reset root password
In the bootstrap we run su -c "yum install foo" with a regular user,
so we need to remove the root password in the chroot.
-rw-r--r-- | tools/bootstrap-redhat.sh | 6 | ||||
-rw-r--r-- | tools/build-release.sh | 3 |
2 files changed, 9 insertions, 0 deletions
diff --git a/tools/bootstrap-redhat.sh b/tools/bootstrap-redhat.sh index 8ece9b31..d91a26ba 100644 --- a/tools/bootstrap-redhat.sh +++ b/tools/bootstrap-redhat.sh @@ -1,5 +1,11 @@ #!/bin/sh +# Requires rpm >= 4.10.0 see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=683759 +# $ sudo dpkg --force-all -i rpm-common_4.10.0-5_amd64.deb librpm3_4.10.0-5_amd64.deb \ +# librpmio3_4.10.0-5_amd64.deb librpmsign1_4.10.0-5_amd64.deb librpmbuild3_4.10.0-5_amd64.deb \ +# rpm_4.10.0-5_amd64.deb rpm2cpio_4.10.0-5_amd64.deb liblzma5_5.1.1alpha+20120614-1_amd64.deb \ +# python-rpm_4.10.0-5_amd64.deb + set -e set -x diff --git a/tools/build-release.sh b/tools/build-release.sh index 3bfbab0c..33a007c7 100644 --- a/tools/build-release.sh +++ b/tools/build-release.sh @@ -96,6 +96,9 @@ echo "mounting /proc and /sys" mount -o bind /proc $CHROOT_PATH/proc mount -o bind /sys $CHROOT_PATH/sys +echo "reset root password" +chroot $CHROOT_PATH sed -i 's/root:\*/root:/g' /etc/shadow + echo "chroot created" echo "starting the build" |